# Change or archive an extra or fee

`PATCH /lodging/extras/{id}` · Rivier · bookings

Change or archive an extra or fee.

- Scope: bookings:admin
- Mcp: rivier_lodging_extra_update
- Sdk: bookings.extra.update
- Cli: bookings extra update

## Parameters

- `id` (path, required), string

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "code": {
      "type": "string",
      "pattern": "^[A-Za-z0-9_-]{1,24}$"
    },
    "name": {
      "type": "string",
      "minLength": 1,
      "maxLength": 120
    },
    "kind": {
      "type": "string",
      "enum": [
        "extra",
        "fee"
      ],
      "default": "extra"
    },
    "priceMinor": {
      "type": "integer",
      "minimum": 0,
      "maximum": 9007199254740991
    },
    "per": {
      "type": "string",
      "enum": [
        "stay",
        "night",
        "person",
        "person_night"
      ],
      "default": "stay"
    },
    "tax": {
      "type": "string",
      "enum": [
        "accommodation",
        "ancillary",
        "none"
      ],
      "default": "ancillary"
    },
    "mandatory": {
      "type": "boolean",
      "default": false
    },
    "maxQuantity": {
      "type": "integer",
      "minimum": 1,
      "maximum": 50,
      "default": 1
    },
    "roomTypeIds": {
      "type": "array",
      "items": {
        "type": "string",
        "format": "uuid"
      },
      "maxItems": 100,
      "default": []
    },
    "content": {
      "type": "object",
      "additionalProperties": {
        "type": "object",
        "additionalProperties": {
          "type": "string",
          "maxLength": 8000
        },
        "propertyNames": {
          "pattern": "^[A-Za-z]{1,32}$"
        }
      },
      "propertyNames": {
        "pattern": "^[a-z]{2,3}(-[A-Za-z0-9]{2,8})?$"
      },
      "default": {}
    },
    "position": {
      "type": "integer",
      "minimum": 0,
      "maximum": 10000,
      "default": 0
    },
    "published": {
      "type": "boolean",
      "default": true
    },
    "status": {
      "type": "string",
      "enum": [
        "active",
        "archived"
      ]
    }
  },
  "additionalProperties": false
}
```

## Responses

- `200`: 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 PATCH 'https://api.rivier.ai/lodging/extras/{id}' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "code": "string",
  "name": "string",
  "kind": "extra",
  "priceMinor": 0,
  "per": "stay",
  "tax": "ancillary",
  "mandatory": false,
  "maxQuantity": 1
}'
```
