---
title: "Update deployment defender"
url: https://hexelstudio.com/docs/api/titan/management/update-deployment-defender
---

# Update deployment defender

**PUT** `/titan/management/deployments/{id}/defender`

## Path parameters

- `id: string`

## Headers

- `Authorization: string`

  `Bearer <token>`. A Hexel Studio access token for a member or a service user of your organization (or send a service user's API key as X-API-Key).

## Body parameters

- `defaults: optional boolean`

- `rules: optional array of object`

  - `action: string`

  - `id: string`

  - `kind: string`

  - `threshold: integer`

  - `window_seconds: integer`

## Returns

`200` Organization-scoped result. (`DefenderView`)

- `defaults: boolean`

- `deployment_id: string`

- `enforcement_deployment_id: string`

- `floor: optional array of object`

  - `action: string`

  - `id: string`

  - `kind: string`

  - `threshold: integer`

  - `window_seconds: integer`

- `kinds: array of string`

- `organization_id: string`

- `rules: array of object`

  - `action: string`

  - `id: string`

  - `kind: string`

  - `threshold: integer`

  - `window_seconds: integer`

## Errors

- `400` Invalid request, path, query, or idempotency key; on create, PROFILE_NOT_AVAILABLE when the region, hosting mode and exposure match no approved profile.
- `401` Missing or invalid authenticated context.
- `403` Organization mismatch or denied IAM action.
- `404` Unknown or foreign organization resource, or plan not yet prepared.
- `405` HTTP method is not supported on this route.
- `503` Local storage or preparation service unavailable.

## Example

```bash
curl --request PUT \
  --url 'https://api.hexelstudio.com/v1/titan/management/deployments/{id}/defender' \
  --header "Authorization: Bearer $ACCESS_TOKEN" \
  --header 'Content-Type: application/json' \
  --data '{
  "defaults": true,
  "rules": [
    {
      "action": "string",
      "id": "string",
      "kind": "string",
      "threshold": 0,
      "window_seconds": 0
    }
  ]
}'
```

### Response (200)

```json
{
  "defaults": true,
  "deployment_id": "string",
  "enforcement_deployment_id": "string",
  "floor": [
    {
      "action": "string",
      "id": "string",
      "kind": "string",
      "threshold": 0,
      "window_seconds": 0
    }
  ],
  "kinds": [
    "string"
  ],
  "organization_id": "string",
  "rules": [
    {
      "action": "string",
      "id": "string",
      "kind": "string",
      "threshold": 0,
      "window_seconds": 0
    }
  ]
}
```

### Response (400)

```json
{
  "error": {
    "billing_url": "string",
    "code": "string",
    "message": "string"
  }
}
```

### Response (401)

```json
{
  "error": {
    "billing_url": "string",
    "code": "string",
    "message": "string"
  }
}
```

### Response (403)

```json
{
  "error": {
    "billing_url": "string",
    "code": "string",
    "message": "string"
  }
}
```

### Response (404)

```json
{
  "error": {
    "billing_url": "string",
    "code": "string",
    "message": "string"
  }
}
```

### Response (405)

```json
{
  "error": {
    "billing_url": "string",
    "code": "string",
    "message": "string"
  }
}
```

### Response (503)

```json
{
  "error": {
    "billing_url": "string",
    "code": "string",
    "message": "string"
  }
}
```
