{"id":1506,"date":"2020-04-01T12:29:54","date_gmt":"2020-04-01T10:29:54","guid":{"rendered":"https:\/\/www.trans.eu\/api\/?p=1506"},"modified":"2025-12-29T11:13:16","modified_gmt":"2025-12-29T10:13:16","slug":"create-new-vehicle-exchange-offer","status":"publish","type":"post","link":"https:\/\/www.trans.eu\/api\/vehicles\/manage-offers\/create-new-vehicle-exchange-offer\/","title":{"rendered":"Create new vehicle exchange offer"},"content":{"rendered":"\n<p>Cre\u00adate new vehi\u00adcle offer for vehi\u00adcle exchange<\/p>\n\n\n\n<!--more-->\n\n\n\n<h2 class=\"wp-block-heading\">Description<\/h2>\n\n\n\n<p>Vehi\u00adcle exchange API gives infor\u00adma\u00adtion about the avail\u00adabil\u00adi\u00adty of your vehi\u00adcle fleet to oth\u00ader plat\u00adform users who are look\u00ading for trans\u00adport between the giv\u00aden loca\u00adtions. Vehi\u00adcle offers are also one of the sources of vehi\u00adcle avail\u00adabil\u00adi\u00adty for the smart\u00admatch algo\u00adrithm. Each vehi\u00adcle offer is always vis\u00adi\u00adble to all plat\u00adform users once it was cre\u00adat\u00aded.<\/p>\n\n\n\n<p>Using this API it is also pos\u00adsi\u00adble to get all own vehi\u00adcle offers.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Url parameters and connection settings<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>URL:<\/strong>&nbsp;https:\/\/api.platform.trans.eu<\/li>\n\n\n\n<li><strong>End\u00adpoint:<\/strong> \/ex\u00adt\/ve\u00adhi\u00adcles-api\/v1\/ve\u00adhi\u00adcles<\/li>\n\n\n\n<li><strong>Method:<\/strong>&nbsp;POST<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Headers<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Con\u00adtent-type: application\/json<\/li>\n\n\n\n<li>Accept: application\/json<\/li>\n\n\n\n<li>Autho\u00adriza\u00adtion: Bear\u00ader {access_token}<\/li>\n\n\n\n<li>Api-key: {unique_ap\u00adp_api-key}<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Authorization and access<\/h2>\n\n\n\n<p>Autho\u00adriza\u00adtion process&nbsp;<a href=\"https:\/\/www.trans.eu\/api\/general-information\/authorization-process\/\" target=\"_blank\" rel=\"noopener\" title>is described here<\/a>.&nbsp; Each API request must also con\u00adsist of unique Api-key obtained dur\u00ading appli\u00adca\u00adtion reg\u00adis\u00adtra\u00adtion togeth\u00ader with client_id and client_secret.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Vehicle offer request<\/h2>\n\n\n\n<p>Exam\u00adple of request for cre\u00adat\u00ading new vehi\u00adcle offer. For allowed val\u00adues please look <a href=\"https:\/\/www.trans.eu\/api\/general-information\/allowed-values\/\">here<\/a>.<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-json\" data-lang=\"JSON\"><code>{\n  \"vehicle_size\": \"bus\",\n  \"truck_body\": \"standard-tent\",\n  \"loading_place\": {\n    \"address\": {\n      \"locality\": \"Wroclaw\",\n      \"postal_code\": \"56-111\",\n      \"country\": \"pl\"\n    }\n  },\n  \"unloading_place\": {\n    \"address\": {\n      \"locality\": \"Wroclaw\",\n      \"postal_code\": \"56-111\",\n      \"country\": \"pl\"\n    }\n  },\n  \"cargo\": {\n    \"capacity\": 5\n  },\n  \"available_on\": {\n    \"begin\": \"2021-03-09T15:25:00+0000\",\n    \"end\": \"2021-03-09T19:25:00+0000\"\n  }\n}<\/code><\/pre><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Response<\/h2>\n\n\n\n<p>Con\u00adfir\u00adma\u00adtion of prop\u00ader\u00adly cre\u00adat\u00aded offer<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-json\" data-lang=\"JSON\"><code>{\n  \"id\": \"01E4WTST4JK6HT6SZD8PDY7BDS\"\n}<\/code><\/pre><\/div>\n","protected":false},"excerpt":{"rendered":"<p class=\"dont-break-out\">Cre\u00adate new vehi\u00adcle offer for vehi\u00adcle exchange<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"wp_typography_post_enhancements_disabled":false,"footnotes":""},"categories":[114],"tags":[],"class_list":["post-1506","post","type-post","status-publish","format-standard","hentry","category-manage-offers"],"acf":[],"aioseo_notices":[],"lang":"en","translations":{"en":1506},"pll_sync_post":[],"_links":{"self":[{"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/posts\/1506","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/comments?post=1506"}],"version-history":[{"count":1,"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/posts\/1506\/revisions"}],"predecessor-version":[{"id":5562,"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/posts\/1506\/revisions\/5562"}],"wp:attachment":[{"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/media?parent=1506"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/categories?post=1506"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.trans.eu\/api\/wp-json\/wp\/v2\/tags?post=1506"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}