---
title: "Create a subscription"
method: POST
path: "/v1/projects/{projectID}/subscriptions"
tags: ["Subscriptions"]
---

# Create a subscription

`POST /v1/projects/{projectID}/subscriptions`

This endpoint creates a subscriptions

## Path parameters

- `projectID` string, required

## Request body

- ModelsCreateSubscription
  - `alert_config` ModelsAlertConfiguration
    - `count` integer
    - `threshold` string
  - `app_id` string — Deprecated but necessary for backward compatibility
  - `endpoint_id` string
  - `filter_config` ModelsFilterConfiguration
    - `event_types` string[]
    - `filter` ModelsFS
      - `body` DatastoreM
      - `headers` DatastoreM
  - `function` string
  - `name` string
  - `rate_limit_config` ModelsRateLimitConfiguration
    - `count` integer
    - `duration` integer
  - `retry_config` ModelsRetryConfiguration
    - `duration` string
    - `interval_seconds` integer
    - `retry_count` integer
    - `type` 'linear' | 'linear' | 'exponential'
  - `source_id` string

## Changes

- **2024-01-30** `5a219dba9f40` — 1 breaking, 2 info
  - removed the success response with the status `201`
  - api operation id `CreateSubscription` removed and replaced with ``
  - added the success response with the status `200`

[Change history](https://skmtc.dev/frain-dev/apis/convoy-api-reference/changes/v1/projects/:projectID/subscriptions/post.md)

---

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