Create a Payment Customer
The API endpoint to create a Payment Customer is POST https://connect.secucard.com/api/v2/Payment/Customers.
Example Request
POST /api/v2/Payment/Customers HTTP/1.1
Host: connect-testing.secupay-ag.de
Authorization: Bearer qb56tjj1bcvo9n2nj4u38k84lo
Content-Type: application/json
Accept: application/json
{
"contact"
: {
"salutation"
:
"Mr."
,
"forename"
:
"Max"
,
"surname"
:
"Mustermann"
,
"address"
: {
"street"
:
"Max-Muster-Str."
,
"street_number"
:
"25a"
,
"postal_code"
:
"09555"
,
"city"
:
"Musterstadt"
,
"country"
:
"DE"
,
"additional_address_data"
:
"Whg. 202"
},
"email"
:
"mmustermann@example.net"
,
"mobile"
:
"+49 177 5555555"
,
"phone"
:
"+49 555 5555555"
}
}
If everything is fine, the API responds with 200 OK:
Example Response
HTTP/1.1 200 OK
Content-Type: application/json
...
{
"object"
:
"payment.customers"
,
"id"
:
"PCU_38RG7MHRE2NJTPFMXRYQP3NKW6GVAZ"
,
"merchant"
: {
"object"
:
"general.merchants"
,
"id"
:
"MRC_DNUWH3RE6J6TNRGW0X607S294W0XO3"
},
"contact"
: {
"salutation"
:
"Mr."
,
"forename"
:
"Max"
,
"surname"
:
"Mustermann"
,
"address"
: {
"street"
:
"Max-Muster-Str."
,
"street_number"
:
"25a"
,
"postal_code"
:
"09555"
,
"city"
:
"Musterstadt"
,
"country"
:
"DE"
,
"additional_address_data"
:
"Whg. 202"
},
"email"
:
"mmustermann@example.net"
,
"mobile"
:
"+49 177 5555555"
,
"phone"
:
"+49 555 5555555"
}
}
The most important field is id. It identifies this particular Payment Customer object. You will need it to create a Payment Container, and to authorize the payment.