Create Label
https://bioderma.naos.clicksend.com.mx/api/v1/createLabel
Method: POST
Method Objective:
The service receives an order to create a shipping label for the assigned courier specified in the Carrier key. To generate the label, it is important that the order contains values in the Customer, Packages, and Shipping address keys.
Headers
Accept
Content-Type
Authorization
application/json
application/json
Bearer {ACCESS_TOKEN}
Body RAW
Request:
Field | Type | Description |
---|---|---|
id * | String | Order ID in Magento, this ID is important for the shipment tracking integration in Magento |
created_at | Timestamp | Order creation date |
cancelled_at | Timestamp | Order cancellation date |
financial_status * | String | Order payment status |
payment_gateway * | String | Payment method |
order_number * | String | Order number |
total_price * | Number | Total order price |
subtotal_price * | Number | Subtotal order price |
total_discounts | String | Total with discounts |
[discount_codes] code | String | Discount code |
[discount_codes] amount | Number | Discount amount |
[discount_codes] type | String | Discount type |
[customer] id * | String | Customer ID |
[customer] email * | String | Customer email |
[customer] first_name * | String | Customer first name |
[customer] last_name * | String | Customer last name |
[customer] phone * | String | Customer phone number |
[customer] currency | String | Customer currency type |
[shipping_address] first_name * | String | Customer name, shipping address |
[shipping_address] last_name * | String | Customer last name, shipping address |
[shipping_address] email * | String | Customer email, shipping address |
[shipping_address] phone * | String | Customer phone number, shipping address |
[shipping_address] city * | String | City, shipping address |
[shipping_address] zip * | String | Postal code, shipping address |
[shipping_address] province * | String | Province, shipping address |
[shipping_address] country | String | Country, shipping address |
[shipping_address] address1 * | String | Address, limit 46 characters |
[shipping_address] address2 | String | Address, limit 46 characters |
[shipping_address] external_number | String | External number Address |
[shipping_address] internal_number | String | Internal number Address |
[shipping_address] asent_dest * | String | Colony or settlement, shipping address |
[shipping_address] reference | String | Reference, shipping address |
[shipping_address] latitude | String | Latitude, shipping address |
[shipping_address] longitude | String | Longitude, shipping address |
[shipping_address] country_code | String | Country code, shipping address |
[shipping_address] province_code | String | Province code, shipping address, must be at least 5 characters |
[line_items] product_id * | String | Product ID |
[line_items] grams | Number | Product weight in grams |
[line_items] title * | String | Product name |
[line_items] price * | Number | Product price |
[line_items] quantity * | integer | Product quantity |
[line_items] sku * | String | Product SKU |
[carrier] name_carrier * | String | Name of the courier for which the label is to be created, list of available carrier: Express Estándar |
[carrier] carrier_service * | String | A unique code associated with the courier, list of available carrier service:
estafeta ampm envio_gratis sin_cobertura carrier service is obtained from the coverage rate service |
[carrier] price_carrier * | Number | Shipping price |
Response:
201 OK
Field | Type | Description |
---|---|---|
status_shipment | string | Status response of the request |
carrier | String | Name of the courier |
shipment_number | String | Tracking number |
tracking_url | String | Tracking URL for the shipment |
document_pdf | String | Base64-encoded PDF |
message | String | Success message |
Validation errors: token is required for the request
401 Error
Validation errors: Carrier Service does not exist in the system
404 Error
Field | Type | Description |
---|---|---|
error | string | Name of the field and message, mandatory in the request |
code | String | Error code in the request |