Get shipment labels

GET REST API request that returns download link for shipping label. Fetching is done by the shipment id which is passed in the URL as a variable. Also, it is possible to specify a format, as a request parameter, in which the label will be downloaded. In the response, a download link will be returned, and with that link, it is possible to download the shipping label as a .zip file, which is connected to the supplier shipment.

The parameter format specifies in which format will the label be downloaded. Possible values are PDF and ZPL. This parameter is optional, if omitted, PDF will be downloaded.

Request

HTTP MethodGET
URLStagehttps://api.qa2.ananastest.com/ws-inventory/api/v1/supplier-integration/shipment/{shipmentId}/labels
Productionhttps://api.ananas.rs/ws-inventory/api/v1/supplier-integration/shipment/{shipmentId}/labels
HTTP Headers
Header nameHeader value
AuthorizationBearer {access_token}
URL Parameters
Parameter nameParameter description
formatSpecifies in which format will the label be downloaded (PDF, ZPL)

Response

There is one scenario where the endpoint will return a status of 4xx:

  • If shipment, specified in the URL, does not exist, or if it does not belong to the supplier - 404

Response Body:

Download link is a URL (Response body)

JSON

Click to copy
Success!
{
  "link": "https://ananas-dev1-logistics.s3.eu-central-1.amazonaws.com/consignment/309/9Z0DG-G6ITS-DS-1/9Z0DG-G6ITS-DS-1.zip?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20221115T104016Z&X-Amz-SignedHeaders=host&X-Amz-Expires=600&X-Amz-Credential=AKIA22VGE46BU67P2UMV%2F20221115%2Feu-central-1%2Fs3%2Faws4_request&X-Amz-Signature=c0dfc17dabf347d8728bb61ee699f69b5ae1bc8efb5a3dd1be0fb2a670a49df3112",
};
Copyright © Ananas 2023. All right reserved.