# Reserve for a guest

`POST /payments/reservations` · Rivier · shop

Reserve for a guest. Paid online, the reservation is held for 35 minutes and the answer carries the address where the guest pays (a checkout on the business's own Stripe account, with the platform fee); it is booked when Stripe says it is paid. Paid on arrival, it is booked at once. An agent inside the owner's limits reserves; outside them, or with no limits set, it waits for the owner's approval.

- Scope: shop:write
- Mcp: rivier_payments_reserve
- Graphql: Mutation.shopReservationCreate
- Sdk: shop.reservation.create
- Cli: shop reservation create

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "offeringId": {
      "type": "string",
      "format": "uuid"
    },
    "quantity": {
      "type": "integer",
      "minimum": 1,
      "maximum": 500,
      "default": 1
    },
    "slotId": {
      "type": "string",
      "format": "uuid"
    },
    "checkin": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
    },
    "checkout": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
    },
    "guest": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "maxLength": 120
        },
        "email": {
          "type": "string",
          "format": "email",
          "maxLength": 200
        }
      },
      "required": [
        "name",
        "email"
      ],
      "additionalProperties": false
    },
    "returnTo": {
      "type": "string",
      "format": "uri",
      "maxLength": 400
    },
    "idempotencyKey": {
      "type": "string",
      "minLength": 8,
      "maxLength": 100
    }
  },
  "required": [
    "offeringId",
    "guest"
  ],
  "additionalProperties": false
}
```

## Responses

- `201`: Success
- `400`: The request was malformed
- `401`: No valid credential
- `403`: The credential lacks the scope, origin or address
- `429`: Over the key's rate limit; see Retry-After

## Example

```sh
curl -X POST 'https://api.rivier.ai/payments/reservations' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "offeringId": "string",
  "guest": {
    "name": "string",
    "email": "name@example.com"
  }
}'
```
