8000 Support Cybersource Tokenization by Wolfizen · Pull Request #260 · BoltApp/sleet · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Apr 29, 2024. It is now read-only.

Support Cybersource Tokenization #260

Merged
merged 3 commits into from
Aug 23, 2023

Conversation

Wolfizen
Copy link
Contributor
@Wolfizen Wolfizen commented Aug 22, 2023

Description

This PR upgrade the CyberSource client to support tokenization using the CyberSource Token Management Service (TMS).

Client consumers can request to tokenize the information in an authorization request by setting the CyberSourceTokenization option with a list of token types they want to create. They can then retrieve the resulting tokens from the CreatedTokens field in the authorization response.

The external API was designed to be processor-agnostic, without using CyberSource-specific terms. While only the token types relevant to CyberSource were defined, they are designed to be generic and reusable for other processors and new token types.

Tests

I added two new unit tests to verify that the presence of the tokenization option in the request results in the addition of tokenization fields in the CyberSource authorization request.

I added an integration test to verify that a CyberSource account is configured for tokenization and can successfully tokenize all supported token types.

@Wolfizen
Copy link
Contributor Author

Current dependencies on/for this PR:

This comment was auto-generated by Graphite.

@Wolfizen Wolfizen requested a review from ellenwei August 23, 2023 17:19
createdTokens[sleet.TokenTypePaymentIdentifier] = paymentInformation.InstrumentIdentifier.ID
}
if paymentInformation.ShippingAddress != nil {
createdTokens[sleet.TokenTypeShippingAddress] = paymentInformation.InstrumentIdentifier.ID
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

paymentInformation.ShippingAddress.ID

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already fixed, I just noticed this as I was reading it a second time 😅

@Wolfizen Wolfizen merged commit d12187b into master Aug 23, 2023
@Wolfizen Wolfizen deleted the winona/cybersourceTokenizationSupport branch August 23, 2023 17:31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0