Create a Bookable Payments scheduling setup preset
curl --request POST \
--url https://api.simplepay.mx/v1/bookable-payments/setup \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"name": "<string>",
"price": {
"amount": 2,
"currency": "<string>"
}
}
'const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({name: '<string>', price: {amount: 2, currency: '<string>'}})
};
fetch('https://api.simplepay.mx/v1/bookable-payments/setup', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.simplepay.mx/v1/bookable-payments/setup"
payload = {
"name": "<string>",
"price": {
"amount": 2,
"currency": "<string>"
}
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"blueprint": {
"default_capacity": 2,
"default_duration_minutes": 2,
"default_resource_kind": "<string>",
"default_schedule": {
"end_time": "<string>",
"start_time": "<string>",
"time_zone": "<string>",
"weekdays": [
3
]
},
"default_slot_interval_minutes": 2,
"event_kind": "<string>",
"id": "<string>",
"inventory_mode": "<string>",
"label": "<string>",
"primitives": [
"<string>"
],
"resource_assignment_mode": "<string>",
"spanish_label": "<string>",
"steps": [
{
"estimated_minutes": 1,
"id": "<string>",
"label": "<string>",
"phase": "<string>",
"readiness_keys": [
"<string>"
],
"required_for_go_live": true,
"required_routes": [
"<string>"
],
"required_scopes": [
"<string>"
],
"tenant_tables": [
"<string>"
]
}
],
"webhook_events": [
"<string>"
]
},
"event_type": {
"active": true,
"bookingFormFields": [
{}
],
"bookingWindowDays": 2,
"bufferAfterMinutes": 1,
"bufferBeforeMinutes": 1,
"cancellationPolicy": {},
"capacity": 2,
"defaultPrice": {
"amount": 1,
"currency": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"defaultPriceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"description": "<string>",
"durationChoicesMinutes": [
2
],
"durationMinutes": 2,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"maximumQuantity": 2,
"metadata": {},
"minimumNoticeMinutes": 1,
"minimumQuantity": 2,
"object": "<unknown>",
"paymentConfig": {},
"product": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
},
"productId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reschedulePolicy": {},
"slug": "<string>",
"slotIntervalMinutes": 2,
"timeZone": "<string>",
"title": "<string>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"next": {
"checkout_route": "<string>",
"config_route": "<string>",
"preflight_route": "<string>",
"slots_route": "<string>"
},
"object": "<unknown>",
"product": {
"active": true,
"booking": {
"bufferAfterMinutes": 1,
"bufferBeforeMinutes": 1,
"capacity": 2,
"config": {},
"durationMinutes": 2,
"enabled": true,
"paymentRequired": true,
"slotIntervalMinutes": 2,
"timeZone": "<string>"
},
"defaultPrice": {
"amount": 1,
"currency": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"description": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"name": "<string>",
"object": "<unknown>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"resource": {
"active": true,
"capacity": 2,
"externalRef": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"location": {},
"metadata": {},
"name": "<string>",
"object": "<unknown>",
"parentResourceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timeZone": "<string>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"schedule": {
"active": true,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"name": "<string>",
"object": "<unknown>",
"overrides": [
{
"active": true,
"capacity": 1,
"endsAt": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"object": "<unknown>",
"reason": "<string>",
"scheduleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"startsAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"rules": [
{
"active": true,
"capacity": 2,
"endTime": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"object": "<unknown>",
"scheduleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"startTime": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"weekday": 3
}
],
"timeZone": "<string>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"tenant_env": "<string>"
}Create a Bookable Payments scheduling setup preset
Referencia detallada para POST /v1/bookable-payments/setup.
POST
https://api.simplepay.mx
/
v1
/
bookable-payments
/
setup
Create a Bookable Payments scheduling setup preset
curl --request POST \
--url https://api.simplepay.mx/v1/bookable-payments/setup \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: <idempotency-key>' \
--data '
{
"name": "<string>",
"price": {
"amount": 2,
"currency": "<string>"
}
}
'const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({name: '<string>', price: {amount: 2, currency: '<string>'}})
};
fetch('https://api.simplepay.mx/v1/bookable-payments/setup', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.simplepay.mx/v1/bookable-payments/setup"
payload = {
"name": "<string>",
"price": {
"amount": 2,
"currency": "<string>"
}
}
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"blueprint": {
"default_capacity": 2,
"default_duration_minutes": 2,
"default_resource_kind": "<string>",
"default_schedule": {
"end_time": "<string>",
"start_time": "<string>",
"time_zone": "<string>",
"weekdays": [
3
]
},
"default_slot_interval_minutes": 2,
"event_kind": "<string>",
"id": "<string>",
"inventory_mode": "<string>",
"label": "<string>",
"primitives": [
"<string>"
],
"resource_assignment_mode": "<string>",
"spanish_label": "<string>",
"steps": [
{
"estimated_minutes": 1,
"id": "<string>",
"label": "<string>",
"phase": "<string>",
"readiness_keys": [
"<string>"
],
"required_for_go_live": true,
"required_routes": [
"<string>"
],
"required_scopes": [
"<string>"
],
"tenant_tables": [
"<string>"
]
}
],
"webhook_events": [
"<string>"
]
},
"event_type": {
"active": true,
"bookingFormFields": [
{}
],
"bookingWindowDays": 2,
"bufferAfterMinutes": 1,
"bufferBeforeMinutes": 1,
"cancellationPolicy": {},
"capacity": 2,
"defaultPrice": {
"amount": 1,
"currency": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"defaultPriceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"description": "<string>",
"durationChoicesMinutes": [
2
],
"durationMinutes": 2,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"maximumQuantity": 2,
"metadata": {},
"minimumNoticeMinutes": 1,
"minimumQuantity": 2,
"object": "<unknown>",
"paymentConfig": {},
"product": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
},
"productId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reschedulePolicy": {},
"slug": "<string>",
"slotIntervalMinutes": 2,
"timeZone": "<string>",
"title": "<string>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"next": {
"checkout_route": "<string>",
"config_route": "<string>",
"preflight_route": "<string>",
"slots_route": "<string>"
},
"object": "<unknown>",
"product": {
"active": true,
"booking": {
"bufferAfterMinutes": 1,
"bufferBeforeMinutes": 1,
"capacity": 2,
"config": {},
"durationMinutes": 2,
"enabled": true,
"paymentRequired": true,
"slotIntervalMinutes": 2,
"timeZone": "<string>"
},
"defaultPrice": {
"amount": 1,
"currency": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"description": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"name": "<string>",
"object": "<unknown>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"resource": {
"active": true,
"capacity": 2,
"externalRef": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"location": {},
"metadata": {},
"name": "<string>",
"object": "<unknown>",
"parentResourceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timeZone": "<string>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"schedule": {
"active": true,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"name": "<string>",
"object": "<unknown>",
"overrides": [
{
"active": true,
"capacity": 1,
"endsAt": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"object": "<unknown>",
"reason": "<string>",
"scheduleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"startsAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"rules": [
{
"active": true,
"capacity": 2,
"endTime": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metadata": {},
"object": "<unknown>",
"scheduleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"startTime": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"weekday": 3
}
],
"timeZone": "<string>",
"updatedAt": "2023-11-07T05:31:56Z"
},
"tenant_env": "<string>"
}Uso
Usalo dentro de Bookable Payments para modelar inventario reservado, calcular disponibilidad, crear holds, convertirlos en checkout y confirmar bookings.Antes de llamar
| Tema | Detalle |
|---|---|
| Metodo | POST |
| Ruta | /v1/bookable-payments/setup |
| Auth | Bearer API key del ambiente correcto. |
| Scope | products:write, availability:write |
| Idempotencia | Recomendada para cualquier retry. Usa una key deterministica por operacion de negocio. |
| Guia relacionada | Bookable Payments |
Patron recomendado
- Ejecuta este endpoint desde backend o job seguro, nunca desde frontend con API keys.
- Manda
Idempotency-Keycuando el endpoint cree, convierta, reprograme, cancele, capture o reembolse estado. - Confirma inventario final con
booking.confirmedo una lectura de booking, no solo con una URL de retorno. - Consulta el bloque OpenAPI de esta pagina para el shape exacto de parametros, body y respuestas.
Ejemplo minimo
terminal
curl -sS -X POST "https://api.simplepay.mx/v1/bookable-payments/setup" \
-H "Authorization: Bearer $SIMPLEPAY_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: create-bookable-payments-setup_v1" \
-d '{ ... }'
Errores a manejar
400indica payload, parametros o estado invalido.401o403indican API key, ambiente o scopes incorrectos.409suele indicar conflicto de estado, duplicado o idempotencia incompatible.429y5xxse pueden reintentar con backoff; en writes conserva la misma idempotency key.
Contrato OpenAPI
El playground, parametros, body y respuestas de abajo salen de/openapi.json. Si el contrato cambia, actualiza la spec y regenera esta pagina.Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Required string length:
8 - 255Body
application/json
Minimum string length:
1Required range:
x >= 1Hide child attributes
Hide child attributes
Required range:
x >= 1Required range:
x >= 0Required range:
x >= 0Required range:
x >= 1Available options:
automatic, manual, payment_required Required range:
x >= 1Required range:
x >= 1Available options:
capacity_pool, date_range, instant, seated, unit_assignment Available options:
appointment, class, scheduled_offer, experience, rental, service, date_range Required range:
x >= 1Required range:
x >= 0Required range:
x >= 1Available options:
deposit, none, optional, required Pattern:
^[a-z0-9][a-z0-9-]{1,120}$Required range:
x >= 1Minimum string length:
1Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Required range:
x >= 0Required range:
x >= 0Required range:
x >= 1Required range:
x >= 1Required range:
x >= 1Minimum string length:
1Available options:
appointment, class, scheduled_offer, experience, rental, service, standard, date_range Hide child attributes
Hide child attributes
Minimum string length:
1Required range:
x >= 1Available options:
amenity, equipment, inventory_pool, space, staff, unit, vehicle Available options:
appointment, class, scheduled_offer, experience, rental, service, date_range, tour Response
201 - application/json
Bookable Payments setup created
Hide child attributes
Hide child attributes
Required range:
x >= 1Required range:
x >= 1Required range:
x >= 1Hide child attributes
Hide child attributes
Required range:
x >= 0Hide child attributes
Hide child attributes
Required range:
x >= 1Required range:
x >= 0Required range:
x >= 0Required range:
x >= 1Available options:
automatic, manual, payment_required Required range:
x >= 1Required range:
x >= 1Available options:
capacity_pool, date_range, instant, seated, unit_assignment Available options:
appointment, class, scheduled_offer, experience, rental, service, date_range Required range:
x >= 1Required range:
x >= 0Required range:
x >= 1Available options:
deposit, none, optional, required Required range:
x >= 1Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Required range:
x >= 0Required range:
x >= 0Required range:
x >= 1Required range:
x >= 1Required range:
x >= 1Available options:
appointment, bundle, class, scheduled_offer, experience, package, rental, service, standard, date_range Hide child attributes
Hide child attributes
Required range:
x >= 1Available options:
amenity, equipment, inventory_pool, space, staff, unit, vehicle Hide child attributes
Hide child attributes
Hide child attributes
Hide child attributes
Required range:
x >= 0Hide child attributes
Hide child attributes
Required range:
x >= 1Required range:
0 <= x <= 6Last modified on June 21, 2026
⌘I