List users's notification threads on a specific repo
const url = 'https://gitea.com/api/v1/repos/example/example/notifications';const options = {method: 'GET', headers: {Authorization: 'Basic <credentials>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://gitea.com/api/v1/repos/example/example/notifications \ --header 'Authorization: Basic <credentials>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Owner of the repo
Name of the repo
Query Parameters
Section titled “Query Parameters”If true, show notifications marked as read. Default value is false
Show notifications with the provided status types. Options are: unread, read and/or pinned. Defaults to unread & pinned
Filter notifications by subject type
Only show notifications updated after the given time. This is a timestamp in RFC 3339 format
Only show notifications updated before the given time. This is a timestamp in RFC 3339 format
Page number of results to return (1-based)
Page size of results
Responses
Section titled “Responses”NotificationThreadList
NotificationThread expose Notification on API
object
ID is the unique identifier for the notification thread
Pinned indicates if the notification is pinned
Repository represents a repository
object
ExternalTracker represents settings for external tracker
object
External Issue Tracker URL Format. Use the placeholders {user}, {repo} and {index} for the username, repository name and issue index.
External Issue Tracker issue regular expression
External Issue Tracker Number Format, either numeric, alphanumeric, or regexp
URL of external issue tracker.
ExternalWiki represents setting for external wiki
object
URL of external wiki.
InternalTracker represents settings for internal tracker
object
Let only contributors track time (Built-in issue tracker)
Enable dependencies for issues and pull requests (Built-in issue tracker)
Enable time tracking (Built-in issue tracker)
ObjectFormatName of the underlying git repository
User represents a user
object
Is user active
URL to the user’s avatar
The user’s description
User counts
The user’s full name
URL to the user’s gitea page
The user’s id
Is the user an administrator
User locale
The user’s location
Login of the user, same as username
Identifier of the user, provided by the external authenticator (if configured)
Is user login prohibited
Is user restricted
The ID of the user’s Authentication Source
User visibility level option: public, limited, private
The user’s website
Permission represents a set of permissions
object
RepoTransfer represents a pending repo transfer
object
User represents a user
object
Is user active
URL to the user’s avatar
The user’s description
User counts
The user’s full name
URL to the user’s gitea page
The user’s id
Is the user an administrator
User locale
The user’s location
Login of the user, same as username
Identifier of the user, provided by the external authenticator (if configured)
Is user login prohibited
Is user restricted
The ID of the user’s Authentication Source
User visibility level option: public, limited, private
The user’s website
User represents a user
object
Is user active
URL to the user’s avatar
The user’s description
User counts
The user’s full name
URL to the user’s gitea page
The user’s id
Is the user an administrator
User locale
The user’s location
Login of the user, same as username
Identifier of the user, provided by the external authenticator (if configured)
Is user login prohibited
Is user restricted
The ID of the user’s Authentication Source
User visibility level option: public, limited, private
The user’s website
Team represents a team in an organization
object
Whether the team can create repositories in the organization
The description of the team
The unique identifier of the team
Whether the team has access to all repositories in the organization
The name of the team
Organization represents an organization
object
The URL of the organization’s avatar
The description of the organization
The email address of the organization
The full display name of the organization
The unique identifier of the organization
The location of the organization
The name of the organization
Whether repository administrators can change team access
Username of the organization deprecated
The visibility level of the organization (public, limited, private)
The website URL of the organization
Deprecated: This variable should be replaced by UnitsMap and will be dropped in later versions.
object
Team visibility within the organization. “private” teams are only listable by members and org owners; “limited” teams are listable by any organization member; “public” teams are listable by any signed-in user.
NotificationSubject contains the notification subject (Issue/Pull/Commit)
object
HTMLURL is the web URL for the notification subject
LatestCommentHTMLURL is the web URL for the latest comment
LatestCommentURL is the API URL for the latest comment
State indicates the current state of the notification subject
Title is the title of the notification subject
Type indicates the type of the notification subject
URL is the API URL for the notification subject
Unread indicates if the notification has been read
UpdatedAt is the time when the notification was last updated
URL is the API URL for this notification thread
Example
[ { "repository": { "object_format_name": "sha1", "owner": { "visibility": "public" }, "repo_transfer": { "doer": { "visibility": "public" }, "recipient": { "visibility": "public" }, "teams": [ { "organization": { "visibility": "public" }, "permission": "none", "units": [ "repo.code", "repo.issues", "repo.ext_issues", "repo.wiki", "repo.pulls", "repo.releases", "repo.projects", "repo.ext_wiki" ], "units_map": { "repo.code": "read", "repo.ext_issues": "none", "repo.ext_wiki": "none", "repo.issues": "write", "repo.projects": "none", "repo.pulls": "owner", "repo.releases": "none", "repo.wiki": "admin" }, "visibility": "public" } ] } }, "subject": { "state": "open", "type": "Issue" } }]