-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NextToken query param encoding error #11
Comments
wish-master
added a commit
to wish-master/selling-partner-api-sdk
that referenced
this issue
Oct 9, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi guys,
The SP API returns the following error while providing a NextToken:
{ "errors": [ { "code": "InvalidInput", "message": "We could not decode your NextToken. Possible reasons include: a transmission error, improper quoting or a truncation problem.", "details": "" } ] }
The NextToken provided by Amazon was :
Abjn8igatlp/YYuZQbKv1QafEPREmauvizt1MIhPYZacG7+f+fPp64jrgtdOS1N57G4NpRGNu/aHNkPWD9qzA98ytOVgN7d/KyNtf5fepe1HnywimSSQDRGmrXufpM2ZiOxqNBW1w66S68vI7Bqws+weLxD7b1CV0+mtVKXnPdiRy61Whm3WZuhTmqWGK9KSllhc4XvGqg5e0zIeaOVNezxWEXvdeDL7Zg54wKetRXLQp0zNIsrUkDRYOWseR6JecVkxA+q0fZYwE7+t4NjazyEZY027dXAVTSGshRBy6ZQghiSCZ3PIKk1DNEBSp27+sHmkcG/7LbJaHp4fabNqjZzx3vUsLaRi/IBQt3FQQzIESYt/Ti7LLVglFmAtnnBygOSv44FefAZ4FtaSjjwjko+Dl5QhYGtU3tAf+LbCLV+BA1KyEG2j/Km8ERy2ZulUV3HBz6/4NisG51E48qXehQ==
And the encoded NextToken passed in the query param by the SDK is :
NextToken=Abjn8igatlp%2FYYuZQbKv1QafEPREmauvizt1MIhPYZacG7%20f%20fPp64jrgtdOS1N57G4NpRGNu%2FaHNkPWD9qzA98ytOVgN7d%2FKyNtf5fepe1HnywimSSQDRGmrXufpM2ZiOxqNBW1w66S68vI7Bqws%20weLxD7b1CV0%20mtVKXnPdiRy61Whm3WZuhTmqWGK9KSllhc4XvGqg5e0zIeaOVNezxWEXvdeDL7Zg54wKetRXLQp0zNIsrUkDRYOWseR6JecVkxA%20q0fZYwE7%20t4NjazyEZY027dXAVTSGshRBy6ZQghiSCZ3PIKk1DNEBSp27%20sHmkcG%2F7LbJaHp4fabNqjZzx3vUsLaRi%2FIBQt3FQQzIESYt%2FTi7LLVglFmAtnnBygOSv44FefAZ4FtaSjjwjko%20Dl5QhYGtU3tAf%20LbCLV%20BA1KyEG2j%2FKm8ERy2ZulUV3HBz6%2F4NisG51E48qXehQ%3D%3D
A URL decode of the encoded token returns :
Abjn8igatlp/YYuZQbKv1QafEPREmauvizt1MIhPYZacG7 f fPp64jrgtdOS1N57G4NpRGNu/aHNkPWD9qzA98ytOVgN7d/KyNtf5fepe1HnywimSSQDRGmrXufpM2ZiOxqNBW1w66S68vI7Bqws weLxD7b1CV0 mtVKXnPdiRy61Whm3WZuhTmqWGK9KSllhc4XvGqg5e0zIeaOVNezxWEXvdeDL7Zg54wKetRXLQp0zNIsrUkDRYOWseR6JecVkxA q0fZYwE7 t4NjazyEZY027dXAVTSGshRBy6ZQghiSCZ3PIKk1DNEBSp27 sHmkcG/7LbJaHp4fabNqjZzx3vUsLaRi/IBQt3FQQzIESYt/Ti7LLVglFmAtnnBygOSv44FefAZ4FtaSjjwjko Dl5QhYGtU3tAf LbCLV BA1KyEG2j/Km8ERy2ZulUV3HBz6/4NisG51E48qXehQ==
As you can see the
+
characters have been converted to spaces... destroying the token.Any idea to solve this please?
Thanks
The text was updated successfully, but these errors were encountered: