Skip to content
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

Authorize.Net: Support Accept.js PCI Tokens #4406

Closed

Conversation

clintmiller
Copy link

This is a PR that's not so dissimilar from other's I've seen in this project, like #3224 and #2422. There may be others I haven't found. One difference is that this work supports both the "main" gateway AuthorizeNetGateway and the "legacy/almost deprecated" AuthorizeNetCimGateway in one PR. Maybe this is helpful for bringing support for these Accept.js tokens to ActiveMerchant.

I was able to add a test helper that constructs a valid Accept.js token in the Authorize.net sandbox environment, which is essential for writing remote gateway tests against API calls using these tokens. That uses the same API that the Javascript Accept.js client-side library calls to obtain the token.

peterbybel and others added 8 commits April 20, 2022 09:59
This helper contains two functions for adding Accept.js (PCI)
tokenization support to the test suite. One, `accept_js_token` is a
simple dummy/placeholder opaque data structure.

The second, `get_sandbox_acceptjs_token_for_credit_card(credit_ard)`
takes a test credit card object from ActiveMerchant and constructs
an XML API request to the configured Authorize sandbox (in fixtures).
This API request (securePaymentContainerRequest) is essentially what the
Accept.js javascript code does. Since providing opaque data in the the
test suite to validate gateway behavior for tokens requires opaque data
from Authorize, we have to ask them for it as if we were using the
Accept.js scriptsin a browser.
By renaming the helper method `add_accept_js` to `add_opaque_data`, we
clarify that any payment details that produce `:opaque_data` are usable
as payment data.
@clintmiller clintmiller changed the title Support Authorize.Net Accept.js PCI Tokenization Authorize.Net: Support Accept.js PCI Tokens Apr 25, 2022
Copy link

github-actions bot commented Feb 3, 2024

To provide a cleaner slate for the maintenance of the library, this PR/Issue is being labeled stale after 60 days without activity. It will be closed in 14 days unless you comment with an update regarding its applicability to the current build. Thank you!

@github-actions github-actions bot added the Stale label Feb 3, 2024
@github-actions github-actions bot closed this Feb 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants