---
title: "Create trigger"
method: POST
path: "/api/v1/triggers"
tags: ["Trigger"]
---

# Create trigger

`POST /api/v1/triggers`

Create new trigger object.

## Request body

- TriggerBase
  - `id` integer — ID of the trigger
  - `url` string, url — URL of the trigger
  - `queue` string, uri — Queue URL.
  - `event` string — Event that will trigger the trigger (see [trigger event types](/guides/using-triggers#trigger-event-types))
  - `condition` object — A subset of MongoDB Query Language (see [trigger condition](/guides/using-triggers#trigger-condition))
  - `email_templates` string[] — URLs of the linked email templates
  - `delete_recommendations` string[] — URLs of the linked delete recommendations
  - `modified_by` string, uri, nullable — User that last modified the object.
  - `modified_at` string, date-time, nullable — Timestamp of last modification.

## Response `201`

Created

- Trigger
  - `id` integer, required — ID of the trigger
  - `url` string, url, required — URL of the trigger
  - `queue` string, uri, required — Queue URL.
  - `event` string, required — Event that will trigger the trigger (see [trigger event types](/guides/using-triggers#trigger-event-types))
  - `condition` object, required — A subset of MongoDB Query Language (see [trigger condition](/guides/using-triggers#trigger-condition))
  - `email_templates` string[], required — URLs of the linked email templates
  - `delete_recommendations` string[], required — URLs of the linked delete recommendations
  - `modified_by` string, uri, nullable, required — User that last modified the object.
  - `modified_at` string, date-time, nullable, required — Timestamp of last modification.

## Other responses

- `400` — Invalid input data.
- `401` — The username/password is invalid or token is invalid (e.g. expired).
- `403` — Insufficient permission, missing authentication, invalid CSRF token and similar issue.
- `404` — The specified resource was not found.
- `409` — Conflict
- `413` — Payload too large (especially for files uploaded).
- `429` — Request rate is too high, wait before sending more requests. See [Rate Limiting](/guides/overview#rate-limiting) for more details.
- `500` — Server failure while processing the request.
- `502` — Invalid response from the upstream server.
- `503` — We're temporarily offline for maintenance. Please try again later.
- `504` — Upstream server could not complete the request in time.

---

[API](https://skmtc.dev/rossum/apis/rossum-api.md) · [All operations](https://skmtc.dev/rossum/apis/rossum-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/rossum/rossum-api/revisions/f1b5a910991d/schema)
