Download label (New)

Call this endpoint to download the labels of booked shipments for small parcel shipments. You must first submit a label generation request, using the Generate Label API. If the label request is still being processed, the response will return a status of 202 (Accepted). Once the labels are ready, the API response will include a PDF file containing
the labels.

Note: This page shows examples using only the required parameters and inputs for downloading labels. For a full list of customization options and additional capabilities, refer to the Marketplace Fulfillment API Reference.

Endpoint

get https://marketplace.walmartapis.com/v4/fulfillment/download-label/?shipmentId={shipmentId}&labelType=Carrier&labelSize=X4_6'

Sample request

curl --request GET \ --url https://marketplace.walmartapis.com/v4/fulfillment/download-label/?shipmentId=0716575WFA&labelType=Carrier&labelSize=X4_6 \
--header 'Content-Type: application/json' \
--header 'Authorization: <Authorization>' \
--header 'WM_SEC.ACCESS_TOKEN: <Your access token>' \
--header 'WM_SVC.NAME: Walmart Marketplace' \
--header 'WM_QOS.CORRELATION_ID: 123456abcdef5' \
--header 'Accept: application/json' \
import requests shipment_id = "0716575GDM"
label_type = "Carrier"
label_size = "X4_6" url = f"https://marketplace.walmartapis.com/v4/fulfillment/download-label/?shipmentId={shipment_id}&labelType={label_type}&labelSize={label_size}" headers = { "accept": "application/pdf", "Authorization": "<Authorization>", # Replace with your authorization information "WM_SEC.ACCESS_TOKEN": "<Your access token>", # Replace with your access token "WM_SVC.NAME": "Walmart Marketplace", "WM_QOS.CORRELATION_ID": "123456abcdef5"
} response = requests.get(url, headers=headers) print(response.status_code)
print(response.content) # This will be the PDF binary content

Modify your code

Replace all placeholder values with your actual shipment data before making the API request.

  • Authorization - Replace with your actual Base64-encoded credentials.
  • WM_QOS.CORRELATION_ID - Use a unique correlation UUID to track the request.
  • WM_SEC.ACCESS_TOKEN - Replace with your valid access token obtained through authentication.

Sample response

If the request is still pending, you will see a status pending message. This denotes the download label operation is still in-progress.

{ "status": "OK" "message": "Label is still being generated. Try again shortly."
}

If the request was successful, you will see a status OKmessage. This confirms that the download label operation was completed.

{ "status": "OK"
}

Result

If the label request is still being processed, the response will return a status of 202 Accepted. If the request is successful, the response returns a 200 OK status.