Reply
Highlighted
Member
Posts: 2
Registered: ‎02-24-2017

Unclear basic workflow documentation - Accept.js

Where can I get examples of how to pull user payment info (from Authorize.net payment profile) using Accept.js (client side), so that said info never touches the server?

Then, how do I edit/save the payment info using Accept.js

 

Also, how do I create a new payment profile using Accept.js, again, so that the info never touches the server?

 

The documentation provided by Authorize.net is very jumbled and incomplete, with not a lot of coherence. I've read, re-read and scratched my head. Also, emailing support isn't really any help either, because all htey do is reply with cannexd responses that are links to the disjointed documentation that I've already read (and that didn't help).

 

Thank you.

Administrator
Posts: 209
Registered: ‎11-03-2016

Re: Unclear basic workflow documentation - Accept.js

Hi @jima,

 

Accept.js is for one-time transactions. For working with payment profiles stored on the Authorize.Net side, you'd want to check out our Customer Profiles API.

 

One of the uses of the Customer Profiles API is to use the Accept Customer hosted forms to allow customers to enter their credit card details directly, never touching your server.

 

Have a look at the Customer Profiles documentation, and if there are things that are still unclear, please let us know.

-Aaron

Aaron Wright
Developer Evangelist - Authorize.Net

Follow Authorize.Net developer news on Twitter!
Member
Posts: 2
Registered: ‎02-24-2017

Re: Unclear basic workflow documentation - Accept.js

Accept.js is STILL for one-time transactions? I read, back in 2011, that it would "soon be upgraded" to eliminate that limitation. I guess that never happened?

 

I have read a lot about, and played with the Customer Profiles API as well. Same basic problems exist there too, as regards unclear documentation that is quite disjointed, with no clear process flow. This solution, as far as I understand it, isn't ideal because it doesn't seem to offer such things as pre-loading of existing payment data into payment forms (for editing), and I cannot seem to find a way to retrieve the payment data (client-side), for display into our own form, and even if I could, I'm not seeing a method to submit the edit (using my own form) that doesn't involve the data touching our server(s).

 

In part, I understand that there are a lot of potential variances to workflow, but there are at least a couple of really rudimentary/basic workflows that could be clearly walked-through, tutorial style, that would help a ton of people trying to implement.

 

Is there ANY possibility of getting a direct phone call or Skype conversation with someone who could help walk me through this?

Administrator
Posts: 209
Registered: ‎11-03-2016

Re: Unclear basic workflow documentation - Accept.js

Hi @jima,

 

Accept.js has only been in existence less than a year, so I'm not sure what you might have read there. You can use the payment nonce returned from an Accept.js call in an API call to our Customer Profiles API, so maybe that's what you had seen. You can use this payment nonce in most API calls that might have previously required you to send an actual credit card number.

 

An example would be if you created your own form to manage a customer's payment profile. You can load the existing payment profile information (with masked card numbers) using our API. Then you can have the customer enter their new credit card number which you convert to a nonce using Accept.js. Then, you'd call updateCustomerPaymentProfileRequest (for example), sending this block:

    <payment>
      <opaqueData>
        <dataDescriptor>COMMON.ACCEPT.INAPP.PAYMENT</dataDescriptor>
        <dataValue>9471056021205027705001</dataValue>
      </opaqueData>  
    </payment>

instead of this block:

    <payment>
      <creditCard>
        <cardNumber>4111111111111111</cardNumber>
        <expirationDate>2026-01</expirationDate>
      </creditCard>
    </payment>

So, if that's the kind of usage you're referring to, my apologies for the misunderstanding. I'll clarify my earlier statement. Instead of saying "Accept.js is for one-time transactions", it'd be more clear to say "Accept.js is for the conversion of payment card data into a single use payment token (or 'payment nonce') that can be used in place of the card data in a subsequent request to the Authorize.Net API". So, Accept.js doesn't directly support profiles, but it doesn't directly support anything. It's just the preparatory step to get you back some data that can be used in whatever your next step is.

 

Accept.js documentation is currently in the middle of a big revamp internally, so I'll make sure that some additional text gets added clarifying that concept.

 

Our other documentation (including the Customer Profile documentation) will be getting that kind of revamp soon. We know there could be more information there, in a clearer fashion. It's a big priority of mine personally to make it happen. We just aren't able to turn it around overnight.

 

I'm happy to help walk you through all of this, but I'd prefer to do it here so that the process can be documented for anyone coming by looking for help later.

 

Let's start by describing your workflow. Are you trying to have every form for profile creation or update hosted on your site, but not have the card data hit your server? If so, you can definitely accomplish that using a combination of Accept.js and the Customer Profiles section of our API.

 

Or, are you wanting to use hosted forms on our side (like for ease of development)? That would use the "Accept Customer" forms detailed in the Customer Profiles documentation. You'd request a token with the details of what you want to do, then use that token in a form post from the customer's browser to our server. The customer's browser then loads up a form customized to what you were trying to do (create a profile, update a profile, etc.)

-Aaron

Aaron Wright
Developer Evangelist - Authorize.Net

Follow Authorize.Net developer news on Twitter!