[Python] Amazon Seller Central - SP-API - GET Labels for shipment

Discussão em 'Python' iniciado por Stack, Abril 9, 2025.

  1. Stack

    Stack Membro Participativo

    I'm trying to get labels for shipments I manually created over the Seller Central UI.

    Shipments I created are successfully fetched (Operation: getShipments) and now I have issue when getting the labels.

    Here is my error response from API:

    {'errors': [{'code': 'InvalidInput',
    'message': 'Provided SellerCartonIds are not valid: [[FBAxxxxxxxxxU000001]] for Shipment: [FBAxxxxxxxxx]',
    'details': ''}]}


    If I print labels from UI FBAxxxxxxxxxU000001 label is printed in pdf - also found out about naming here.

    In general, I don't know where to find parameter of package labels PackageLabelsToPrint from GetLabelsDocs, also I'm not sure if this parameter is same as cartonIdList parameter?

    Here is response if you don't provide PackageLabelsToPrint query param in request:

    {'errors': [{'code': 'InvalidInput',
    'message': "1 validation error detected: Value null at 'cartonIdList' failed to satisfy constraint: Member must not be null",
    'details': ''}]}

    Continue reading...

Compartilhe esta Página