Initial Payment

Sending the Initial Payment

During the initial payment, marked by the parameter recurringType with the value INITIAL, the customer is present. Therefore this initial request should contain additional parameters that authenticate the customer like card.cvv for card payments, and also additional checks like 3D secure can be executed.

In Primeiro Pay you get this behaviour out of the box, so all you have to do is to follow the Primeiro Pay Integration guide and add to the /checkouts request in step 1 this parameter:

recurringType=INITIAL

curl https://test.oppwa.com/v1/payments \
 -d "entityId=8a8294184e736012014e78a17a5615ac" \
 -d "amount=92.00" \
 -d "currency=EUR" \
 -d "paymentBrand=VISA" \
 -d "paymentType=DB" \
 -d "card.number=4200000000000000" \
 -d "card.holder=Jane Jones" \
 -d "card.expiryMonth=05" \
 -d "card.expiryYear=2034" \
 -d "card.cvv=123" \
 -d "recurringType=INITIAL" \
 -d "createRegistration=true" \
 -H "Authorization: Bearer OGE4Mjk0MTg0ZTczNjAxMjAxNGU3OGExN2E2YTE1YjB8ZjJGRUtacXRCUA=="

For some cases you might want to use an alternative approach: If the shopper just registered his data without sending a payment at the same time you would have sent his payment directly to the /registrations endpoint as described here. In the same way as described above, the recurringType=INITIAL parameter can be added to the request to indicate that this is the first in a series of recurring payments.

You can find more details on the server-to-server option using either /payments or /registrations in the the tokenisation tutorial.

Last updated