Skip to content

Create Package Shipment​

POST
/api/v1/shipment/shipments/packages

Creates a package shipment in a single request and registers it with UPS. If the operation cannot be completed, the shipment stays in the panel as a draft (Not generated); a new attempt without id creates a new draft.

Parameters​

Header Parameters

Authorization*

Token returned by the Get Token request, with the Bearer prefix

Typestring
Required
Example"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIn0.signature"
Accept-Language

Language of the name fields in the response (country, unit of measure, status and package additional fee names) and of validation messages. English when it starts with en (e.g. en, en-US), Turkish otherwise. Success, business rule, authorization and 503 messages are always in Turkish.

Typestring
Examples
"tr"
"en"
Default"tr"

Request Body​

application/json
JSON
{
"recipientAddress": {
"countryId": 3,
"firstName": "JOHN",
"lastName": "DOE",
"company": "",
"email": "",
"phone": "2125550100",
"zipCode": "10001",
"state": "NY",
"city": "NEW YORK",
"address1": "350 5TH AVE",
"address2": ""
},
"packages": [
{
"length": 10,
"size": 10,
"height": 10,
"weight": 10,
"piece": 1
}
],
"description": "DRESS",
"carrierId": 1,
"currencyId": 1,
"exportCodeId": 10,
"products": [
{
"hsCode": "620442",
"description": "COTTON DRESS",
"piece": 1,
"unitPrice": 10,
"unitOfMeasureCode": "PCS",
"originCountryCode": "TR"
}
],
"referenceNumbers": [
"REF1"
],
"taxNumber": "",
"deliveryTaxType": 1,
"previousTaxStatus": 2,
"freight": 5,
"discount": 0,
"other": 0,
"isRecipientCompany": false,
"taxIdentificationNumber": "",
"isDiffBillingAddress": false,
"billingAddress": {
"countryId": 3,
"firstName": "JOHN",
"lastName": "DOE",
"company": "",
"email": "",
"phone": "2125550100",
"zipCode": "10001",
"state": "NY",
"city": "NEW YORK",
"address1": "350 5TH AVE",
"address2": ""
},
"senderAddressId": 12,
"newSenderAddress": {
"title": "MERKEZ DEPO",
"county": {
"id": 268,
"name": "KADIKOY"
},
"city": {
"id": 34,
"name": "ISTANBUL"
},
"address1": "CAFERAGA MAH. MODA CAD. NO 7",
"address2": "DAIRE 6",
"firstName": "AHMET",
"lastName": "YILMAZ",
"company": "ORNEK TEKSTIL",
"email": "[email protected]",
"phone": "5321234567",
"zipCode": "34710",
"taxType": 2,
"tcNo": "11111111111",
"taxNumber": "1234567890"
},
"singlePointImportId": 45,
"customsAccountNumber": "string",
"customsAccountZipCode": "string",
"comment": "string",
"id": 2102
}

Responses​

Package shipment created

application/json
JSON
{
"success": true,
"message": "Gönderi oluşturuldu",
"data": {
"id": 0,
"barcode": "string",
"trackingNumber": "string",
"trackingUrl": "string",
"description": "string",
"comment": "string",
"type": {
"id": 0,
"slug": "string",
"name": "string"
},
"status": {
"id": 0,
"slug": "string",
"name": "string"
},
"activityStatus": {
"id": 0,
"slug": "string",
"name": "string"
},
"currency": {
"id": 0,
"code": "string",
"name": "string"
},
"exportCode": {
"id": 0,
"code": "string",
"name": "string"
},
"carrier": {
"id": 0,
"slug": "string",
"name": "string",
"service": "string",
"logoUrl": "string"
},
"organization": {
"id": 0,
"name": "string"
},
"singlePointImport": {
"id": 0,
"name": "string",
"upsShipmentId": "string"
},
"recipientAddress": {
"id": 0,
"firstName": "string",
"lastName": "string",
"company": "string",
"email": "string",
"phone": "string",
"state": "string",
"city": "string",
"zipCode": "string",
"address1": "string",
"address2": "string",
"country": {
"id": 0,
"code": "string",
"name": "string",
"flags": {
"w20": "string",
"w40": "string"
},
"phoneCode": "string",
"isUpsService": true,
"tax": {
"type": "string",
"maxValidPrice": 0
}
}
},
"senderAddress": {
"id": 0,
"firstName": "string",
"lastName": "string",
"company": "string",
"email": "string",
"phone": "string",
"state": "string",
"city": "string",
"zipCode": "string",
"address1": "string",
"address2": "string",
"country": {
"id": 0,
"code": "string",
"name": "string",
"flags": {
"w20": "string",
"w40": "string"
},
"phoneCode": "string",
"isUpsService": true,
"tax": {
"type": "string",
"maxValidPrice": 0
}
}
},
"billingAddress": {
"id": 0,
"firstName": "string",
"lastName": "string",
"company": "string",
"email": "string",
"phone": "string",
"state": "string",
"city": "string",
"zipCode": "string",
"address1": "string",
"address2": "string",
"country": {
"id": 0,
"code": "string",
"name": "string",
"flags": {
"w20": "string",
"w40": "string"
},
"phoneCode": "string",
"isUpsService": true,
"tax": {
"type": "string",
"maxValidPrice": 0
}
}
},
"referenceNumbers": [
"string"
],
"taxIdentificationNumber": "string",
"deliveryTaxType": 0,
"previousTaxStatus": 0,
"isGuarantee": true,
"isOutsource": true,
"customsAccountNumber": "string",
"customsAccountZipCode": "string",
"packages": [
{
"id": 0,
"desi": 0,
"size": 0,
"height": 0,
"length": 0,
"weight": 0,
"trackingNumber": "string",
"activityStatus": {
"id": 0,
"slug": "string",
"name": "string"
}
}
],
"products": [
{
"id": 0,
"hsCode": "string",
"description": "string",
"piece": 0,
"unitPrice": 0,
"unitOfMeasure": {
"id": 0,
"code": "string",
"name": "string"
},
"originCountry": {
"id": 0,
"code": "string",
"name": "string"
}
}
],
"createdAt": "string",
"updatedAt": "string"
}
}

Playground​

Headers
Body

Samples​

cURL
JavaScript
PHP
Python