跳转到内容
Try Gitea Cloud ☁️ for 30 days → Accelerate your Development & Deploys!
Support
This is the documentation of 25.6.2, which is no longer the latest release. See the latest release.

Watch a repo

PUT
/repos/{owner}/{repo}/subscription
curl --request PUT \
--url https://gitea.example.com/api/v1/repos/example/example/subscription \
--header 'Authorization: Basic <credentials>'
owner
required
string

Owner of the repo

repo
required
string

Name of the repo

WatchInfo

WatchInfo represents an API watch status of one repository

object
created_at

The timestamp when the watch status was created

string format: date-time
ignored

Whether notifications for the repository are ignored

boolean
reason

The reason for the current watch status

repository_url

The URL of the repository being watched

string
subscribed

Whether the repository is being watched for notifications

boolean
url

The URL for managing the watch status

string
Examplegenerated
{
"created_at": "2026-04-15T12:00:00Z",
"ignored": true,
"reason": "example",
"repository_url": "example",
"subscribed": true,
"url": "example"
}

APIForbiddenError is a forbidden error response

message
string
url
string

APINotFound is a not found empty response