Documentație APIAPI Documentation
Documentație APIAPI Documentation
Bine ai venit în documentația API SmartShip.ro. Prin API poți estima costuri de livrare la toți curierii, emite AWB-uri, urmări colete, anula expedieri, descărca etichete și consulta decontările de ramburs — direct din aplicația ta. Toate cererile și răspunsurile folosesc JSON.Welcome to the SmartShip.ro API documentation. The API lets you estimate delivery costs across all couriers, create AWBs, track parcels, cancel shipments, download labels and retrieve cash-on-delivery payouts — straight from your application. All requests and responses use JSON.
Ai contract direct cu un curier și vrei să emiți pe el prin SmartShip? Vezi documentația pentru contract propriu (BYOC).Do you have a direct contract with a courier and want to ship on it through SmartShip? See the own contract (BYOC) documentation.
AutentificareAuthentication
Toate cererile se autentifică cu cheia ta API, trimisă în header-ul X-API-KEY. Găsești cheia în platformă: Contul meu → Setări → API. Tratează cheia ca pe o parolă — nu o publica în cod client-side (browser, aplicații mobile).All requests are authenticated with your API key, sent in the X-API-KEY header. You can find your key in the platform: My account → Settings → API. Treat the key like a password — never expose it in client-side code (browser, mobile apps).
curl -X GET "https://api.smartship.ro/geolocation/counties" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/geolocation/counties");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/geolocation/counties", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/geolocation/counties",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json()Curieri disponibiliAvailable couriers
Tabelul de mai jos e generat automat din platformă și reflectă curierii activi în acest moment, cu regulile fiecăruia. ID-ul din prima coloană se folosește la courier_id (emitere) și curier_preferat (estimare).The table below is generated automatically from the platform and reflects the currently active couriers and their rules. The ID in the first column is used for courier_id (AWB creation) and curier_preferat (cost estimation).
| ID | CurierCourier | Greutate maxMax weight | Max / coletMax / parcel | RambursCOD | PalețiPallets |
|---|---|---|---|---|---|
1 |
Cargus | 200 kg | 31 kg | DaYes | NuNo |
2 |
SameDay | 200 kg | 31 kg | DaYes | NuNo |
5 |
DragonStar | 2000 kg | 2000 kg | DaYes | DaYes |
8 |
PTT Express | 800 kg | 31 kg | DaYes | NuNo |
12 |
SameDay EasyBox | 30 kg | 20 kg | DaYes | NuNo |
14 |
PTT Express | 2000 kg | 2000 kg | DaYes | DaYes |
16 |
SmartShip Delivery | 10000 kg | 10000 kg | DaYes | DaYes |
19 |
FedEx | 200 kg | 68 kg | NuNo | NuNo |
Obiecte comuneCommon objects
Endpoint-urile /cost și /awb/new folosesc aceleași trei obiecte: sender, recipient și content.The /cost and /awb/new endpoints share the same three objects: sender, recipient and content.
Obiectele sender / recipientThe sender / recipient objects
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
name | string | obligatoriurequired | Nume și prenume (sau denumirea firmei). Minim două cuvinte.First and last name (or company name). At least two words. |
address | string | obligatoriurequired | Adresa completă: stradă, număr, detalii.Full street address: street, number, details. |
email | string | opționaloptional | Adresa de email. Destinatarul primește notificări de tracking pe această adresă.Email address. The recipient receives tracking notifications at this address. |
city | integer | obligatoriurequired | ID-ul localității, obținut din /geolocation/cities. Nu se trimite denumirea, ci ID-ul numeric.The locality ID, obtained from /geolocation/cities. Send the numeric ID, not the name. |
phone | string | obligatoriurequired | Număr de telefon valid (10 cifre, format românesc).Valid phone number (10 digits, Romanian format). |
country | string | obligatoriurequired | Codul țării. Pentru livrări interne: RO.Country code. For domestic shipments: RO. |
sector | integer | opționaloptional | Obligatoriu doar pentru București: sectorul, valoare 1–6. Pentru restul localităților trimite 0.Required only for Bucharest: the district (sector), value 1–6. For all other localities send 0. |
Obiectul contentThe content object
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
package_content | string | obligatoriurequired | Descrierea conținutului coletului (apare pe AWB).Description of the parcel contents (printed on the AWB). |
parcels | integer | obligatoriurequired | Numărul de colete. Pentru colete cu dimensiuni diferite folosește parcels_multiple.Number of parcels. For parcels with different dimensions use parcels_multiple. |
weight | number | obligatoriurequired | Greutatea totală în kg. Se facturează maximul dintre greutatea fizică și cea volumetrică (L×l×h / 6000 per colet).Total weight in kg. Billing uses the greater of physical and volumetric weight (L×W×H / 6000 per parcel). |
cash_on_delivery | number | opționaloptional | Valoarea rambursului în RON. 0 = fără ramburs. Atenție: unii curieri (ex. FedEx) nu acceptă ramburs și nu vor apărea la estimare.Cash on delivery amount in RON. 0 = no COD. Note: some couriers (e.g. FedEx) do not support COD and will not be returned in estimates. |
length / width / height | integer | obligatoriurequired | Dimensiunile coletului în cm.Parcel dimensions in cm. |
insurance | number | opționaloptional | Valoarea declarată / asigurată în RON. 0 = fără asigurare.Declared / insured value in RON. 0 = no insurance. |
iban | string | opționaloptional | IBAN-ul pentru virarea rambursului. Obligatoriu când cash_on_delivery > 0. IBAN-ul este validat la fiecare cerere.IBAN for the COD payout. Required when cash_on_delivery > 0. The IBAN is validated on every request. |
open_package | integer | opționaloptional | 1 = destinatarul poate deschide coletul la livrare (unde curierul suportă opțiunea). Implicit 0. Nu se aplică la livrarea în locker (nu există curier prezent care să deschidă coletul): dacă trimiți open_package: 1 împreună cu locker_id, opțiunea este ignorată.1 = the recipient may open the parcel on delivery (where the courier supports it). Default 0. Not available for locker delivery (there is no courier present to open the parcel): if you send open_package: 1 together with locker_id, the option is ignored. |
order_id | string | opționaloptional | ID-ul comenzii din sistemul tău. Poți regăsi ulterior AWB-ul după el, prin /awb/order_id/{order_id}.Your internal order ID. You can later look up the AWB by it via /awb/order_id/{order_id}. |
curier_preferat | integer | opționaloptional | Doar la /cost: dacă e specificat, estimarea se face doar pentru acest curier (vezi tabelul de curieri). 0 sau lipsă = toți curierii.Only for /cost: when set, the estimate is returned only for this courier (see the couriers table). 0 or missing = all couriers. |
parcels_multiple | array | opționaloptional | Colete multiple cu dimensiuni diferite: listă de obiecte {"weight": 2, "length": 30, "width": 20, "height": 10}. Dacă e prezentă, are prioritate față de parcels/weight/dimensiunile simple.Multiple parcels with different dimensions: a list of {"weight": 2, "length": 30, "width": 20, "height": 10} objects. When present, it takes precedence over parcels/weight/the simple dimensions. |
dpd_shipment_note | string | opționaloptional | Doar pentru DPD: notă suplimentară tipărită pe etichetă. Maxim 200 de caractere.DPD only: extra note printed on the label. Max. 200 characters. |
locker_id | integer | opționaloptional | Pentru livrare la SameDay easybox (curier 12): ID-ul lockerului, din /geolocation/easybox. Fără locker_id, easybox nu apare la estimare și nu se poate emite. Când trimiți locker_id, /cost întoarce DOAR varianta la locker (ceilalți curieri livrează la adresă, deci nu sunt opțiuni pentru aceeași trimitere; regula are prioritate și față de curier_preferat). Ca să compari livrare acasă vs la locker, fă două apeluri: unul cu locker_id, unul fără. Dacă locker_id nu e valid, cererea eșuează cu 612 — nu se cotează livrare la adresă în locul lui. Coletul se livrează la locker, nu la adresa destinatarului (max 30 kg).For delivery to a SameDay easybox locker (courier 12): the locker ID, from /geolocation/easybox. Without locker_id, easybox is not returned in estimates and cannot be used for AWB creation. When you send locker_id, /cost returns ONLY the locker option (all other couriers deliver to an address, so they are not options for the same shipment; this rule also overrides curier_preferat). To compare home vs locker delivery, make two calls: one with locker_id, one without. If locker_id is not valid, the request fails with 612 — address delivery is not quoted as a fallback. The parcel is delivered to the locker, not to the recipient's address (max 30 kg). |
personal_drop_off | integer | opționaloptional | 1 = predare personală: duci tu coletul la un easybox sau punct SameDay, nu vine curierul să-l ridice de la adresa expeditorului. Disponibil doar la SameDay (2) și SameDay easybox (12). La /cost, cu personal_drop_off: 1 se întorc doar aceste variante, cu prețul pentru predare personală. Implicit 0. Vezi Livrare la locker și predare personală.1 = personal drop-off: you take the parcel to a SameDay easybox or pickup point yourself, no courier collects it from the sender address. Available only for SameDay (2) and SameDay easybox (12). On /cost, with personal_drop_off: 1 only these options are returned, priced for personal drop-off. Default 0. See Locker delivery and personal drop-off. |
swap | integer | opționaloptional | Doar la /awb/new: 1 = colet la schimb (curierul predă coletul și preia altul înapoi). Costul se dublează (tur + retur). Acceptat la PTT Express (14) și SmartShip Delivery (16). La curierii care nu îl acceptă cererea este respinsă cu eroarea 699. Implicit 0.Only for /awb/new: 1 = exchange parcel (the courier delivers the parcel and collects another one back). The cost is doubled (outbound + return). Accepted by PTT Express (14) and SmartShip Delivery (16). Couriers that do not support it reject the request with error 699. Default 0. |
nocom | integer | opționaloptional | Doar la /awb/new: 1 = NU comanda automat curierul pentru ridicare (valabil la FanCourier, DragonStar și PTT Express, unde ridicarea se comandă automat la emitere). Util dacă ai deja o ridicare zilnică programată. Implicit 0.Only for /awb/new: 1 = do NOT automatically order the courier pickup (applies to FanCourier, DragonStar and PTT Express, where pickup is ordered automatically at creation). Useful if you already have a scheduled daily pickup. Default 0. |
Flux recomandat de integrareRecommended integration flow
1. Localitățile: expeditorul și destinatarul se trimit cu ID-ul numeric al localității (city), luat din /geolocation/counties și /geolocation/cities. Expeditorii salvați în cont îi găsești în /account/senders.1. Localities: sender and recipient are sent with the numeric locality ID (city), taken from /geolocation/counties and /geolocation/cities. Senders saved in your account are available at /account/senders.
2. Prețul: /cost întoarce curierii disponibili, cu prețul cu TVA, sortați crescător. Alegi unul (sau îl lași pe client să aleagă).2. Price: /cost returns the available couriers with VAT-inclusive prices, sorted ascending. Pick one (or let your customer choose).
3. AWB-ul: /awb/new cu courier_id din pasul 2 și aceleași date. Răspunsul conține awb, pdf_link (eticheta) și tracking_url (pagina de urmărire pentru destinatar). Trimite și order_id, ca să poți regăsi AWB-ul după comanda ta.3. AWB: /awb/new with the courier_id from step 2 and the same data. The response contains awb, pdf_link (the label) and tracking_url (the tracking page for the recipient). Also send order_id so you can find the AWB by your order later.
4. Eticheta și ridicarea: descarci eticheta din pdf_link sau /awb/print. La curierii unde ridicarea nu se comandă automat, verifici și programezi cu /pickup/availability și /pickup.4. Label and pickup: download the label from pdf_link or /awb/print. For couriers where pickup is not ordered automatically, check and book it with /pickup/availability and /pickup.
5. Urmărirea și banii: statusul cu /awb/status (sau lista cu /awbs), iar rambursurile încasate cu /payouts.5. Tracking and money: status via /awb/status (or the list via /awbs), and collected cash on delivery via /payouts.
Răspunsuri și erori: fiecare răspuns JSON are câmpul status — 200 înseamnă succes, orice altă valoare e o eroare, explicată în message (la erorile de validare 999, lista completă e în erori). Verifică mereu status din JSON, nu doar codul HTTP. Codurile posibile sunt listate la fiecare endpoint.Responses and errors: every JSON response has a status field — 200 means success, any other value is an error explained in message (for validation errors 999, the full list is in erori). Always check the JSON status, not just the HTTP code. The possible codes are listed for each endpoint.
Livrare la locker și predare personalăLocker delivery and personal drop-off
Sunt două opțiuni independente, care se pot combina: livrarea la locker (destinatarul ridică coletul dintr-un locker, nu îl primește acasă) și predarea personală (tu, expeditorul, duci coletul la un easybox sau punct SameDay, în loc să vină curierul să-l ridice).These are two independent options that can be combined: locker delivery (the recipient collects the parcel from a locker instead of receiving it at home) and personal drop-off (you, the sender, take the parcel to a SameDay easybox or pickup point instead of having a courier collect it).
Livrare la easybox, în 3 pași: 1) iei ID-ul lockerului din /geolocation/easybox; 2) apelezi /cost cu content.locker_id — răspunsul conține doar varianta courier_id: 12; 3) emiți cu /awb/new, cu courier_id: 12 și același content.locker_id. Coletul ajunge în locker (max 30 kg), iar open_package este ignorat. Dacă trimiți ramburs, lockerul trebuie să accepte plata ramburs (altfel eroarea 6590).easybox delivery, in 3 steps: 1) get the locker ID from /geolocation/easybox; 2) call /cost with content.locker_id — the response contains only the courier_id: 12 option; 3) create the AWB with /awb/new, using courier_id: 12 and the same content.locker_id. The parcel goes to the locker (max 30 kg) and open_package is ignored. If you send cash on delivery, the locker must accept COD payment (otherwise error 6590).
Predare personală: trimite content.personal_drop_off: 1, atât la /cost cât și la /awb/new. Este disponibilă la SameDay (2) și SameDay easybox (12), iar prețul este cel pentru predare personală. Nu se comandă curier pentru ridicare: după emitere, duci coletul cu AWB-ul la un easybox sau punct SameDay. Cu alt curier primești eroarea 613.Personal drop-off: send content.personal_drop_off: 1 on both /cost and /awb/new. It is available for SameDay (2) and SameDay easybox (12), and the price is the personal drop-off price. No courier pickup is ordered: after the AWB is created, take the parcel with its AWB to a SameDay easybox or pickup point. With any other courier you get error 613.
Emitere: predare personală + livrare la easyboxCreate AWB: personal drop-off + easybox delivery
curl -X POST "https://api.smartship.ro/awb/new" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"courier_id": 12,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720000000"
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0721000000"
},
"content": {
"package_content": "Cosmetice",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"locker_id": 1234,
"personal_drop_off": 1
}
}'$payload = json_decode('{
"courier_id": 12,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720000000"
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0721000000"
},
"content": {
"package_content": "Cosmetice",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"locker_id": 1234,
"personal_drop_off": 1
}
}', true);
$ch = curl_init("https://api.smartship.ro/awb/new");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awb/new", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"courier_id": 12,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720000000"
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0721000000"
},
"content": {
"package_content": "Cosmetice",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"locker_id": 1234,
"personal_drop_off": 1
}
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/awb/new",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"courier_id": 12,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720000000"
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0721000000"
},
"content": {
"package_content": "Cosmetice",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"locker_id": 1234,
"personal_drop_off": 1
}
},
)
data = response.json()Integrare cu AI (ChatGPT, Claude, Cursor)Using the API with AI (ChatGPT, Claude, Cursor)
Ca să scrie un AI integrarea pentru tine, dă-i una dintre variantele de mai jos (sunt generate automat din aceeași sursă ca pagina, deci sunt mereu la zi): specificația OpenAPI (cea mai bună pentru generare de cod), documentația în Markdown (o singură limbă, fără duplicări; în engleză) sau butonul „Copiază pentru AI” din capul paginii. Pentru contract propriu există variantele OpenAPI BYOC și Markdown BYOC. Rezumatul pentru modele AI este în /llms.txt.To have an AI write the integration for you, give it one of the formats below (generated automatically from the same source as this page, so always up to date): the OpenAPI specification (best for code generation), the Markdown documentation (single language, no duplication) or the “Copy for AI” button at the top of the page. For your own contract there are OpenAPI BYOC and Markdown BYOC. The summary for AI models is at /llms.txt.
Conector AI (MCP), fără cod: poți conecta contul SmartShip direct la Claude, ChatGPT sau orice aplicație compatibilă MCP și lucra în limbaj natural: „unde e coletul X?”, „ce colete au probleme?”, „cât costă un colet de 5 kg la Cluj?”, „emite un AWB pentru comanda 1234”, „anulează AWB-ul Y”. Asistentul poate urmări colete, căuta după comandă, lista expedieri, compara tarife (inclusiv colete cu dimensiuni diferite, asigurare, easybox și predare personală), vedea soldul, facturile și decontările, găsi lockere easybox, descărca etichete, dar și emite AWB-uri, anula AWB-uri neridicate și programa ridicări FedEx.AI connector (MCP), no code: you can connect your SmartShip account directly to Claude, ChatGPT or any MCP-compatible app and work in plain language: “where is parcel X?”, “which parcels have problems?”, “how much is a 5 kg parcel to Cluj?”, “create an AWB for order 1234”, “cancel AWB Y”. The assistant can track parcels, look up orders, list shipments, compare rates (including parcels of different sizes, insurance, easybox and personal drop-off), show balance, invoices and payouts, find easybox lockers, download labels, and also create AWBs, cancel AWBs not yet picked up and schedule FedEx pickups.
Cum îl activezi: din contul SmartShip, Setări cont → Conector AI → „Activează conectorul AI”. Primești un link https://mcp.smartship.ro/c/… care identifică contul tău, deci tratează-l ca pe o parolă (de acolo îl poți regenera, dezactiva sau trece pe „doar citire” oricând). În Claude: Setări → Conectori → Adaugă conector personalizat și lipești linkul. În Claude Code: claude mcp add --transport http smartship https://mcp.smartship.ro/c/LINKUL_TAU. În alte aplicații, adaugă-l ca server MCP de tip HTTP (sau prin npx mcp-remote cu același URL).How to enable it: in your SmartShip account, Account settings → AI connector → “Enable the AI connector”. You get a https://mcp.smartship.ro/c/… link that identifies your account, so treat it like a password (there you can regenerate it, disable it or switch it to read-only at any time). In Claude: Settings → Connectors → Add custom connector and paste the link. In Claude Code: claude mcp add --transport http smartship https://mcp.smartship.ro/c/YOUR_LINK. In other apps, add it as an HTTP MCP server (or via npx mcp-remote with the same URL).
Siguranța operațiunilor: emiterea, anularea și programarea ridicării se fac în doi pași — asistentul îți arată întâi rezumatul (expeditor, destinatar, curier, cost) și execută doar după ce confirmi explicit în chat. Expeditorul se alege doar dintre cei salvați în cont, rambursul se virează doar într-un IBAN al contului, prețul se verifică din nou la confirmare, iar o comandă care are deja AWB activ nu primește încă unul fără cererea ta explicită.Safety: creating, cancelling and pickup scheduling happen in two steps — the assistant first shows you a summary (sender, recipient, courier, cost) and acts only after you explicitly confirm in the chat. The sender can only be one of the senders saved in your account, COD is paid only into an IBAN of your account, the price is re-checked at confirmation, and an order that already has an active AWB does not get another one unless you explicitly ask.
Estimare cost livrareEstimate delivery cost
Returnează costul livrării la toți curierii disponibili pentru datele trimise, sortat crescător după preț. Prețurile includ discountul contului tău și sunt exprimate în RON, cu TVA inclus (câmpul cost). Pentru comoditate întoarcem și cost_fara_tva. Fiecare curier include și ramburs_delay — estimarea timpului până la plata rambursului (median și p75, în zile de la livrare), calculată din livrările anterioare; null dacă nu avem date suficiente. Curierii care nu pot onora cererea (reguli de greutate, ramburs, rută) sunt omiși din răspuns.Returns the delivery cost for every courier available for the given data, sorted by price ascending. Prices include your account discount and are expressed in RON, VAT included (the cost field). For convenience we also return cost_fara_tva (net of VAT). Each courier also includes ramburs_delay — the estimated time until the COD payout (median and p75, in days from delivery), computed from previous deliveries; null when we lack enough data. Couriers that cannot fulfil the request (weight, COD or route rules) are omitted from the response.
Body-ul folosește obiectele comune sender, recipient și content.The body uses the common sender, recipient and content objects.
Coduri de eroareError codes
| 999 | Erori de validare. Câmpul erori conține lista problemelor (nume incomplet, telefon invalid, localitate lipsă etc.).Validation errors. The erori field lists the problems (incomplete name, invalid phone, missing locality, etc.). |
| 201 | IBAN invalid (când cash_on_delivery > 0).Invalid IBAN (when cash_on_delivery > 0). |
| 612 | curier_preferat = 12 (easybox) fără locker_id valid.curier_preferat = 12 (easybox) without a valid locker_id. |
| 613 | personal_drop_off: 1 cu un curier_preferat diferit de SameDay (2) sau easybox (12).personal_drop_off: 1 with a curier_preferat other than SameDay (2) or easybox (12). |
| 301 | Cheie API invalidă.Invalid API key. |
curl -X POST "https://api.smartship.ro/cost" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0
}
}'$payload = json_decode('{
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0
}
}', true);
$ch = curl_init("https://api.smartship.ro/cost");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/cost", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0
}
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/cost",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0
}
},
)
data = response.json()curl -X POST "https://api.smartship.ro/cost" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0,
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
}'$payload = json_decode('{
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0,
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
}', true);
$ch = curl_init("https://api.smartship.ro/cost");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/cost", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0,
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/cost",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"curier_preferat": 0,
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
},
)
data = response.json(){
"status": 200,
"costs": [
{
"courier_id": 1,
"courier_name": "Cargus",
"courier_logo": "https://smartship.ro/images/logo_curieri/cargus.png",
"cost": 16.13,
"cost_fara_tva": 13.33,
"ramburs_delay": {
"median": 4,
"p75": 5
},
"delivery_date": "2026-07-10",
"pickup_date": "2026-07-09"
},
{
"courier_id": 19,
"courier_name": "FedEx",
"courier_logo": "https://smartship.ro/images/logo_curieri/fedex_logo.png",
"cost": 23.69,
"cost_fara_tva": 19.58,
"ramburs_delay": null,
"delivery_date": "2026-07-10",
"pickup_date": "2026-07-09"
},
{
"courier_id": 6,
"courier_name": "DPD",
"courier_logo": "https://smartship.ro/images/logo_curieri/dpd.png",
"cost": 16.61,
"cost_fara_tva": 13.73,
"ramburs_delay": {
"median": 1,
"p75": 1
},
"delivery_date": "2026-07-10",
"pickup_date": "2026-07-09"
}
],
"total_weight_calculated": 2
}
Emitere AWBCreate AWB
Emite un AWB la curierul ales prin courier_id. Costul se calculează exact ca la /cost și se scade din creditul contului (sau intră pe factura la termen). Recomandare: apelează întâi /cost și lasă clientul/sistemul să aleagă curierul din răspuns.Creates an AWB with the courier chosen via courier_id. The cost is calculated exactly like /cost and deducted from your account credit (or added to your invoice if you pay on terms). Recommended flow: call /cost first and pick the courier from the response.
Câmpuri suplimentareAdditional fields
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
courier_id | integer | obligatoriurequired | ID-ul curierului cu care se emite AWB-ul — vezi tabelul de curieri de mai sus.The ID of the courier the AWB is created with — see the couriers table above. |
Body-ul folosește obiectele comune sender, recipient și content.The body uses the common sender, recipient and content objects.
Coduri de eroareError codes
| 601 | courier_id invalid — nu e în lista curierilor acceptați.Invalid courier_id — not in the accepted courier list. |
| 602 | Curierul nu este disponibil momentan.Courier not available at the moment. |
| 603 | Niciun curier disponibil pentru datele trimise.No courier available for the given data. |
| 605 | Credit insuficient. Răspunsul include creditul disponibil și costul necesar.Not enough credits. The response includes your available credit and the required cost. |
| 606 | Curierul ales nu acceptă ramburs (ex. FedEx).The chosen courier does not support cash on delivery (e.g. FedEx). |
| 806 | easybox: locker_id lipsă sau invalid.easybox: missing or invalid locker_id. |
| 613 | personal_drop_off: 1 cu un courier_id diferit de SameDay (2) sau easybox (12).personal_drop_off: 1 with a courier_id other than SameDay (2) or easybox (12). |
| 6589 | easybox: lockerul ales nu este disponibil momentan.easybox: the chosen locker is currently unavailable. |
| 6590 | easybox: lockerul ales nu acceptă plată ramburs — alege alt locker sau elimină rambursul.easybox: the chosen locker does not support COD payment — choose another locker or remove cash on delivery. |
| 9855 | Costul nu a putut fi calculat pentru curierul ales (verifică datele / disponibilitatea rutei).The cost could not be calculated for the chosen courier (check the data / route availability). |
| 999 | Erori de validare — vezi câmpul erori.Validation errors — see the erori field. |
| 301 | AWB-ul nu s-a emis. Câmpul err conține răspunsul curierului (fără datele trimise de noi: nu mai apar fields la Cargus și datasend la SameDay).The AWB was not created. The err field contains the courier's response (without the data we sent: fields for Cargus and datasend for SameDay no longer appear). |
| 5014, 5015, 5016, 50111 | DPD a refuzat expedierea. Răspunsul conține doar status și message.DPD rejected the shipment. The response contains only status and message. |
curl -X POST "https://api.smartship.ro/awb/new" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"courier_id": 19,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234"
}
}'$payload = json_decode('{
"courier_id": 19,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234"
}
}', true);
$ch = curl_init("https://api.smartship.ro/awb/new");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awb/new", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"courier_id": 19,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234"
}
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/awb/new",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"courier_id": 19,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"parcels": 1,
"weight": 2,
"cash_on_delivery": 0,
"length": 30,
"width": 20,
"height": 10,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234"
}
},
)
data = response.json()curl -X POST "https://api.smartship.ro/awb/new" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"courier_id": 1,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234",
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
}'$payload = json_decode('{
"courier_id": 1,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234",
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
}', true);
$ch = curl_init("https://api.smartship.ro/awb/new");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awb/new", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"courier_id": 1,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234",
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/awb/new",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"courier_id": 1,
"recipient": {
"name": "Ion Vasile",
"address": "Str. Memorandumului 28",
"email": "[email protected]",
"city": 256212,
"phone": "0720123456",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Magazinul Meu SRL",
"address": "Str. Polonă 68",
"email": "[email protected]",
"city": 255154,
"phone": "0720333222",
"country": "RO",
"sector": 1
},
"content": {
"package_content": "Piese auto",
"cash_on_delivery": 0,
"insurance": 0,
"iban": "",
"open_package": 0,
"order_id": "CMD-1234",
"parcels_multiple": [
{
"weight": 2,
"length": 30,
"width": 20,
"height": 10
},
{
"weight": 5,
"length": 40,
"width": 30,
"height": 20
},
{
"weight": 1.5,
"length": 20,
"width": 15,
"height": 10
}
]
}
},
)
data = response.json(){
"status": 200,
"message": "AWB created.",
"awb": "874156063265",
"courier_id": 19,
"courier_name": "FedEx",
"courier_logo": "https://smartship.ro/images/logo_curieri/fedex_logo.png",
"cost": 23.69,
"cost_fara_tva": 19.58,
"pdf_link": "https://smartship.ro/api/CHEIA_TA_API/print/874156063265",
"tracking_url": "https://smartship.ro/t/aB3xK9mQw2"
}
Status și tracking AWBAWB status & tracking
Returnează statusul curent și istoricul de tracking pentru un AWB emis prin contul tău. Statusurile principale: 0 = emis (neridicat), 1 = în tranzit, 2 = livrat, 5/6 = retur, 10 = anulat.Returns the current status and tracking history for an AWB created through your account. Main statuses: 0 = created (not picked up), 1 = in transit, 2 = delivered, 5/6 = returned, 10 = cancelled.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
awb (path) | string | obligatoriurequired | Numărul AWB-ului.The AWB number. |
Coduri de eroareError codes
| 301 | AWB-ul nu există sau nu aparține contului tău.The AWB does not exist or does not belong to your account. |
curl -X GET "https://api.smartship.ro/awb/status/{awb}" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/awb/status/{awb}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awb/status/{awb}", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/awb/status/{awb}",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"awb": "874156063265",
"tracking_link": "https://smartship.ro/t/aB3xK9mQw2",
"awb_status": 1,
"awb_status_desc": "In tranzit",
"carrier": "FedEx",
"tracking": [
{
"date": "2026-07-09 14:20:00",
"event_id": "1",
"description": "Colet ridicat de la expeditor",
"locality": "Bucuresti"
},
{
"date": "2026-07-10 08:15:00",
"event_id": "5",
"description": "In curs de livrare",
"locality": "Cluj-Napoca"
}
]
}
Status AWB după order_idAWB status by order_id
Identic cu /awb/status, dar caută AWB-ul după order_id-ul trimis la emitere — util când sistemul tău nu stochează numărul AWB.Same as /awb/status, but looks up the AWB by the order_id sent at creation — useful when your system does not store the AWB number.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
order_id (path) | string | obligatoriurequired | ID-ul comenzii trimis în content.order_id la emitere.The order ID sent in content.order_id at creation. |
curl -X GET "https://api.smartship.ro/awb/order_id/{order_id}" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/awb/order_id/{order_id}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awb/order_id/{order_id}", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/awb/order_id/{order_id}",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json()Anulare AWBCancel AWB
Anulează un AWB emis prin contul tău. Anularea se face și la curier, iar costul este returnat în creditul contului o singură dată, numai după ce curierul confirmă anularea. Dacă curierul refuză sau nu răspunde, AWB-ul rămâne activ și nu se returnează nimic. Un AWB ridicat deja de curier nu mai poate fi anulat.Cancels an AWB created through your account. The cancellation is propagated to the courier and the cost is refunded to your account credit only once, and only after the courier confirms the cancellation. If the courier rejects it or does not respond, the AWB stays active and nothing is refunded. An AWB already picked up by the courier can no longer be cancelled.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
awb (path) | string | obligatoriurequired | Numărul AWB-ului.The AWB number. |
Coduri de eroareError codes
| 301 | AWB-ul nu există sau nu aparține contului tău.The AWB does not exist or does not belong to your account. |
| 608 | Curierul a refuzat anularea (ex. coletul e deja ridicat) sau nu a răspuns; AWB-ul rămâne activ, fără returnarea costului. Motivul este în câmpul message (răspunsul nu mai conține câmpurile brute res, res_dragon, err). Refuzul DPD răspunde tot 608, cu mesajul „Expedierea nu se poate anula. Mesaj DPD: …” (înainte venea cu status 200).The courier rejected the cancellation (e.g. the parcel was already picked up) or did not respond; the AWB stays active and nothing is refunded. The reason is in the message field (the response no longer contains the raw res, res_dragon, err fields). A DPD rejection also returns 608, with the message "Expedierea nu se poate anula. Mesaj DPD: …" (it used to come with status 200). |
| 205 | AWB-ul este deja anulat (valabil pentru toți curierii). Cererea nu mai ajunge la curier și costul nu se returnează a doua oară.The AWB is already cancelled (applies to all couriers). The request is not sent to the courier again and the cost is not refunded a second time. |
| 206 | Expedierea nu mai poate fi anulată (a fost deja ridicată/livrată), inclusiv la Cargus, când coletul a fost deja preluat.The shipment can no longer be cancelled (already picked up/delivered), including Cargus shipments that have already been collected. |
| 220 | Anularea pentru acest curier nu este disponibilă prin API. Exemplu: PTT Express (14), care nu permite anularea unui AWB emis; AWB-ul rămâne activ și costul nu se returnează (nu mai există răspunsul 200 cu warning: ptt_no_api_cancel).Cancellation for this courier is not available via the API. Example: PTT Express (14), which does not allow cancelling an issued AWB; the AWB stays active and the cost is not refunded (the 200 response with warning: ptt_no_api_cancel no longer exists). |
curl -X GET "https://api.smartship.ro/awb/cancel/{awb}" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/awb/cancel/{awb}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awb/cancel/{awb}", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/awb/cancel/{awb}",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"message": "AWB canceled.",
"awb": "874156063265"
}
Descărcare etichetă (PDF)Download label (PDF)
Returnează eticheta AWB-ului în format PDF, gata de printat. Răspunsul este fișierul PDF (nu JSON).Returns the AWB label as a print-ready PDF. The response is the PDF file itself (not JSON).
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
awb (path) | string | obligatoriurequired | Numărul AWB-ului.The AWB number. |
format (path) | string | opționaloptional | A4 (implicit) sau A6 (etichetă compactă, pentru imprimante de etichete).A4 (default) or A6 (compact label, for label printers). |
curl -X GET "https://api.smartship.ro/awb/print/{awb}/{format}" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/awb/print/{awb}/{format}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awb/print/{awb}/{format}", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/awb/print/{awb}/{format}",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json()Listă județeList counties
Returnează lista județelor, cu ID-urile folosite la căutarea localităților.Returns the list of counties, with the IDs used for locality lookup.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
country (query) | string | opționaloptional | Codul țării. Implicit RO.Country code. Default RO. |
curl -X GET "https://api.smartship.ro/geolocation/counties" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/geolocation/counties");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/geolocation/counties", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/geolocation/counties",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"counties": [
{
"id": 1,
"county": "Alba"
},
{
"id": 2,
"county": "Arad"
}
]
}
Listă localitățiList cities
Returnează localitățile dintr-un județ. ID-ul localității este cel care se trimite în câmpul city la expeditor/destinatar. Recomandare: sincronizează lista o dată pe zi, nu la fiecare cerere.Returns the localities in a county. The locality ID is what you send in the city field for sender/recipient. Recommendation: sync the list once a day, not on every request.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
county (query) | integer | obligatoriurequired | ID-ul județului, din /geolocation/counties.The county ID, from /geolocation/counties. |
loc_sel (query) | string | opționaloptional | Opțional: numele unei localități; dacă e găsită, răspunsul include și city_selected cu ID-ul ei.Optional: a locality name; if found, the response also includes city_selected with its ID. |
curl -X GET "https://api.smartship.ro/geolocation/cities" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/geolocation/cities");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/geolocation/cities", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/geolocation/cities",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"county": {
"id": 13,
"name": "Cluj"
},
"city_selected": null,
"cities": [
{
"id": 256212,
"city": "Cluj-Napoca"
},
{
"id": 256213,
"city": "Apahida"
}
]
}
Listă lockere easyboxList easybox lockers
Returnează lista lockerelor easybox (Sameday) disponibile pentru livrare.Returns the list of easybox (Sameday) lockers available for delivery.
curl -X GET "https://api.smartship.ro/geolocation/easybox" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/geolocation/easybox");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/geolocation/easybox", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/geolocation/easybox",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json()Expeditori salvațiSaved senders
Returnează expeditorii salvați în contul tău (adresele de ridicare). Pentru un singur expeditor: /account/senders/{id} — răspunsul conține obiectul sender în loc de lista senders.Returns the senders saved in your account (pickup addresses). For a single sender: /account/senders/{id} — the response contains a sender object instead of the senders list.
curl -X GET "https://api.smartship.ro/account/senders" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/account/senders");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/account/senders", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/account/senders",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"senders": [
{
"id": 1042,
"nume": "Magazinul Meu SRL",
"telefon": "0720333222",
"email": "[email protected]",
"judet": "Bucuresti",
"localitate": "Bucuresti",
"adresa": "Str. Polonă 68",
"localitate_id": 255154,
"sector": 1
}
]
}
Sold și limită de creditBalance & credit limit
Returnează soldul curent al contului, limita de credit și suma disponibilă pentru emitere. Util înainte de /awb/new, ca să eviți eroarea 605 (credit insuficient).Returns your current account balance, credit limit and the amount available for shipping. Useful before /awb/new to avoid error 605 (not enough credits).
curl -X GET "https://api.smartship.ro/account/balance" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/account/balance");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/account/balance", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/account/balance",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"balance": -657.72,
"credit_limit": 10000,
"payment_on_terms": 1,
"available_for_shipping": 9342.28,
"currency": "RON"
}
Lista expedierilorList shipments
Returnează expedierile contului, paginat, cu filtre — pentru reconciliere și sincronizare în ERP. Statusuri: 0 = emis, 1 = în livrare, 2 = livrat, 5 = refuz primire, 6 = returnat, 10 = anulat.Returns your shipments, paginated, with filters — for ERP reconciliation and sync. Statuses: 0 = created, 1 = in transit, 2 = delivered, 5 = refused, 6 = returned, 10 = cancelled.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
page (query) | integer | opționaloptional | Pagina. Implicit 1.Page number. Default 1. |
per_page (query) | integer | opționaloptional | Rezultate per pagină. Implicit 50, maxim 100.Results per page. Default 50, max 100. |
status (query) | integer | opționaloptional | Filtrează după status (vezi lista de mai sus).Filter by status (see list above). |
date_from / date_to (query) | string | opționaloptional | Interval de date, format YYYY-MM-DD.Date range, YYYY-MM-DD format. |
order_id (query) | string | opționaloptional | Filtrează după ID-ul comenzii tale.Filter by your order ID. |
q (query) | string | opționaloptional | Căutare text (minim 2 caractere) în numărul AWB, numele destinatarului, localitatea destinatarului și ID-ul comenzii.Text search (minimum 2 characters) across AWB number, recipient name, recipient city and order ID. |
courier (query) | integer | opționaloptional | Filtrează după curier — ID-ul numeric returnat în câmpul courier_id.Filter by courier — the numeric ID returned in the courier_id field. |
curl -X GET "https://api.smartship.ro/awbs" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/awbs");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/awbs", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/awbs",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"total_awbs_count": 583,
"current_page": 1,
"per_page": 50,
"total_pages": 12,
"awbs": [
{
"awb": "874156063265",
"date": "2026-07-09 15:20:03",
"courier_id": 19,
"courier_name": "FedEx",
"status": 2,
"status_desc": "Livrat",
"cost": 19.76,
"cash_on_delivery": 0,
"insurance": 0,
"parcels": 1,
"weight": 1,
"recipient_name": "Ion Vasile",
"recipient_county": "Cluj",
"recipient_city": "Cluj-Napoca",
"order_id": "CMD-1234",
"tracking_url": "https://smartship.ro/t/aB3xK9mQw2"
}
]
}
Disponibilitate ridicare FedExFedEx pickup availability
Pentru AWB-urile FedEx: returnează zilele și intervalele orare în care poate fi programată ridicarea coletului de la expeditor. Folosește valorile returnate la POST /pickup/{awb}.For FedEx AWBs: returns the days and time intervals available for scheduling the parcel pickup from the sender. Use the returned values with POST /pickup/{awb}.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
awb (path) | string | obligatoriurequired | Numărul AWB-ului FedEx.The FedEx AWB number. |
curl -X GET "https://api.smartship.ro/pickup/availability/{awb}" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/pickup/availability/{awb}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/pickup/availability/{awb}", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/pickup/availability/{awb}",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"awb": "874156063265",
"options": [
{
"pickup_date": "2026-07-10",
"schedule_day": "SAME_DAY",
"available": true,
"cutoff_time": "16:30:00",
"default_ready_time": "15:00:00",
"ready_time_options": [
"09:00:00",
"12:00:00",
"15:00:00"
],
"latest_time_options": [
"12:00:00",
"15:00:00",
"18:00:00"
]
}
]
}
Programare ridicare FedExSchedule FedEx pickup
Programează ridicarea coletului FedEx de la adresa expeditorului, în ziua și intervalul ales (din /pickup/availability). Maxim o comandă de ridicare per AWB. Expeditorul primește confirmarea pe email.Schedules the FedEx parcel pickup from the sender address, on the chosen day and interval (from /pickup/availability). Max one pickup per AWB. The sender receives an email confirmation.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
awb (path) | string | obligatoriurequired | Numărul AWB-ului FedEx.The FedEx AWB number. |
Câmpuri suplimentareAdditional fields
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
pickup_date | string | obligatoriurequired | Ziua ridicării, format YYYY-MM-DD.Pickup day, YYYY-MM-DD format. |
ready_time | string | obligatoriurequired | Ora de la care coletul e pregătit, format HH:MM.Time from which the parcel is ready, HH:MM format. |
latest_time | string | obligatoriurequired | Ora până la care e disponibil, format HH:MM.Latest available time, HH:MM format. |
Coduri de eroareError codes
| 302 | AWB-ul nu este FedEx.The AWB is not a FedEx shipment. |
| 305 | Există deja o ridicare programată pe acest AWB.A pickup is already scheduled for this AWB. |
| 998 | FedEx nu a confirmat — verifică intervalul cu /pickup/availability.FedEx did not confirm — check the interval against /pickup/availability. |
curl -X POST "https://api.smartship.ro/pickup/{awb}" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"pickup_date": "2026-07-10",
"ready_time": "12:00",
"latest_time": "18:00"
}'$payload = json_decode('{
"pickup_date": "2026-07-10",
"ready_time": "12:00",
"latest_time": "18:00"
}', true);
$ch = curl_init("https://api.smartship.ro/pickup/{awb}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/pickup/{awb}", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"pickup_date": "2026-07-10",
"ready_time": "12:00",
"latest_time": "18:00"
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/pickup/{awb}",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"pickup_date": "2026-07-10",
"ready_time": "12:00",
"latest_time": "18:00"
},
)
data = response.json(){
"status": 200,
"message": "Pickup scheduled.",
"awb": "874156063265",
"pickup_confirmation_code": "ABC123",
"location": "CLJA",
"pickup_date": "2026-07-10",
"ready_time": "12:00",
"latest_time": "18:00"
}
FacturiInvoices
Returnează facturile emise către contul tău, paginat, cu link PDF public — pentru reconciliere contabilă alături de /payouts.Returns the invoices issued to your account, paginated, with a public PDF link — for accounting reconciliation alongside /payouts.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
page (query) | integer | opționaloptional | Pagina. Implicit 1.Page number. Default 1. |
per_page (query) | integer | opționaloptional | Rezultate per pagină. Implicit 50, maxim 100.Results per page. Default 50, max 100. |
curl -X GET "https://api.smartship.ro/invoices" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/invoices");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/invoices", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/invoices",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"total_invoices_count": 22,
"current_page": 1,
"per_page": 50,
"total_pages": 1,
"invoices": [
{
"number": "SS1283958963",
"date": "2026-07-01",
"due_date": "2026-07-15",
"total": 1240.5,
"currency": "RON",
"pdf_link": "https://smartship.ro/factura/xxxxxxxx"
}
]
}
Listă deconturi rambursList COD payouts
Returnează deconturile de ramburs virate către contul tău, paginat. Fiecare decont are un număr, dată, valoare totală și IBAN-ul destinație.Returns the cash-on-delivery payouts transferred to your account, paginated. Each payout has a number, date, total value and destination IBAN.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
page (query) | integer | opționaloptional | Pagina. Implicit 1.Page number. Default 1. |
per_page (query) | integer | opționaloptional | Rezultate per pagină. Implicit 50, maxim 100.Results per page. Default 50, max 100. |
curl -X GET "https://api.smartship.ro/payouts" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/payouts");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/payouts", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/payouts",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"total_payouts_count": 128,
"current_page": 1,
"per_page": 50,
"total_pages": 3,
"payouts": [
{
"number": "PN472375",
"date": "2026-07-08",
"client": "Magazinul Meu SRL",
"valoare": 4820.5,
"iban": "RO49AAAA1B31007593840000",
"awb_count": 37
}
]
}
Detalii decontPayout details
Returnează detaliile unui decont: liniile componente, cu AWB-ul, destinatarul și suma fiecărei încasări incluse.Returns the details of a payout: its component lines with the AWB, recipient and amount of each collected COD included.
ParametriParameters
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
number (path) | string | obligatoriurequired | Numărul decontului, din /payouts. Ex: PN472375.The payout number, from /payouts. E.g. PN472375. |
curl -X GET "https://api.smartship.ro/payouts/{number}" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/payouts/{number}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/payouts/{number}", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/payouts/{number}",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"payout": {
"number": "PN472375",
"date": "2026-07-08",
"iban": "RO49AAAA1B31007593840000",
"value": 4820.5,
"lines": [
{
"date": "2026-07-07",
"number": "PN472375",
"value": 250,
"recipient": "Ion Vasile",
"awb": "874156063265"
}
]
}
}
Solicită ofertă transport (marfă grea)Request a transport offer (heavy freight)
Pentru marfă grea/voluminoasă (peste pragul standard), unde curierii obișnuiți nu sunt potriviți, poți cere o ofertă de transport dedicată. Trimiți detaliile expedierii + parametrii de transport, iar echipa SmartShip revine cu o ofertă (preț, transportator, termen). Verifici starea cu GET /transport-offer/{ref} și accepți/refuzi când oferta e gata. La acceptare se emite automat un AWB SmartShip Delivery și se scade prețul ofertei din credit.For heavy/oversized freight (above the standard threshold), where ordinary couriers do not fit, you can request a dedicated transport offer. You send the shipment details + transport parameters and the SmartShip team returns an offer (price, carrier, term). Poll the status with GET /transport-offer/{ref} and accept/reject once the offer is ready. On acceptance a SmartShip Delivery AWB is created automatically and the offer price is deducted from your credit.
Câmpuri suplimentareAdditional fields
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
content.weight | number | obligatoriurequired | Greutate totală (kg).Total weight (kg). |
content.parcels | integer | opționaloptional | Număr colete/paleți. Implicit 1.Number of parcels/pallets. Default 1. |
content.length/width/height | integer | opționaloptional | Dimensiuni (cm).Dimensions (cm). |
content.truck_type | string | opționaloptional | Tip camion dorit: box, prelata, platforma, basculanta, cisterna, container, agabaritic, autotransportator, cap_tractor.Desired truck type: box, prelata, platforma, basculanta, cisterna, container, agabaritic, autotransportator, cap_tractor. |
content.groupage / adr / temperature_controlled | boolean | opționaloptional | Acceptă grupaj / marfă ADR / necesită temperatură controlată.Accepts groupage / ADR goods / requires temperature control. |
content.budget | number | opționaloptional | Buget estimativ (lei), orientativ pentru ofertă.Estimated budget (RON), a hint for the offer. |
content.pickup_deadline / delivery_deadline | string | opționaloptional | Termene dorite de preluare/livrare (text liber).Desired pickup/delivery terms (free text). |
content.message | string | opționaloptional | Detalii suplimentare pentru echipă.Extra details for the team. |
content.client_reference | string | opționaloptional | Referința ta internă (cod comandă etc.). O returnăm în GET și o afișăm peste tot (panou, emailuri).Your internal reference (order code, etc.). Returned in GET and shown everywhere (panel, emails). |
Body-ul folosește obiectele comune sender, recipient și content.The body uses the common sender, recipient and content objects.
Coduri de eroareError codes
| 999 | Erori de validare (câmpul erori le listează).Validation errors (listed in erori). |
| 422 | Greutate sub pragul minim pentru solicitare de ofertă transport (marfă grea). Câmpul min_weight indică pragul. Sub prag, folosește /cost + /awb/new.Weight below the minimum threshold for a transport offer request (heavy freight). The min_weight field shows the threshold. Below it, use /cost + /awb/new. |
| 301 | Cheie API invalidă.Invalid API key. |
curl -X POST "https://api.smartship.ro/transport-offer" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"recipient": {
"name": "Fabrica X SRL",
"address": "Str. Industriei 5",
"email": "[email protected]",
"city": 253300,
"phone": "0731234567",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Depozit Central SRL",
"address": "Str. Logisticii 10",
"email": "[email protected]",
"city": 252424,
"phone": "0721234567",
"country": "RO",
"sector": 0
},
"content": {
"weight": 900,
"parcels": 2,
"length": 200,
"width": 120,
"height": 150,
"truck_type": "prelata",
"groupage": true,
"adr": false,
"temperature_controlled": false,
"budget": 1500,
"pickup_deadline": "1-2 zile",
"delivery_deadline": "3-5 zile",
"message": "Marfă paletizată, descărcare cu stivuitor.",
"client_reference": "CMD-4821"
}
}'$payload = json_decode('{
"recipient": {
"name": "Fabrica X SRL",
"address": "Str. Industriei 5",
"email": "[email protected]",
"city": 253300,
"phone": "0731234567",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Depozit Central SRL",
"address": "Str. Logisticii 10",
"email": "[email protected]",
"city": 252424,
"phone": "0721234567",
"country": "RO",
"sector": 0
},
"content": {
"weight": 900,
"parcels": 2,
"length": 200,
"width": 120,
"height": 150,
"truck_type": "prelata",
"groupage": true,
"adr": false,
"temperature_controlled": false,
"budget": 1500,
"pickup_deadline": "1-2 zile",
"delivery_deadline": "3-5 zile",
"message": "Marfă paletizată, descărcare cu stivuitor.",
"client_reference": "CMD-4821"
}
}', true);
$ch = curl_init("https://api.smartship.ro/transport-offer");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/transport-offer", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"recipient": {
"name": "Fabrica X SRL",
"address": "Str. Industriei 5",
"email": "[email protected]",
"city": 253300,
"phone": "0731234567",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Depozit Central SRL",
"address": "Str. Logisticii 10",
"email": "[email protected]",
"city": 252424,
"phone": "0721234567",
"country": "RO",
"sector": 0
},
"content": {
"weight": 900,
"parcels": 2,
"length": 200,
"width": 120,
"height": 150,
"truck_type": "prelata",
"groupage": true,
"adr": false,
"temperature_controlled": false,
"budget": 1500,
"pickup_deadline": "1-2 zile",
"delivery_deadline": "3-5 zile",
"message": "Marfă paletizată, descărcare cu stivuitor.",
"client_reference": "CMD-4821"
}
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/transport-offer",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"recipient": {
"name": "Fabrica X SRL",
"address": "Str. Industriei 5",
"email": "[email protected]",
"city": 253300,
"phone": "0731234567",
"country": "RO",
"sector": 0
},
"sender": {
"name": "Depozit Central SRL",
"address": "Str. Logisticii 10",
"email": "[email protected]",
"city": 252424,
"phone": "0721234567",
"country": "RO",
"sector": 0
},
"content": {
"weight": 900,
"parcels": 2,
"length": 200,
"width": 120,
"height": 150,
"truck_type": "prelata",
"groupage": true,
"adr": false,
"temperature_controlled": false,
"budget": 1500,
"pickup_deadline": "1-2 zile",
"delivery_deadline": "3-5 zile",
"message": "Marfă paletizată, descărcare cu stivuitor.",
"client_reference": "CMD-4821"
}
},
)
data = response.json(){
"status": 200,
"message": "Solicitare înregistrată.",
"ref": "OFT-2026-00123",
"request_status": "new"
}
Verifică oferta de transportCheck the transport offer
Întoarce starea solicitării și oferta primită (când e gata). Interoghează oricând ca să vezi dacă echipa a revenit cu o ofertă. request_status: new, in_review, offered, accepted, rejected (ai refuzat oferta), declined (SmartShip nu a putut oferi o variantă), cancelled, expired, completed. La rejected/declined, resolution_message conține motivul (dacă a fost dat). Când offer.acceptable = true, poți accepta.Returns the request status and the offer (once ready). Poll it anytime to see whether the team returned an offer. request_status: new, in_review, offered, accepted, rejected (you rejected the offer), declined (SmartShip could not provide an option), cancelled, expired, completed. For rejected/declined, resolution_message holds the reason (if given). When offer.acceptable = true, you can accept.
Coduri de eroareError codes
| 404 | Solicitarea nu există (sau nu e a contului tău).Request not found (or not yours). |
curl -X GET "https://api.smartship.ro/transport-offer/{ref}" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/transport-offer/{ref}");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/transport-offer/{ref}", {
method: "GET",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.get(
"https://api.smartship.ro/transport-offer/{ref}",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"ref": "OFT-2026-00123",
"client_reference": "CMD-4821",
"request_status": "offered",
"resolution_message": null,
"created_at": "2026-08-13 10:20:00",
"shipment": {
"weight": 900,
"parcels": 2,
"dimensions": {
"length": 200,
"width": 120,
"height": 150
},
"sender_city": 252424,
"recipient_city": 253300,
"truck_type": "prelata",
"groupage": true,
"adr": false,
"temperature_controlled": false
},
"offer": {
"price": 1500,
"carrier": "Transportator Partener SRL",
"delivery_term": "3-5 zile lucrătoare",
"valid_until": "2026-08-20",
"message": "Preț valabil pentru încărcare paletizată.",
"expired": false,
"acceptable": true
},
"awb": null
}
Acceptă oferta de transportAccept the transport offer
Acceptă oferta primită. Se emite automat un AWB SmartShip Delivery pentru expediere și se scade prețul ofertei din creditul contului (verificat înainte). Idempotent: re-apelarea întoarce același AWB. Răspunsul conține AWB-ul și link-ul de tracking.Accepts the offer. A SmartShip Delivery AWB is created automatically and the offer price is deducted from your account credit (checked beforehand). Idempotent: calling again returns the same AWB. The response contains the AWB and the tracking link.
Coduri de eroareError codes
| 409 | Nu există o ofertă activă de acceptat.No active offer to accept. |
| 410 | Oferta a expirat.The offer has expired. |
| 601 | Credite insuficiente pentru prețul ofertei.Not enough credit for the offer price. |
curl -X POST "https://api.smartship.ro/transport-offer/{ref}/accept" \
-H "X-API-KEY: CHEIA_TA_API"$ch = curl_init("https://api.smartship.ro/transport-offer/{ref}/accept");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/transport-offer/{ref}/accept", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/transport-offer/{ref}/accept",
headers={"X-API-KEY": "CHEIA_TA_API"},
)
data = response.json(){
"status": 200,
"message": "Ofertă acceptată. AWB emis.",
"awb": "SMA3170895",
"tracking_url": "https://smartship.ro/t/aB3xK9mQw2",
"cost": 1500
}
Refuză oferta de transportReject the transport offer
Refuză oferta primită. Opțional poți trimite reason (motivul) în body.Rejects the offer. You may optionally send a reason in the body.
Câmpuri suplimentareAdditional fields
| CâmpField | Tip | DescriereDescription | |
|---|---|---|---|
reason | string | opționaloptional | Motivul refuzului (opțional).Reason for rejection (optional). |
Coduri de eroareError codes
| 409 | Oferta nu mai poate fi refuzată.The offer can no longer be rejected. |
curl -X POST "https://api.smartship.ro/transport-offer/{ref}/reject" \
-H "X-API-KEY: CHEIA_TA_API" \
-H "Content-Type: application/json" \
-d '{
"reason": "Am găsit o variantă mai avantajoasă."
}'$payload = json_decode('{
"reason": "Am găsit o variantă mai avantajoasă."
}', true);
$ch = curl_init("https://api.smartship.ro/transport-offer/{ref}/reject");
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => json_encode($payload),
CURLOPT_HTTPHEADER => [
"X-API-KEY: CHEIA_TA_API",
"Content-Type: application/json",
],
]);
$response = json_decode(curl_exec($ch), true);const response = await fetch("https://api.smartship.ro/transport-offer/{ref}/reject", {
method: "POST",
headers: {
"X-API-KEY": "CHEIA_TA_API",
"Content-Type": "application/json",
},
body: JSON.stringify({
"reason": "Am găsit o variantă mai avantajoasă."
}),
});
const data = await response.json();import requests
response = requests.post(
"https://api.smartship.ro/transport-offer/{ref}/reject",
headers={"X-API-KEY": "CHEIA_TA_API"},
json={
"reason": "Am găsit o variantă mai avantajoasă."
},
)
data = response.json(){
"status": 200,
"message": "Ofertă refuzată."
}







