curl --request POST \
--url https://api.{gr4vy_id}.gr4vy.app/payment-services \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"payment_service_definition_id": "stripe-card",
"display_name": "Stripe (Main)",
"fields": [
{
"key": "private_key",
"value": "sk_test_26PHem9AhJZvU623DfE1x4sd"
}
],
"accepted_countries": [
"US",
"GB",
"DE"
],
"accepted_currencies": [
"EUR",
"USD",
"GBP"
],
"three_d_secure_enabled": true,
"merchant_profile": {
"amex": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"dankort": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"discover": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"jcb": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"mastercard": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"unionpay": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"visa": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
}
},
"active": true,
"open_loop": true,
"payment_method_tokenization_enabled": true,
"network_tokens_enabled": true
}'
{
"type": "payment-service",
"id": "faaad066-30b4-4997-a438-242b0752d7e1",
"merchant_account_id": "default",
"payment_service_definition_id": "stripe",
"method": "card",
"display_name": "Stripe",
"status": "pending",
"accepted_currencies": [
"EUR"
],
"accepted_countries": [
"DE"
]
}
Adds a new payment service by providing a custom name and a value for each of the required fields.
curl --request POST \
--url https://api.{gr4vy_id}.gr4vy.app/payment-services \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"payment_service_definition_id": "stripe-card",
"display_name": "Stripe (Main)",
"fields": [
{
"key": "private_key",
"value": "sk_test_26PHem9AhJZvU623DfE1x4sd"
}
],
"accepted_countries": [
"US",
"GB",
"DE"
],
"accepted_currencies": [
"EUR",
"USD",
"GBP"
],
"three_d_secure_enabled": true,
"merchant_profile": {
"amex": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"dankort": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"discover": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"jcb": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"mastercard": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"unionpay": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
},
"visa": {
"merchant_acquirer_bin": "<string>",
"merchant_url": "<string>",
"merchant_acquirer_id": "<string>",
"merchant_name": "<string>",
"merchant_country_code": "<string>",
"merchant_category_code": "<string>"
}
},
"active": true,
"open_loop": true,
"payment_method_tokenization_enabled": true,
"network_tokens_enabled": true
}'
{
"type": "payment-service",
"id": "faaad066-30b4-4997-a438-242b0752d7e1",
"merchant_account_id": "default",
"payment_service_definition_id": "stripe",
"method": "card",
"display_name": "Stripe",
"status": "pending",
"accepted_currencies": [
"EUR"
],
"accepted_countries": [
"DE"
]
}
payment-services.write
scope.Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Request body for activating a payment service.
Returns the created payment service.
An active, configured payment service.
Was this page helpful?