10 KiB
\NotificationApi
All URIs are relative to http://localhost/api/v1
Method | HTTP request | Description |
---|---|---|
NotifyGetList | Get /notifications | List users's notification threads |
NotifyGetRepoList | Get /repos/{owner}/{repo}/notifications | List users's notification threads on a specific repo |
NotifyGetThread | Get /notifications/threads/{id} | Get notification thread by ID |
NotifyNewAvailable | Get /notifications/new | Check if unread notifications exist |
NotifyReadList | Put /notifications | Mark notification threads as read |
NotifyReadRepoList | Put /repos/{owner}/{repo}/notifications | Mark notification threads as read on a specific repo |
NotifyReadThread | Patch /notifications/threads/{id} | Mark notification thread as read by ID |
NotifyGetList
[]NotificationThread NotifyGetList(ctx, optional) List users's notification threads
Required Parameters
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
optional | *NotifyGetListOpts | optional parameters | nil if no parameters |
Optional Parameters
Optional parameters are passed through a pointer to a NotifyGetListOpts struct
Name | Type | Description | Notes |
---|---|---|---|
all | optional.String | If true, show notifications marked as read. Default value is false | |
since | optional.Time | Only show notifications updated after the given time. This is a timestamp in RFC 3339 format | |
before | optional.Time | Only show notifications updated before the given time. This is a timestamp in RFC 3339 format | |
page | optional.Int32 | page number of results to return (1-based) | |
limit | optional.Int32 | page size of results, maximum page size is 50 |
Return type
Authorization
AccessToken, AuthorizationHeaderToken, BasicAuth, SudoHeader, SudoParam, Token
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
NotifyGetRepoList
[]NotificationThread NotifyGetRepoList(ctx, owner, repo, optional) List users's notification threads on a specific repo
Required Parameters
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
owner | string | owner of the repo | |
repo | string | name of the repo | |
optional | *NotifyGetRepoListOpts | optional parameters | nil if no parameters |
Optional Parameters
Optional parameters are passed through a pointer to a NotifyGetRepoListOpts struct
Name | Type | Description | Notes |
---|
all | optional.String| If true, show notifications marked as read. Default value is false | since | optional.Time| Only show notifications updated after the given time. This is a timestamp in RFC 3339 format | before | optional.Time| Only show notifications updated before the given time. This is a timestamp in RFC 3339 format | page | optional.Int32| page number of results to return (1-based) | limit | optional.Int32| page size of results, maximum page size is 50 |
Return type
Authorization
AccessToken, AuthorizationHeaderToken, BasicAuth, SudoHeader, SudoParam, Token
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
NotifyGetThread
NotificationThread NotifyGetThread(ctx, id) Get notification thread by ID
Required Parameters
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
id | string | id of notification thread |
Return type
Authorization
AccessToken, AuthorizationHeaderToken, BasicAuth, SudoHeader, SudoParam, Token
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
NotifyNewAvailable
NotificationCount NotifyNewAvailable(ctx, ) Check if unread notifications exist
Required Parameters
This endpoint does not need any parameter.
Return type
Authorization
AccessToken, AuthorizationHeaderToken, BasicAuth, SudoHeader, SudoParam, Token
HTTP request headers
- Content-Type: application/json, text/plain
- Accept: application/json, text/html
[Back to top] [Back to API list] [Back to Model list] [Back to README]
NotifyReadList
NotifyReadList(ctx, optional) Mark notification threads as read
Required Parameters
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
optional | *NotifyReadListOpts | optional parameters | nil if no parameters |
Optional Parameters
Optional parameters are passed through a pointer to a NotifyReadListOpts struct
Name | Type | Description | Notes |
---|---|---|---|
lastReadAt | optional.Time | Describes the last point that notifications were checked. Anything updated since this time will not be updated. |
Return type
(empty response body)
Authorization
AccessToken, AuthorizationHeaderToken, BasicAuth, SudoHeader, SudoParam, Token
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
NotifyReadRepoList
NotifyReadRepoList(ctx, owner, repo, optional) Mark notification threads as read on a specific repo
Required Parameters
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
owner | string | owner of the repo | |
repo | string | name of the repo | |
optional | *NotifyReadRepoListOpts | optional parameters | nil if no parameters |
Optional Parameters
Optional parameters are passed through a pointer to a NotifyReadRepoListOpts struct
Name | Type | Description | Notes |
---|
lastReadAt | optional.Time| Describes the last point that notifications were checked. Anything updated since this time will not be updated. |
Return type
(empty response body)
Authorization
AccessToken, AuthorizationHeaderToken, BasicAuth, SudoHeader, SudoParam, Token
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
NotifyReadThread
NotifyReadThread(ctx, id) Mark notification thread as read by ID
Required Parameters
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
id | string | id of notification thread |
Return type
(empty response body)
Authorization
AccessToken, AuthorizationHeaderToken, BasicAuth, SudoHeader, SudoParam, Token
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]