---
title: "Set a thread subscription"
method: PUT
path: "/notifications/threads/{thread_id}/subscription"
tags: ["activity"]
---

# Set a thread subscription

`PUT /notifications/threads/{thread_id}/subscription`

If you are watching a repository, you receive notifications for all threads by default. Use this endpoint to ignore future notifications for threads until you comment on the thread or get an **@mention**.

You can also use this endpoint to subscribe to threads that you are currently not receiving notifications for or to subscribed to threads that you have previously ignored.

Unsubscribing from a conversation in a repository that you are not watching is functionally equivalent to the [Delete a thread subscription](https://docs.github.com/enterprise-cloud@latest/rest/activity/notifications#delete-a-thread-subscription) endpoint.

## Path parameters

- `thread_id` integer, required

## Request body

- object
  - `ignored` boolean — Whether to block all notifications from a thread.

## Response `200`

Response

- ThreadSubscription — Thread Subscription
  - `subscribed` boolean, required
  - `ignored` boolean, required
  - `reason` string, nullable, required
  - `created_at` string, date-time, nullable, required
  - `url` string, uri, required
  - `thread_url` string, uri
  - `repository_url` string, uri

## Other responses

- `304` — Not modified
- `401` — Requires authentication
- `403` — Forbidden

---

[API](https://skmtc.net/github/apis/github-v3-rest-api-2.md) · [All operations](https://skmtc.net/github/apis/github-v3-rest-api-2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/github-v3-rest-api-2/versions/8ae6d0c8716e/schema)
