Rezepte
ReferenceTokens

/api/v1/tokens

The raw token is returned once and cannot be retrieved afterwards.

POST/api/v1/tokens
rezepte_session<token>

Session cookie set by POST /api/v1/auth/login.

In: cookie

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/problem+json

application/problem+json

application/problem+json

application/problem+json

curl -X POST "https://example.com/api/v1/tokens" \  -H "Content-Type: application/json" \  -d '{    "name": "string",    "scopes": [      "recipes:read"    ]  }'
{  "$schema": "https://example.com/api/v1/schemas/CreatedAPIToken.json",  "createdAt": "2019-08-24T14:15:22Z",  "expiresAt": "2019-08-24T14:15:22Z",  "id": "string",  "lastUsedAt": "2019-08-24T14:15:22Z",  "name": "string",  "ownerColor": "string",  "ownerDisplayName": "string",  "ownerId": "string",  "ownerUsername": "string",  "prefix": "string",  "scopes": [    "string"  ],  "token": "string"}