# Get an Access Code

* [Request Parameters](https://docs.seam.co/latest/~/revisions/DFdrUdS2jQOnbJTNDT5a/api/access_codes/..#request-parameters)
* [Response](https://docs.seam.co/latest/~/revisions/DFdrUdS2jQOnbJTNDT5a/api/access_codes/..#response)
* [Examples](https://docs.seam.co/latest/~/revisions/DFdrUdS2jQOnbJTNDT5a/api/access_codes/..#examples)

Returns a specified [access code](https://docs.seam.co/latest/capability-guides/smart-locks/access-codes).

You must specify either `access_code_id` or both `device_id` and `code`.

{% tabs %}
{% tab title="Signature" %}

```
POST /access_codes/get ⇒ { access_code }
```

{% endtab %}
{% endtabs %}

<details>

<summary>Authentication Methods</summary>

* API key
* Client session token

To learn more, see [Authentication](https://docs.seam.co/latest/api/authentication).

</details>

## Request Parameters

**`access_code_id`** *String*

ID of the access code that you want to get. You must specify either `access_code_id` or both `device_id` and `code`.

***

**`code`** *String*

Code of the access code that you want to get. You must specify either `access_code_id` or both `device_id` and `code`.

***

**`device_id`** *String*

ID of the device containing the access code that you want to get. You must specify either `access_code_id` or both `device_id` and `code`.

***

## Response

[access\_code](https://docs.seam.co/latest/~/revisions/DFdrUdS2jQOnbJTNDT5a/api/access_codes)

{% tabs %}
{% tab title="JSON" %}

```json
{
  JSON representation of access_code
}
```

{% endtab %}
{% endtabs %}
