Skip to content

get_labels asking for value not found in Amazon documentation #1275

Closed

Description

@godlyatheist

Describe the bug
When calling get_labels, error message "sp_api.base.exceptions.SellingApiBadRequestException: [{'code': 'InvalidInput', 'message': "1 validation error detected: Value null at 'cartonIdList' failed to satisfy constraint: Member must not be null", 'details': ''}]". cartonIdList is not a value associated with the getLabels operation according to documentation. The code below used to work without error.

To Reproduce

`from sp_api.base import Marketplaces
from sp_api.api import FulfillmentInbound

credentials = dict(refresh_token='token', lwa_app_id='app_id', lwa_client_secret='secret')

label_blob = FulfillmentInbound(credentials=credentials, marketplace=Marketplaces.US).get_labels(
shipment_id = 'FBA0000000',
PageType = 'PackageLabel_Thermal',
LabelType = ['UNIQUE','PALLET'] )
print(label_blob['DownloadURL'])
`
Expected behavior
No error regarding cartonIdList, returns a URL

Desktop (please complete the following information):

Windows 10 build 19045 VSCode 1.85.1

Additional context

Activity

  1. saleweaver commented on Dec 28, 2023

    @saleweaver
    Owner

    I haven't worked with this endpoint for some time, but if I remember correctly, if the code was working, it must have been for a shipment created with something other than a carton feed. The value you need to pass for this kind of shipment should be this

    image

  2. added
    questionFurther information is requested
    and removed
    bugSomething isn't working
    on Dec 28, 2023
  3. godlyatheist commented on Dec 28, 2023

    @godlyatheist
    Author

    Thank you, I will check my work

  4. Repository owner locked and limited conversation to collaborators on Dec 30, 2023
  5. converted this issue into a discussion #1278 on Dec 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions