Clientes

Crear cliente

Obtiene o crea un cliente (usuario) en el sistema de Tonder. Devuelve el `id` y el `auth_token` del cliente. Si ya existe un cliente con ese correo, regresa el existente en vez de duplicarlo.

POST
/customer/

Autorización

Authorization
Authorization<token>

Your public API key, with the word Token and a space in front of it. Example: Token 6534bc0a7e1f4d2b9c8e3a5f7b1d2c4e6f8a9b0c — that whole value is the header. Sending the key alone returns 401 'Authentication credentials were not provided'. In this playground you may paste just the key; the prefix is added for you.

In: header

Cuerpo de la petición

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Cuerpo de la respuesta

application/json

application/json

application/json

curl -X POST "https://example.com/customer/" \  -H "Content-Type: application/json" \  -d '{    "email": "user@example.com"  }'
{
  "id": 766,
  "email": "jsmith@example.com",
  "auth_token": "86706c507e9ca032c91771a26819d69e91402fc9"
}
{
  "email": [
    "Enter a valid email address."
  ]
}
{
  "detail": "Invalid token."
}
¿Te resultó útil esta página?