Skip to content

"Invalid Input" error on VendorOrders get_purchase_orders() depending on changedAfter value #433

@robguttman

Description

@robguttman

Describe the bug
Calls to VendorOrders().get_purchase_orders() succeed or fail depending on the value of changedAfter.

To Reproduce
This call succeeds:

VendorOrders().get_purchase_orders(changedAfter="2022-03-05T15:15:48.001000+00:00", nextToken=None)

This call fails:

VendorOrders().get_purchase_orders(changedAfter="2022-03-04T21:00:56.001000+00:00", nextToken=None)

The error response is:

SellingApiBadRequestException: [{'code': 'InvalidInput', 'message': 'Invalid Input', 'details': ''}]

Notice that the only difference is the changedAfter value - both are in ISO-8601 date/time format and both are well within the 7 day range stated in the documentation. These calls also fail:

VendorOrders().get_purchase_orders(changedAfter="2022-03-04T21:00:56.001000", nextToken=None)
VendorOrders().get_purchase_orders(changedAfter="2022-03-04T21:00:56.001", nextToken=None)
VendorOrders().get_purchase_orders(changedAfter="2022-03-04T21:00:56", nextToken=None)

Expected behavior
It's expected that these calls should succeed as long as the changedAfter date is ISO-8601 date/time format and within the 7 day range.

Additional context
I suspect these issues are with the Amazon REST API and not this SDK, but it's hard to know for sure. Also, the API error response message is useless. I also suspect this is the fault of the Amazon API and not this SDK but again, it's hard to know for sure.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions