# Manage Scenarios via API

Scenarios can be managed programmatically through the Verkada API, including listing available scenarios, activating one, or releasing an active one. [Emergency scenarios](/access-control/integrations-and-alerts/configure-access-control-event-alerts/emergency-lockdown.md) are pre-configured emergency responses that admins can activate to lock and unlock doors and notify the right people when something happens, organized into five types: Lockdown, Hold, Secure, Evacuate, and Shelter.

***

## Command configuration

#### Organization level

{% stepper %}
{% step %}
**In Verkada Command, go to All Products > Access.**
{% endstep %}

{% step %}
**On the left navigation, click Access Settings.**
{% endstep %}

{% step %}
**Toggle on Enable Lockdown and Scenario Control via API.**
{% endstep %}
{% endstepper %}

#### Generate API key

{% stepper %}
{% step %}
**In Verkada Command, go to All Products > Admin.**
{% endstep %}

{% step %}
**Under Org Settings, click API & Integrations.**
{% endstep %}

{% step %}
**From the API & Integration settings, select API Keys > Add.**

a. Select **New Key** and click **Next.**\
b. Enter a unique name.\
c. Under **Endpoints**, select **Access Control.**\
d. Set the permissions to **Read/Write**.\
e. Set the expiration date.\
f. Click **Generate API.**
{% endstep %}
{% endstepper %}

***

## Available API actions

Once you configure Command to allow API control of scenarios, you can perform the following actions:

* [List Scenarios](https://apidocs.verkada.com/reference/getaccessscenariolistviewv1): Retrieve all configured scenarios across your organization.
* [Activate a Scenario](https://apidocs.verkada.com/reference/postaccessscenarioactivateviewv1): Trigger a scenario programmatically in response to an event or condition.
* [Release a Scenario](https://apidocs.verkada.com/reference/postaccessscenarioreleaseviewv1): End or deactivate an active scenario.

{% hint style="warning" %}
See [Verkada API Docs](https://apidocs.verkada.com/reference/access-scenarios) for more details on specific Access Control API endpoints.
{% endhint %}

***

## Activate and release a scenario via API

When a scenario, such as a lockdown, is activated or released through the API, it behaves the same as if it were activated manually in Command.

Using the API to activate or release a scenario will:

* Execute all configured scenario actions, such as locking doors, unlocking doors, triggering alerts, or activating AUX outputs.
* Update the scenario’s status in both the Command interface and the Verkada Pass app.
* Generate event logs for each action, visible in the Events report and the Command audit log.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.verkada.com/access-control/integrations-and-alerts/manage-doors-via-api/manage-lockdowns-and-scenarios-via-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
