> Tychron Atlas API & Provisioning Reference — chapter 17 of 35 as Markdown. Web version: https://docs.tychron.com/api-reference/secret-keys/
> Source: https://docs.tychron.com/api-reference/ · Updated 2026-08-12 · Generated from the Atlas OpenAPI spec (https://api.atlas.tychron.online/api/v1/openapi is the live contract; this file is a dated snapshot of it).
> Source revision: atlas_api_reference_2026-08-12.md · sha256 482ebd3b014af053 · sanitize gate v1 clean · reconciled with OpenAPI 2026.8.25-p01 (spec sha256 cc049ef38c71cd6e) on 2026-09-05 · content last modified 2026-09-09 · newer definition under review since 2026-09-09 (not yet reconciled)
> Scope: the Atlas platform API only. The SMS, MMS, CNAM, LRN and MCL services are separate APIs with their own specifications: https://docs.tychron.com/openapi/
> Machine index: https://docs.tychron.com/llms.txt

# Secret Keys

## Schema

An set of authorization details for various APIs

__Type__ Object

| Name          | Type                                         | Description                    |
| ------------- | -------------------------------------------- | ------------------------------ |
| `id`          | String(format:uuid)                          | [Desc. `id`](https://docs.tychron.com/api-reference/secret-keys/#desc-250)        |
| `inserted_at` | String(format:date-time)                     | An ISO8601 formatted timestamp |
| `name`        | String(3..255)                               | [Desc. `name`](https://docs.tychron.com/api-reference/secret-keys/#desc-251)      |
| `notes`       | String(0..65535)                             | [Desc. `notes`](https://docs.tychron.com/api-reference/secret-keys/#desc-252)     |
| `size`        | Enum(`16`, `24`, `32`, `48`, `64`):Number    | [Desc. `size`](https://docs.tychron.com/api-reference/secret-keys/#desc-253)      |
| `updated_at`  | String(format:date-time)                     | An ISO8601 formatted timestamp |
| `usage`       | Enum(`NONE`, `SIGNING`, `ENCRYPTION`):String | [Desc. `usage`](https://docs.tychron.com/api-reference/secret-keys/#desc-254)     |

#### Desc. `id` {#desc-250}

A Universally unique identifier, which identifies the resource

#### Desc. `name` {#desc-251}

A friendly name to identify the Secret Key

#### Desc. `notes` {#desc-252}

Any notes about the Secret Key, like, what it is used for, or other sharable details.

#### Desc. `size` {#desc-253}

The size of the key that should be created in bytes, or the size of the key in the system.

Different use cases or methods will require different length keys.

#### Desc. `usage` {#desc-254}

What is the intended usage of the Secret Key, this will bar it from being used for other cases.

NONE is placeholder or temporary disablement state reserved for internal usage.

Only SIGNING and ENCRYPTION can be used otherwise.



__Example__

```json
{
  "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
  "inserted_at": "2021-08-13T04:08:44.762841Z",
  "name": "My Secret Key",
  "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
  "size": 32,
  "updated_at": "2021-08-13T04:08:44.762841Z",
  "usage": "SIGNING"
}
```


## Summary

## Where are my secrets?

Similar to API Keys, once a SecretKey is created, its `data` is returned once, all subsequent requests afterwards do not return the `data`.

## API

### Create Secret Key

__Data__

| Name    | Type                                         | Description                |
| ------- | -------------------------------------------- | -------------------------- |
| `name`  | String(3..255)                               | [Desc. `name`](https://docs.tychron.com/api-reference/secret-keys/#desc-255)  |
| `notes` | String(0..65535)                             | [Desc. `notes`](https://docs.tychron.com/api-reference/secret-keys/#desc-256) |
| `size`  | Enum(`16`, `24`, `32`, `48`, `64`):Number    | [Desc. `size`](https://docs.tychron.com/api-reference/secret-keys/#desc-257)  |
| `usage` | Enum(`NONE`, `SIGNING`, `ENCRYPTION`):String | [Desc. `usage`](https://docs.tychron.com/api-reference/secret-keys/#desc-258) |

#### Desc. `name` {#desc-255}

A friendly name to identify the Secret Key

#### Desc. `notes` {#desc-256}

Any notes about the Secret Key, like, what it is used for, or other sharable details.

#### Desc. `size` {#desc-257}

The size of the key that should be created in bytes, or the size of the key in the system.

Different use cases or methods will require different length keys.

#### Desc. `usage` {#desc-258}

What is the intended usage of the Secret Key, this will bar it from being used for other cases.

NONE is placeholder or temporary disablement state reserved for internal usage.

Only SIGNING and ENCRYPTION can be used otherwise.



```http
POST /api/v1/secret_keys HTTP/1.1
```

Create a new Secret Key.

Note that newly created Secret Keys will return their secrets, however all subsequent GET requests
will not contain the secrets.


#### Request application/json

```http
POST /api/v1/secret_keys HTTP/1.1
Accept: application/json
Content-Type: application/json
Content-Length: 196
```

```json
{
  "data": {
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```

#### Response 201

##### application/json

```http
HTTP/1.1 201
Content-Type: application/json
Content-Length: 367
```

```json
{
  "data": {
    "data": "string",
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Update Secret Key

__Data__

| Name     | Type    | Description                              |
| -------- | ------- | ---------------------------------------- |
| `active` | Boolean | Whether the Secret Key is active for use |
| `name`   | String  | A display name for the Secret Key        |
| `notes`  | String  | Any notes on the Secret Key              |



```http
PATCH /api/v1/secret_keys/{id} HTTP/1.1
```

Update an existing Secret Key


__Path Parameters__

| Name | Type                 | Description   |
| ---- | -------------------- | ------------- |
| id   | String(format:uuid)! | Secret Key ID |

#### Request application/json

```http
PATCH /api/v1/secret_keys/{id} HTTP/1.1
Accept: application/json
Content-Type: application/json
Content-Length: 108
```

```json
{
  "data": {
    "active": false,
    "name": "string",
    "notes": "string"
  },
  "type": "secret_key"
}
```

#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Delete Secret Key

```http
DELETE /api/v1/secret_keys/{id} HTTP/1.1
```

Delete an Secret Key.

Note that an Secret Key cannot be deleted if it is still associated with any Switches.


__Path Parameters__

| Name | Type                 | Description   |
| ---- | -------------------- | ------------- |
| id   | String(format:uuid)! | Secret Key ID |

#### Request

```http
DELETE /api/v1/secret_keys/{id} HTTP/1.1
Accept: application/json
```
#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### List Secret Keys

```http
GET /api/v1/secret_keys HTTP/1.1
```

Retrieve Secret Keys allocated for this account.


__Query Parameters__

| Name   | Type    | Description                     |
| ------ | ------- | ------------------------------- |
| first  | Integer | [Query Desc. first](https://docs.tychron.com/api-reference/secret-keys/#desc-259)  |
| last   | Integer | [Query Desc. last](https://docs.tychron.com/api-reference/secret-keys/#desc-260)   |
| after  | String  | [Query Desc. after](https://docs.tychron.com/api-reference/secret-keys/#desc-261)  |
| before | String  | [Query Desc. before](https://docs.tychron.com/api-reference/secret-keys/#desc-262) |

#### Query Desc. first {#desc-259}

The number of items to return starting from the 'after' cursor

#### Query Desc. last {#desc-260}

The number of items to return behind the 'before' cursor

#### Query Desc. after {#desc-261}

The cursor representing the starting point of a 'first' based paging

#### Query Desc. before {#desc-262}

The cursor representing the starting point of a 'last' based paging

#### Request

```http
GET /api/v1/secret_keys HTTP/1.1
Accept: application/json
```
#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 554
```

```json
{
  "count": 1,
  "page_info": {
    "first": "string",
    "has_next_page": true,
    "has_previous_page": true,
    "last": "string"
  },
  "results": [
    {
      "data": {
        "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
        "inserted_at": "2021-08-13T04:08:44.762841Z",
        "name": "My Secret Key",
        "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
        "size": 32,
        "updated_at": "2021-08-13T04:08:44.762841Z",
        "usage": "SIGNING"
      },
      "type": "secret_key"
    }
  ]
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```


### Get Secret Key

```http
GET /api/v1/secret_keys/{id} HTTP/1.1
```

Lookup an Secret Key by its ID


__Path Parameters__

| Name | Type                 | Description   |
| ---- | -------------------- | ------------- |
| id   | String(format:uuid)! | Secret Key ID |

#### Request

```http
GET /api/v1/secret_keys/{id} HTTP/1.1
Accept: application/json
```
#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Attach Secret Key to Switch as MMS Encryption Key

```http
PUT /api/v1/switches/{switch_id}/mms_encryption_key/{id} HTTP/1.1
```

Attach a Secret Key to a Switch for MMS Encryption.


__Path Parameters__

| Name      | Type                 | Description   |
| --------- | -------------------- | ------------- |
| switch_id | String(format:uuid)! | Switch ID     |
| id        | String(format:uuid)! | Secret Key ID |

#### Request application/json

```http
PUT /api/v1/switches/{switch_id}/mms_encryption_key/{id} HTTP/1.1
Accept: application/json
Content-Type: application/json
Content-Length: 75
```

```json
{
  "data": {
    "mms_encryption_method": "NONE"
  },
  "type": "switch"
}
```

#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Detach MMS Encryption Key from Switch

```http
DELETE /api/v1/switches/{switch_id}/mms_encryption_key HTTP/1.1
```

Detach Secret Key from Switch used for MMS Encryption.


__Path Parameters__

| Name      | Type                 | Description |
| --------- | -------------------- | ----------- |
| switch_id | String(format:uuid)! | Switch ID   |

#### Request

```http
DELETE /api/v1/switches/{switch_id}/mms_encryption_key HTTP/1.1
Accept: application/json
```
#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Attach Secret Key to Switch as MMS Signing Key

```http
PUT /api/v1/switches/{switch_id}/mms_signing_key/{id} HTTP/1.1
```

Attach a Secret Key to a Switch for MMS Signing.


__Path Parameters__

| Name      | Type                 | Description   |
| --------- | -------------------- | ------------- |
| switch_id | String(format:uuid)! | Switch ID     |
| id        | String(format:uuid)! | Secret Key ID |

#### Request application/json

```http
PUT /api/v1/switches/{switch_id}/mms_signing_key/{id} HTTP/1.1
Accept: application/json
Content-Type: application/json
Content-Length: 104
```

```json
{
  "data": {
    "mms_signing_hash": "NONE",
    "mms_signing_scheme": "NONE"
  },
  "type": "switch"
}
```

#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Detach MMS Signing Key from Switch

```http
DELETE /api/v1/switches/{switch_id}/mms_signing_key HTTP/1.1
```

Detach Secret Key from Switch used for MMS Signing.


__Path Parameters__

| Name      | Type                 | Description |
| --------- | -------------------- | ----------- |
| switch_id | String(format:uuid)! | Switch ID   |

#### Request

```http
DELETE /api/v1/switches/{switch_id}/mms_signing_key HTTP/1.1
Accept: application/json
```
#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Attach Secret Key to Switch as SMS Encryption Key

```http
PUT /api/v1/switches/{switch_id}/sms_encryption_key/{id} HTTP/1.1
```

Attach a Secret Key to a Switch for SMS Encryption.


__Path Parameters__

| Name      | Type                 | Description   |
| --------- | -------------------- | ------------- |
| switch_id | String(format:uuid)! | Switch ID     |
| id        | String(format:uuid)! | Secret Key ID |

#### Request application/json

```http
PUT /api/v1/switches/{switch_id}/sms_encryption_key/{id} HTTP/1.1
Accept: application/json
Content-Type: application/json
Content-Length: 75
```

```json
{
  "data": {
    "sms_encryption_method": "NONE"
  },
  "type": "switch"
}
```

#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Detach SMS Encryption Key from Switch

```http
DELETE /api/v1/switches/{switch_id}/sms_encryption_key HTTP/1.1
```

Detach Secret Key from Switch used for SMS Encryption.


__Path Parameters__

| Name      | Type                 | Description |
| --------- | -------------------- | ----------- |
| switch_id | String(format:uuid)! | Switch ID   |

#### Request

```http
DELETE /api/v1/switches/{switch_id}/sms_encryption_key HTTP/1.1
Accept: application/json
```
#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Attach Secret Key to Switch as SMS Signing Key

```http
PUT /api/v1/switches/{switch_id}/sms_signing_key/{id} HTTP/1.1
```

Attach a Secret Key to a Switch for SMS Signing.


__Path Parameters__

| Name      | Type                 | Description   |
| --------- | -------------------- | ------------- |
| switch_id | String(format:uuid)! | Switch ID     |
| id        | String(format:uuid)! | Secret Key ID |

#### Request application/json

```http
PUT /api/v1/switches/{switch_id}/sms_signing_key/{id} HTTP/1.1
Accept: application/json
Content-Type: application/json
Content-Length: 104
```

```json
{
  "data": {
    "sms_signing_hash": "NONE",
    "sms_signing_scheme": "NONE"
  },
  "type": "switch"
}
```

#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```


### Detach SMS Signing Key from Switch

```http
DELETE /api/v1/switches/{switch_id}/sms_signing_key HTTP/1.1
```

Detach Secret Key from Switch used for SMS Signing.


__Path Parameters__

| Name      | Type                 | Description |
| --------- | -------------------- | ----------- |
| switch_id | String(format:uuid)! | Switch ID   |

#### Request

```http
DELETE /api/v1/switches/{switch_id}/sms_signing_key HTTP/1.1
Accept: application/json
```
#### Response 200

##### application/json

```http
HTTP/1.1 200
Content-Type: application/json
Content-Length: 345
```

```json
{
  "data": {
    "id": "c6be45e4-b7dd-412c-96c4-777e83fb9c48",
    "inserted_at": "2021-08-13T04:08:44.762841Z",
    "name": "My Secret Key",
    "notes": "This Secret Key is used for the west datacenter's SMS notifications.",
    "size": 32,
    "updated_at": "2021-08-13T04:08:44.762841Z",
    "usage": "SIGNING"
  },
  "type": "secret_key"
}
```
#### Response 403

##### application/json

```http
HTTP/1.1 403
Content-Type: application/json
Content-Length: 312
```

```json
{
  "errors": [
    {
      "code": "access_denied.no_scope",
      "detail": "No scope available to user role",
      "params": {
        "action": "index",
        "level": "guest",
        "resource": "resource"
      },
      "sub_code": "none",
      "title": "Access Denied, no scope available"
    }
  ]
}
```
#### Response 404

##### application/json

```http
HTTP/1.1 404
Content-Type: application/json
Content-Length: 314
```

```json
{
  "errors": [
    {
      "code": "not_found",
      "detail": "The specified resource could not be found",
      "params": {
        "resource": {
          "id": "3fbb573a-6049-44a0-a12c-d3a1ffae0b69",
          "type": "user"
        }
      },
      "sub_code": "none",
      "title": "Not Found"
    }
  ]
}
```

---

Previous chapter: https://docs.tychron.com/api-reference/call-data-webhooks.md  
Next chapter: https://docs.tychron.com/api-reference/switches.md  
Complete reference in one file: https://docs.tychron.com/llms-full.txt
