curl --request POST \
--url https://prod01-apigw.{customer_name}.fabric.zone/ext-stripe/payment-method \
--header 'Content-Type: application/json' \
--data '{
"type": "card",
"metadata": {
"keyName": "key value"
},
"card": {
"number": "4242424242424242",
"exp_month": 6,
"exp_year": 21,
"cvc": "021"
},
"billing_details": {
"address": {
"line1": "3520 Millenio",
"line2": "Crowley Drive",
"city": "Vancouver",
"state": "BC",
"country": "CA",
"postal_code": "V5R 6G9"
},
"name": "John Smith",
"email": "john@fabric.inc",
"phone": "123-456-7890"
}
}'
{
"id": "pm_1Ij5zBJxr7zyIFb9u3cfbHJG",
"object": "payment_method",
"card": {
"brand": "visa",
"checks": {
"address_line1_check": "unchecked",
"address_postal_code_check": "unchecked",
"cvc_check": "unchecked"
},
"country": "US",
"exp_month": 2,
"exp_year": 2023,
"fingerprint": "lf55OlXOOfjcvjan",
"funding": "credit",
"generated_from": null,
"last4": "4242",
"networks": {
"available": [
"visa"
],
"preferred": null
},
"three_d_secure_usage": {
"supported": true
},
"wallet": null
},
"created": 1619111201,
"customer": null,
"livemode": false,
"metadata": {},
"type": "card",
"billing_details": {
"address": {
"line1": "3520 Millenio",
"line2": "Crowley Drive",
"city": "Vancouver",
"state": "BC",
"country": "CA",
"postal_code": "V5R 6G9"
},
"name": "John Smith",
"email": "john@fabric.inc",
"phone": "123-456-7890"
}
}
Create payment method
curl --request POST \
--url https://prod01-apigw.{customer_name}.fabric.zone/ext-stripe/payment-method \
--header 'Content-Type: application/json' \
--data '{
"type": "card",
"metadata": {
"keyName": "key value"
},
"card": {
"number": "4242424242424242",
"exp_month": 6,
"exp_year": 21,
"cvc": "021"
},
"billing_details": {
"address": {
"line1": "3520 Millenio",
"line2": "Crowley Drive",
"city": "Vancouver",
"state": "BC",
"country": "CA",
"postal_code": "V5R 6G9"
},
"name": "John Smith",
"email": "john@fabric.inc",
"phone": "123-456-7890"
}
}'
{
"id": "pm_1Ij5zBJxr7zyIFb9u3cfbHJG",
"object": "payment_method",
"card": {
"brand": "visa",
"checks": {
"address_line1_check": "unchecked",
"address_postal_code_check": "unchecked",
"cvc_check": "unchecked"
},
"country": "US",
"exp_month": 2,
"exp_year": 2023,
"fingerprint": "lf55OlXOOfjcvjan",
"funding": "credit",
"generated_from": null,
"last4": "4242",
"networks": {
"available": [
"visa"
],
"preferred": null
},
"three_d_secure_usage": {
"supported": true
},
"wallet": null
},
"created": 1619111201,
"customer": null,
"livemode": false,
"metadata": {},
"type": "card",
"billing_details": {
"address": {
"line1": "3520 Millenio",
"line2": "Crowley Drive",
"city": "Vancouver",
"state": "BC",
"country": "CA",
"postal_code": "V5R 6G9"
},
"name": "John Smith",
"email": "john@fabric.inc",
"phone": "123-456-7890"
}
}
"0LybWR49k95cCwYh3cu0waCYoh4H2Eux2J52wn4k"
Created payment method
The response is of type object
.
Was this page helpful?