---
title: "Setup Payment"
openapi: "openapi POST /v1/billing.setup_payment"
---
import { DynamicParamField } from "/components/dynamic-param-field.jsx";
import { DynamicResponseField } from "/components/dynamic-response-field.jsx";
import { DynamicResponseExample } from "/components/dynamic-response-example.jsx";
### Body Parameters
The ID of the customer
URL to redirect to after successful payment setup. Must start with either http:// or https://
Customer details to set when creating a customer
Customer's name
Customer's email address
Unique identifier (eg, serial number) to detect duplicate customers and prevent free trial abuse
Additional metadata for the customer
Stripe customer ID if you already have one
Whether to create the customer in Stripe
The ID of the free plan to auto-enable for the customer
Whether to send email receipts to this customer
Additional parameters for the checkout session
### Response
The ID of the customer
URL to the payment setup page
```json 200
{
"customer_id": "cus_123",
"payment_url": "https://checkout.stripe.com/..."
}
```