Skip to main content

Setup

POST/api/v1/payments/setup

Creates a Stripe setup intent for saving a payment method for future use. Returns a setup intent secret for use with client-side Stripe Elements.

cv-api-key
Productionhttps://api.care360-next.carevalidate.com/api/v1/payments/setup
Staginghttps://api-staging.care360-next.carevalidate.com/api/v1/payments/setup

Request Body

Body Parameters
metadataobjectoptional

Optional metadata to be stored with the setup intent

Show 2 child properties
emailstringoptional

Email address associated with the setup intent

Example: testemail@example.com
phonestringoptional

Phone number associated with the setup intent

Example: +1404567890

Response Fields

FieldTypeDescription
successbooleanIndicates if the setup intent was created successfully
paymentSecretstringSecret key for client-side payment processing

Changelog

VersionDateChanges
1.02026-02-03Initial Payment Setup API documentation

Request Examples

curl -X POST "https://api.care360-next.carevalidate.com/api/v1/payments/setup" \
-H "cv-api-key: YOUR_SECRET_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"metadata": {
"email": "testemail@example.com",
"phone": "+1404567890"
}
}'

Responses

200SuccessSetup intent created successfully
{
"success": true,
"paymentSecret": "pi_3SG0o8GkkQS2eXzh0BKpSaq0_secret_CBrwqmT726jzfcnvCt0qBcS9e"
}
401UnauthorizedInvalid or missing API key
{
"status": 401,
"error": "Invalid API key"
}
500Internal Server ErrorAn unexpected error occurred
{
"success": false,
"message": "Internal server error"
}

Try It Out