Hello,
I have an application that currently allows for signing people up for monthly membership plans. We are on the Clover Flex Gen 2 only. During the sign up flow we currently open up a WebView that has a EComm iFrame in which the CC info is manually entered. Once this form submits a token back to our server we create a customer and save this token on file in order to have a multi-pay token, following the directions here: https://docs.clover.com/docs/ecommerce-saving-card
To make the sign up process easier we are trying to use the Rest Pay Display API in order to get the eComm compatible token instead of the manual form entry via iFrame. We are using this endpoint: https://docs.clover.com/reference/request_token
For some reason we are getting back a 402 when taking the token returned from the Rest Pay Display API and attempting to create a customer:
%{"error" => %{"code" => "invalid_cvc", "message" => "CVV not found during card verification for Clover token clv_1TSTSqeJUN9uekt2gce6aEnx", "type" => "card_error"}, "message" => "402 Payment Required"}
Is this expected? I've seen other posts in the forum about this error but those seem to be related to using the token directly for payment multiple times. We are only trying to post the customer right now, and doing this exact flow with the iFrame approach works fine. Are we missing a step in order to use the token returned from the Rest Pay Display API?
Also, is there any way to enable a button to exit the Clover Pay Display API? Currently on success/error we just have it display a message but the device just hangs. The 4 corner touch to exit is not the easiest approach, have to do it multiple times as it doesn't sense all 4 touches every time.
Update: So I did update the initial request to get the token to include manual entry as an option. Not sure if this matters but I was testing with the provided test card that came with the Flex device, is that an issue? I manually enter in the success Discover card from here: https://docs.clover.com/docs/testing-us-payment-flows, looks like it gets past the 402 response but we do get a 500 now:
body: %{ "code" => "processing_error", "message" => "There was an error communicating with the server. Please try again.: TokenizationResult: null", "requestId" => "e0747e54-ec97-4a10-af33-b4c89f6c484b", "requestType" => "REQUEST_TOKEN", "type" => "api_error" }