CyberSource / CyberSource/cybersource-rest-samples-node
Payment with flex token example gives INVALID_DATA error
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 43
- Forks
- 66
- Avg merge
- 23m
- Merged PRs (30d)
- 2
Description
When I run the flex token payment example i.e.
node Samples/Payments/Payments/payment-with-flex-token.js
I get the following error in the response:
\"Declined - One or more fields in the request contains invalid data\",\"details\":[{\"field\":\"tokenInformation.jti\",\"reason\":\"INVALID_DATA\"
As these examples are supposed to be self-contained I expected this to work. Does anyone know what the issue is? I did try adding the jti value which you can obtain from the decoded JWT token but this didn't fix the issue.
Also note that the exact same problem applies to the payment-with-flex-token-create-permanent-tms-token.js example.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running Samples/Payments/Payments/payment-with-flex-token.js and payment-with-flex-token-create-permanent-tms-token.js as described in the issue, then inspect how each example builds the Flex token payment request. Trace the tokenInformation.jti handling and verify the examples no longer return INVALID_DATA for that field.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- api, payments
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100