swagger: '2.0' info: description: This documentation describes the Gitea API. title: Gitea admin issue API license: name: MIT url: http://opensource.org/licenses/MIT version: 1.27.0+dev-89-gf52b6f3315 basePath: /api/v1 schemes: - https - http consumes: - application/json produces: - application/json security: - BasicAuth: [] - Token: [] - AccessToken: [] - AuthorizationHeaderToken: [] - SudoParam: [] - SudoHeader: [] - TOTPHeader: [] tags: - name: issue paths: /repos/issues/search: get: produces: - application/json tags: - issue summary: Search for issues across the repositories that the user has access to operationId: issueSearchIssues parameters: - enum: - open - closed - all type: string default: open description: State of the issue name: state in: query - type: string description: Comma-separated list of label names. Fetch only issues that have any of these labels. Non existent labels are discarded. name: labels in: query - type: string description: Comma-separated list of milestone names. Fetch only issues that have any of these milestones. Non existent milestones are discarded. name: milestones in: query - type: string description: Search string name: q in: query - enum: - issues - pulls type: string description: Filter by issue type name: type in: query - type: string format: date-time description: Only show issues updated after the given time (RFC 3339 format) name: since in: query - type: string format: date-time description: Only show issues updated before the given time (RFC 3339 format) name: before in: query - type: boolean default: false description: Filter issues or pulls assigned to the authenticated user name: assigned in: query - type: boolean default: false description: Filter issues or pulls created by the authenticated user name: created in: query - type: boolean default: false description: Filter issues or pulls mentioning the authenticated user name: mentioned in: query - type: boolean default: false description: Filter pull requests where the authenticated user's review was requested name: review_requested in: query - type: boolean default: false description: Filter pull requests reviewed by the authenticated user name: reviewed in: query - type: string description: Filter by repository owner name: owner in: query - type: string description: Only show items which were created by the given user name: created_by in: query - type: string description: Filter by team (requires organization owner parameter) name: team in: query - minimum: 1 type: integer default: 1 description: Page number of results to return (1-based) name: page in: query - minimum: 0 type: integer description: Number of items per page name: limit in: query responses: '200': $ref: '#/responses/IssueList' '400': $ref: '#/responses/error' '422': $ref: '#/responses/validationError' /repos/{owner}/{repo}/issues: get: produces: - application/json tags: - issue summary: List a repository's issues operationId: issueListIssues parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - enum: - closed - open - all type: string description: whether issue is open or closed name: state in: query - type: string description: comma separated list of label names. Fetch only issues that have any of this label names. Non existent labels are discarded. name: labels in: query - type: string description: search string name: q in: query - enum: - issues - pulls type: string description: filter by type (issues / pulls) if set name: type in: query - type: string description: comma separated list of milestone names or ids. It uses names and fall back to ids. Fetch only issues that have any of this milestones. Non existent milestones are discarded name: milestones in: query - type: string format: date-time description: Only show items updated after the given time. This is a timestamp in RFC 3339 format name: since in: query - type: string format: date-time description: Only show items updated before the given time. This is a timestamp in RFC 3339 format name: before in: query - type: string description: Only show items which were created by the given user name: created_by in: query - type: string description: Only show items for which the given user is assigned name: assigned_by in: query - type: string description: Only show items in which the given user was mentioned name: mentioned_by in: query - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/IssueList' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Create an issue. If using deadline only the date will be taken into account, and time of day ignored. operationId: issueCreateIssue parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - name: body in: body schema: $ref: '#/definitions/CreateIssueOption' responses: '201': $ref: '#/responses/Issue' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' '412': $ref: '#/responses/error' '422': $ref: '#/responses/validationError' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/comments: get: produces: - application/json tags: - issue summary: List all comments in a repository operationId: issueGetRepoComments parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string format: date-time description: if provided, only comments updated since the provided time are returned. name: since in: query - type: string format: date-time description: if provided, only comments updated before the provided time are returned. name: before in: query - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/CommentList' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/comments/{id}: get: consumes: - application/json produces: - application/json tags: - issue summary: Get a comment operationId: issueGetComment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment name: id in: path required: true responses: '200': $ref: '#/responses/Comment' '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' delete: tags: - issue summary: Delete a comment operationId: issueDeleteComment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of comment to delete name: id in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' patch: consumes: - application/json produces: - application/json tags: - issue summary: Edit a comment operationId: issueEditComment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment to edit name: id in: path required: true - name: body in: body schema: $ref: '#/definitions/EditIssueCommentOption' responses: '200': $ref: '#/responses/Comment' '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/comments/{id}/assets: get: produces: - application/json tags: - issue summary: List comment's attachments operationId: issueListIssueCommentAttachments parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment name: id in: path required: true responses: '200': $ref: '#/responses/AttachmentList' '404': $ref: '#/responses/error' post: consumes: - multipart/form-data produces: - application/json tags: - issue summary: Create a comment attachment operationId: issueCreateIssueCommentAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment name: id in: path required: true - type: string description: name of the attachment name: name in: query - type: file description: attachment to upload name: attachment in: formData required: true responses: '201': $ref: '#/responses/Attachment' '400': $ref: '#/responses/error' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/error' '413': $ref: '#/responses/error' '422': $ref: '#/responses/validationError' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/comments/{id}/assets/{attachment_id}: get: produces: - application/json tags: - issue summary: Get a comment attachment operationId: issueGetIssueCommentAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment name: id in: path required: true - type: integer format: int64 description: id of the attachment to get name: attachment_id in: path required: true responses: '200': $ref: '#/responses/Attachment' '404': $ref: '#/responses/error' delete: produces: - application/json tags: - issue summary: Delete a comment attachment operationId: issueDeleteIssueCommentAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment name: id in: path required: true - type: integer format: int64 description: id of the attachment to delete name: attachment_id in: path required: true responses: '204': $ref: '#/responses/empty' '404': $ref: '#/responses/error' '423': $ref: '#/responses/repoArchivedError' patch: consumes: - application/json produces: - application/json tags: - issue summary: Edit a comment attachment operationId: issueEditIssueCommentAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment name: id in: path required: true - type: integer format: int64 description: id of the attachment to edit name: attachment_id in: path required: true - name: body in: body schema: $ref: '#/definitions/EditAttachmentOptions' responses: '201': $ref: '#/responses/Attachment' '404': $ref: '#/responses/error' '422': $ref: '#/responses/validationError' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/comments/{id}/reactions: get: consumes: - application/json produces: - application/json tags: - issue summary: Get a list of reactions from a comment of an issue operationId: issueGetCommentReactions parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment to edit name: id in: path required: true responses: '200': $ref: '#/responses/ReactionList' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Add a reaction to a comment of an issue operationId: issuePostCommentReaction parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment to edit name: id in: path required: true - name: content in: body schema: $ref: '#/definitions/EditReactionOption' responses: '200': $ref: '#/responses/Reaction' '201': $ref: '#/responses/Reaction' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' delete: consumes: - application/json produces: - application/json tags: - issue summary: Remove a reaction from a comment of an issue operationId: issueDeleteCommentReaction parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the comment to edit name: id in: path required: true - name: content in: body schema: $ref: '#/definitions/EditReactionOption' responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}: get: produces: - application/json tags: - issue summary: Get an issue operationId: issueGetIssue parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue to get name: index in: path required: true responses: '200': $ref: '#/responses/Issue' '404': $ref: '#/responses/notFound' delete: tags: - issue summary: Delete an issue operationId: issueDelete parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of issue to delete name: index in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' patch: description: 'Pass `content_version` to enable optimistic locking on body edits. If the version doesn''t match the current value, the request fails with 409 Conflict. ' consumes: - application/json produces: - application/json tags: - issue summary: Edit an issue. If using deadline only the date will be taken into account, and time of day ignored. operationId: issueEditIssue parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue to edit name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/EditIssueOption' responses: '201': $ref: '#/responses/Issue' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' '412': $ref: '#/responses/error' /repos/{owner}/{repo}/issues/{index}/assets: get: produces: - application/json tags: - issue summary: List issue's attachments operationId: issueListIssueAttachments parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true responses: '200': $ref: '#/responses/AttachmentList' '404': $ref: '#/responses/error' post: consumes: - multipart/form-data produces: - application/json tags: - issue summary: Create an issue attachment operationId: issueCreateIssueAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: string description: name of the attachment name: name in: query - type: file description: attachment to upload name: attachment in: formData required: true responses: '201': $ref: '#/responses/Attachment' '400': $ref: '#/responses/error' '404': $ref: '#/responses/error' '413': $ref: '#/responses/error' '422': $ref: '#/responses/validationError' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/{index}/assets/{attachment_id}: get: produces: - application/json tags: - issue summary: Get an issue attachment operationId: issueGetIssueAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: integer format: int64 description: id of the attachment to get name: attachment_id in: path required: true responses: '200': $ref: '#/responses/Attachment' '404': $ref: '#/responses/error' delete: produces: - application/json tags: - issue summary: Delete an issue attachment operationId: issueDeleteIssueAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: integer format: int64 description: id of the attachment to delete name: attachment_id in: path required: true responses: '204': $ref: '#/responses/empty' '404': $ref: '#/responses/error' '423': $ref: '#/responses/repoArchivedError' patch: consumes: - application/json produces: - application/json tags: - issue summary: Edit an issue attachment operationId: issueEditIssueAttachment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: integer format: int64 description: id of the attachment to edit name: attachment_id in: path required: true - name: body in: body schema: $ref: '#/definitions/EditAttachmentOptions' responses: '201': $ref: '#/responses/Attachment' '404': $ref: '#/responses/error' '422': $ref: '#/responses/validationError' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/{index}/blocks: get: produces: - application/json tags: - issue summary: List issues that are blocked by this issue operationId: issueListBlocks parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: index of the issue name: index in: path required: true - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/IssueList' '404': $ref: '#/responses/notFound' post: produces: - application/json tags: - issue summary: Block the issue given in the body by the issue in path operationId: issueCreateIssueBlocking parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/IssueMeta' responses: '201': $ref: '#/responses/Issue' '404': description: the issue does not exist delete: produces: - application/json tags: - issue summary: Unblock the issue given in the body by the issue in path operationId: issueRemoveIssueBlocking parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/IssueMeta' responses: '200': $ref: '#/responses/Issue' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/comments: get: produces: - application/json tags: - issue summary: List all comments on an issue operationId: issueGetComments parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: string format: date-time description: if provided, only comments updated since the specified time are returned. name: since in: query - type: string format: date-time description: if provided, only comments updated before the provided time are returned. name: before in: query responses: '200': $ref: '#/responses/CommentList' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Add a comment to an issue operationId: issueCreateComment parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/CreateIssueCommentOption' responses: '201': $ref: '#/responses/Comment' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/{index}/comments/{id}: delete: tags: - issue summary: Delete a comment operationId: issueDeleteCommentDeprecated deprecated: true parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer description: this parameter is ignored name: index in: path required: true - type: integer format: int64 description: id of comment to delete name: id in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' patch: consumes: - application/json produces: - application/json tags: - issue summary: Edit a comment operationId: issueEditCommentDeprecated deprecated: true parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer description: this parameter is ignored name: index in: path required: true - type: integer format: int64 description: id of the comment to edit name: id in: path required: true - name: body in: body schema: $ref: '#/definitions/EditIssueCommentOption' responses: '200': $ref: '#/responses/Comment' '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/deadline: post: consumes: - application/json produces: - application/json tags: - issue summary: Set an issue deadline. If set to null, the deadline is deleted. If using deadline only the date will be taken into account, and time of day ignored. operationId: issueEditIssueDeadline parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue to create or update a deadline on name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/EditDeadlineOption' responses: '201': $ref: '#/responses/IssueDeadline' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/dependencies: get: produces: - application/json tags: - issue summary: List an issue's dependencies, i.e all issues that block this issue. operationId: issueListIssueDependencies parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: index of the issue name: index in: path required: true - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/IssueList' '404': $ref: '#/responses/notFound' post: produces: - application/json tags: - issue summary: Make the issue in the url depend on the issue in the form. operationId: issueCreateIssueDependencies parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/IssueMeta' responses: '201': $ref: '#/responses/Issue' '404': description: the issue does not exist '423': $ref: '#/responses/repoArchivedError' delete: produces: - application/json tags: - issue summary: Remove an issue dependency operationId: issueRemoveIssueDependencies parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/IssueMeta' responses: '200': $ref: '#/responses/Issue' '404': $ref: '#/responses/notFound' '423': $ref: '#/responses/repoArchivedError' /repos/{owner}/{repo}/issues/{index}/labels: get: produces: - application/json tags: - issue summary: Get an issue's labels operationId: issueGetLabels parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true responses: '200': $ref: '#/responses/LabelList' '404': $ref: '#/responses/notFound' put: consumes: - application/json produces: - application/json tags: - issue summary: Replace an issue's labels operationId: issueReplaceLabels parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/IssueLabelsOption' responses: '200': $ref: '#/responses/LabelList' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Add a label to an issue operationId: issueAddLabel parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/IssueLabelsOption' responses: '200': $ref: '#/responses/LabelList' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' delete: produces: - application/json tags: - issue summary: Remove all labels from an issue operationId: issueClearLabels parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/labels/{id}: delete: produces: - application/json tags: - issue summary: Remove a label from an issue operationId: issueRemoveLabel parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: integer format: int64 description: id of the label to remove name: id in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' '422': $ref: '#/responses/validationError' /repos/{owner}/{repo}/issues/{index}/lock: put: consumes: - application/json produces: - application/json tags: - issue summary: Lock an issue operationId: issueLockIssue parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/LockIssueOption' responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' delete: consumes: - application/json produces: - application/json tags: - issue summary: Unlock an issue operationId: issueUnlockIssue parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/pin: post: tags: - issue summary: Pin an Issue operationId: pinIssue parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of issue to pin name: index in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' delete: tags: - issue summary: Unpin an Issue operationId: unpinIssue parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of issue to unpin name: index in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/pin/{position}: patch: tags: - issue summary: Moves the Pin to the given Position operationId: moveIssuePin parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of issue name: index in: path required: true - type: integer format: int64 description: the new position name: position in: path required: true responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/reactions: get: consumes: - application/json produces: - application/json tags: - issue summary: Get a list reactions of an issue operationId: issueGetIssueReactions parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/ReactionList' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Add a reaction to an issue operationId: issuePostIssueReaction parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - name: content in: body schema: $ref: '#/definitions/EditReactionOption' responses: '200': $ref: '#/responses/Reaction' '201': $ref: '#/responses/Reaction' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' delete: consumes: - application/json produces: - application/json tags: - issue summary: Remove a reaction from an issue operationId: issueDeleteIssueReaction parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - name: content in: body schema: $ref: '#/definitions/EditReactionOption' responses: '204': $ref: '#/responses/empty' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/stopwatch/delete: delete: consumes: - application/json produces: - application/json tags: - issue summary: Delete an issue's existing stopwatch. operationId: issueDeleteStopWatch parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue to stop the stopwatch on name: index in: path required: true responses: '204': $ref: '#/responses/empty' '403': description: Not repo writer, user does not have rights to toggle stopwatch '404': $ref: '#/responses/notFound' '409': description: Cannot cancel a non-existent stopwatch /repos/{owner}/{repo}/issues/{index}/stopwatch/start: post: consumes: - application/json produces: - application/json tags: - issue summary: Start stopwatch on an issue. operationId: issueStartStopWatch parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue to create the stopwatch on name: index in: path required: true responses: '201': $ref: '#/responses/empty' '403': description: Not repo writer, user does not have rights to toggle stopwatch '404': $ref: '#/responses/notFound' '409': description: Cannot start a stopwatch again if it already exists /repos/{owner}/{repo}/issues/{index}/stopwatch/stop: post: consumes: - application/json produces: - application/json tags: - issue summary: Stop an issue's existing stopwatch. operationId: issueStopStopWatch parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue to stop the stopwatch on name: index in: path required: true responses: '201': $ref: '#/responses/empty' '403': description: Not repo writer, user does not have rights to toggle stopwatch '404': $ref: '#/responses/notFound' '409': description: Cannot stop a non-existent stopwatch /repos/{owner}/{repo}/issues/{index}/subscriptions: get: consumes: - application/json produces: - application/json tags: - issue summary: Get users who subscribed on an issue. operationId: issueSubscriptions parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/UserList' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/subscriptions/check: get: consumes: - application/json produces: - application/json tags: - issue summary: Check if user is subscribed to an issue operationId: issueCheckSubscription parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true responses: '200': $ref: '#/responses/WatchInfo' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/subscriptions/{user}: put: consumes: - application/json produces: - application/json tags: - issue summary: Subscribe user to issue operationId: issueAddSubscription parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: string description: username of the user to subscribe the issue to name: user in: path required: true responses: '200': description: Already subscribed '201': description: Successfully Subscribed '304': description: User can only subscribe itself if he is no admin '404': $ref: '#/responses/notFound' delete: consumes: - application/json produces: - application/json tags: - issue summary: Unsubscribe user from issue operationId: issueDeleteSubscription parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: string description: username of the user to unsubscribe from an issue name: user in: path required: true responses: '200': description: Already unsubscribed '201': description: Successfully Unsubscribed '304': description: User can only subscribe itself if he is no admin '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/timeline: get: produces: - application/json tags: - issue summary: List all comments and events on an issue operationId: issueGetCommentsAndTimeline parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: string format: date-time description: if provided, only comments updated since the specified time are returned. name: since in: query - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query - type: string format: date-time description: if provided, only comments updated before the provided time are returned. name: before in: query responses: '200': $ref: '#/responses/TimelineList' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/times: get: produces: - application/json tags: - issue summary: List an issue's tracked times operationId: issueTrackedTimes parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: string description: optional filter by user (available for issue managers) name: user in: query - type: string format: date-time description: Only show times updated after the given time. This is a timestamp in RFC 3339 format name: since in: query - type: string format: date-time description: Only show times updated before the given time. This is a timestamp in RFC 3339 format name: before in: query - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/TrackedTimeList' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Add tracked time to a issue operationId: issueAddTime parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - name: body in: body schema: $ref: '#/definitions/AddTimeOption' responses: '200': $ref: '#/responses/TrackedTime' '400': $ref: '#/responses/error' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' delete: consumes: - application/json produces: - application/json tags: - issue summary: Reset a tracked time of an issue operationId: issueResetTime parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue to add tracked time to name: index in: path required: true responses: '204': $ref: '#/responses/empty' '400': $ref: '#/responses/error' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/issues/{index}/times/{id}: delete: consumes: - application/json produces: - application/json tags: - issue summary: Delete specific tracked time operationId: issueDeleteTime parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: index of the issue name: index in: path required: true - type: integer format: int64 description: id of time to delete name: id in: path required: true responses: '204': $ref: '#/responses/empty' '400': $ref: '#/responses/error' '403': $ref: '#/responses/forbidden' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/labels: get: produces: - application/json tags: - issue summary: Get all of a repository's labels operationId: issueListLabels parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/LabelList' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Create a label operationId: issueCreateLabel parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - name: body in: body schema: $ref: '#/definitions/CreateLabelOption' responses: '201': $ref: '#/responses/Label' '404': $ref: '#/responses/notFound' '422': $ref: '#/responses/validationError' /repos/{owner}/{repo}/labels/{id}: get: produces: - application/json tags: - issue summary: Get a single label operationId: issueGetLabel parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the label to get name: id in: path required: true responses: '200': $ref: '#/responses/Label' '404': $ref: '#/responses/notFound' delete: tags: - issue summary: Delete a label operationId: issueDeleteLabel parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the label to delete name: id in: path required: true responses: '204': $ref: '#/responses/empty' '404': $ref: '#/responses/notFound' patch: consumes: - application/json produces: - application/json tags: - issue summary: Update a label operationId: issueEditLabel parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: integer format: int64 description: id of the label to edit name: id in: path required: true - name: body in: body schema: $ref: '#/definitions/EditLabelOption' responses: '200': $ref: '#/responses/Label' '404': $ref: '#/responses/notFound' '422': $ref: '#/responses/validationError' /repos/{owner}/{repo}/milestones: get: produces: - application/json tags: - issue summary: Get all of a repository's opened milestones operationId: issueGetMilestonesList parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: Milestone state, Recognized values are open, closed and all. Defaults to "open" name: state in: query - type: string description: filter by milestone name name: name in: query - type: integer description: page number of results to return (1-based) name: page in: query - type: integer description: page size of results name: limit in: query responses: '200': $ref: '#/responses/MilestoneList' '404': $ref: '#/responses/notFound' post: consumes: - application/json produces: - application/json tags: - issue summary: Create a milestone operationId: issueCreateMilestone parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - name: body in: body schema: $ref: '#/definitions/CreateMilestoneOption' responses: '201': $ref: '#/responses/Milestone' '404': $ref: '#/responses/notFound' /repos/{owner}/{repo}/milestones/{id}: get: produces: - application/json tags: - issue summary: Get a milestone operationId: issueGetMilestone parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: the milestone to get, identified by ID and if not available by name name: id in: path required: true responses: '200': $ref: '#/responses/Milestone' '404': $ref: '#/responses/notFound' delete: tags: - issue summary: Delete a milestone operationId: issueDeleteMilestone parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: the milestone to delete, identified by ID and if not available by name name: id in: path required: true responses: '204': $ref: '#/responses/empty' '404': $ref: '#/responses/notFound' patch: consumes: - application/json produces: - application/json tags: - issue summary: Update a milestone operationId: issueEditMilestone parameters: - type: string description: owner of the repo name: owner in: path required: true - type: string description: name of the repo name: repo in: path required: true - type: string description: the milestone to edit, identified by ID and if not available by name name: id in: path required: true - name: body in: body schema: $ref: '#/definitions/EditMilestoneOption' responses: '200': $ref: '#/responses/Milestone' '404': $ref: '#/responses/notFound' definitions: Comment: description: Comment represents a comment on a commit or issue type: object properties: assets: description: Attachments contains files attached to the comment type: array items: $ref: '#/definitions/Attachment' x-go-name: Attachments body: description: Body contains the comment text content type: string x-go-name: Body created_at: type: string format: date-time x-go-name: Created html_url: description: HTMLURL is the web URL for viewing the comment type: string x-go-name: HTMLURL id: description: ID is the unique identifier for the comment type: integer format: int64 x-go-name: ID issue_url: description: IssueURL is the API URL for the issue type: string x-go-name: IssueURL original_author: description: OriginalAuthor is the original author name (for imported comments) type: string x-go-name: OriginalAuthor original_author_id: description: OriginalAuthorID is the original author ID (for imported comments) type: integer format: int64 x-go-name: OriginalAuthorID pull_request_url: description: PRURL is the API URL for the pull request (if applicable) type: string x-go-name: PRURL updated_at: type: string format: date-time x-go-name: Updated user: $ref: '#/definitions/User' x-go-package: code.gitea.io/gitea/modules/structs CreateLabelOption: description: CreateLabelOption options for creating a label type: object required: - name - color properties: color: type: string x-go-name: Color example: '#00aabb' description: description: Description provides additional context about the label's purpose type: string x-go-name: Description exclusive: type: boolean x-go-name: Exclusive example: false is_archived: type: boolean x-go-name: IsArchived example: false name: type: string x-go-name: Name x-go-package: code.gitea.io/gitea/modules/structs RepositoryMeta: description: RepositoryMeta basic repository information type: object properties: full_name: type: string x-go-name: FullName id: type: integer format: int64 x-go-name: ID name: type: string x-go-name: Name owner: type: string x-go-name: Owner x-go-package: code.gitea.io/gitea/modules/structs CreateMilestoneOption: description: CreateMilestoneOption options for creating a milestone type: object properties: description: description: Description provides details about the milestone type: string x-go-name: Description due_on: type: string format: date-time x-go-name: Deadline state: type: string enum: - open - closed x-go-name: State title: description: Title is the title of the new milestone type: string x-go-name: Title x-go-package: code.gitea.io/gitea/modules/structs User: description: User represents a user type: object properties: active: description: Is user active type: boolean x-go-name: IsActive avatar_url: description: URL to the user's avatar type: string x-go-name: AvatarURL created: type: string format: date-time x-go-name: Created description: description: the user's description type: string x-go-name: Description email: type: string format: email x-go-name: Email followers_count: description: user counts type: integer format: int64 x-go-name: Followers following_count: type: integer format: int64 x-go-name: Following full_name: description: the user's full name type: string x-go-name: FullName html_url: description: URL to the user's gitea page type: string x-go-name: HTMLURL id: description: the user's id type: integer format: int64 x-go-name: ID is_admin: description: Is the user an administrator type: boolean x-go-name: IsAdmin language: description: User locale type: string x-go-name: Language last_login: type: string format: date-time x-go-name: LastLogin location: description: the user's location type: string x-go-name: Location login: description: login of the user, same as `username` type: string x-go-name: UserName login_name: description: identifier of the user, provided by the external authenticator (if configured) type: string default: empty x-go-name: LoginName prohibit_login: description: Is user login prohibited type: boolean x-go-name: ProhibitLogin restricted: description: Is user restricted type: boolean x-go-name: Restricted source_id: description: The ID of the user's Authentication Source type: integer format: int64 x-go-name: SourceID starred_repos_count: type: integer format: int64 x-go-name: StarredRepos visibility: description: 'User visibility level option: public, limited, private' type: string x-go-name: Visibility website: description: the user's website type: string x-go-name: Website x-go-package: code.gitea.io/gitea/modules/structs EditLabelOption: description: EditLabelOption options for editing a label type: object properties: color: type: string x-go-name: Color example: '#00aabb' description: description: Description provides additional context about the label's purpose type: string x-go-name: Description exclusive: type: boolean x-go-name: Exclusive example: false is_archived: type: boolean x-go-name: IsArchived example: false name: description: Name is the new display name for the label type: string x-go-name: Name x-go-package: code.gitea.io/gitea/modules/structs IssueMeta: description: IssueMeta basic issue information type: object properties: index: type: integer format: int64 x-go-name: Index owner: description: owner of the issue's repo type: string x-go-name: Owner repo: type: string x-go-name: Name x-go-package: code.gitea.io/gitea/modules/structs EditDeadlineOption: description: EditDeadlineOption options for creating a deadline type: object required: - due_date properties: due_date: type: string format: date-time x-go-name: Deadline x-go-package: code.gitea.io/gitea/modules/structs Issue: description: Issue represents an issue in a repository type: object properties: assets: type: array items: $ref: '#/definitions/Attachment' x-go-name: Attachments assignee: $ref: '#/definitions/User' assignees: type: array items: $ref: '#/definitions/User' x-go-name: Assignees body: type: string x-go-name: Body closed_at: type: string format: date-time x-go-name: Closed comments: type: integer format: int64 x-go-name: Comments content_version: description: The version of the issue content for optimistic locking type: integer format: int64 x-go-name: ContentVersion created_at: type: string format: date-time x-go-name: Created due_date: type: string format: date-time x-go-name: Deadline html_url: type: string x-go-name: HTMLURL id: type: integer format: int64 x-go-name: ID is_locked: type: boolean x-go-name: IsLocked labels: type: array items: $ref: '#/definitions/Label' x-go-name: Labels milestone: $ref: '#/definitions/Milestone' number: type: integer format: int64 x-go-name: Index original_author: type: string x-go-name: OriginalAuthor original_author_id: type: integer format: int64 x-go-name: OriginalAuthorID pin_order: type: integer format: int64 x-go-name: PinOrder pull_request: $ref: '#/definitions/PullRequestMeta' ref: type: string x-go-name: Ref repository: $ref: '#/definitions/RepositoryMeta' state: type: string enum: - open - closed x-go-enum-desc: 'open StateOpen StateOpen pr is opened closed StateClosed StateClosed pr is closed' x-go-name: State time_estimate: type: integer format: int64 x-go-name: TimeEstimate title: type: string x-go-name: Title updated_at: type: string format: date-time x-go-name: Updated url: type: string x-go-name: URL user: $ref: '#/definitions/User' x-go-package: code.gitea.io/gitea/modules/structs EditMilestoneOption: description: EditMilestoneOption options for editing a milestone type: object properties: description: description: Description provides updated details about the milestone type: string x-go-name: Description due_on: description: Deadline is the updated due date for the milestone type: string format: date-time x-go-name: Deadline state: description: State indicates the updated state of the milestone type: string enum: - open - closed x-go-name: State title: description: Title is the updated title of the milestone type: string x-go-name: Title x-go-package: code.gitea.io/gitea/modules/structs TrackedTime: description: TrackedTime worked time for an issue / pr type: object properties: created: type: string format: date-time x-go-name: Created id: description: ID is the unique identifier for the tracked time entry type: integer format: int64 x-go-name: ID issue: $ref: '#/definitions/Issue' issue_id: description: deprecated (only for backwards compatibility) type: integer format: int64 x-go-name: IssueID time: description: Time in seconds type: integer format: int64 x-go-name: Time user_id: description: deprecated (only for backwards compatibility) type: integer format: int64 x-go-name: UserID user_name: description: username of the user type: string x-go-name: UserName x-go-package: code.gitea.io/gitea/modules/structs EditReactionOption: description: EditReactionOption contain the reaction type type: object properties: content: description: The reaction content (e.g., emoji or reaction type) type: string x-go-name: Reaction x-go-package: code.gitea.io/gitea/modules/structs Milestone: description: Milestone milestone is a collection of issues on one repository type: object properties: closed_at: type: string format: date-time x-go-name: Closed closed_issues: description: ClosedIssues is the number of closed issues in this milestone type: integer format: int64 x-go-name: ClosedIssues created_at: type: string format: date-time x-go-name: Created description: description: Description provides details about the milestone type: string x-go-name: Description due_on: type: string format: date-time x-go-name: Deadline id: description: ID is the unique identifier for the milestone type: integer format: int64 x-go-name: ID open_issues: description: OpenIssues is the number of open issues in this milestone type: integer format: int64 x-go-name: OpenIssues state: description: 'State indicates if the milestone is open or closed open StateOpen StateOpen pr is opened closed StateClosed StateClosed pr is closed' type: string enum: - open - closed x-go-enum-desc: 'open StateOpen StateOpen pr is opened closed StateClosed StateClosed pr is closed' x-go-name: State title: description: Title is the title of the milestone type: string x-go-name: Title updated_at: type: string format: date-time x-go-name: Updated x-go-package: code.gitea.io/gitea/modules/structs WatchInfo: description: WatchInfo represents an API watch status of one repository type: object properties: created_at: description: The timestamp when the watch status was created type: string format: date-time x-go-name: CreatedAt ignored: description: Whether notifications for the repository are ignored type: boolean x-go-name: Ignored reason: description: The reason for the current watch status x-go-name: Reason repository_url: description: The URL of the repository being watched type: string x-go-name: RepositoryURL subscribed: description: Whether the repository is being watched for notifications type: boolean x-go-name: Subscribed url: description: The URL for managing the watch status type: string x-go-name: URL x-go-package: code.gitea.io/gitea/modules/structs IssueLabelsOption: description: IssueLabelsOption a collection of labels type: object properties: labels: description: 'Labels can be a list of integers representing label IDs or a list of strings representing label names' type: array items: {} x-go-name: Labels x-go-package: code.gitea.io/gitea/modules/structs CreateIssueOption: description: CreateIssueOption options to create one issue type: object required: - title properties: assignee: description: deprecated type: string x-go-name: Assignee assignees: type: array items: type: string x-go-name: Assignees body: type: string x-go-name: Body closed: type: boolean x-go-name: Closed due_date: type: string format: date-time x-go-name: Deadline labels: description: list of label ids type: array items: type: integer format: int64 x-go-name: Labels milestone: description: milestone id type: integer format: int64 x-go-name: Milestone ref: type: string x-go-name: Ref title: type: string x-go-name: Title x-go-package: code.gitea.io/gitea/modules/structs Team: description: Team represents a team in an organization type: object properties: can_create_org_repo: description: Whether the team can create repositories in the organization type: boolean x-go-name: CanCreateOrgRepo description: description: The description of the team type: string x-go-name: Description id: description: The unique identifier of the team type: integer format: int64 x-go-name: ID includes_all_repositories: description: Whether the team has access to all repositories in the organization type: boolean x-go-name: IncludesAllRepositories name: description: The name of the team type: string x-go-name: Name organization: $ref: '#/definitions/Organization' permission: type: string enum: - none - read - write - admin - owner x-go-name: Permission units: type: array items: type: string x-go-name: Units example: - repo.code - repo.issues - repo.ext_issues - repo.wiki - repo.pulls - repo.releases - repo.projects - repo.ext_wiki units_map: type: object additionalProperties: type: string x-go-name: UnitsMap example: 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 x-go-package: code.gitea.io/gitea/modules/structs Attachment: description: Attachment a generic attachment type: object properties: browser_download_url: description: DownloadURL is the URL to download the attachment type: string x-go-name: DownloadURL created_at: type: string format: date-time x-go-name: Created download_count: description: DownloadCount is the number of times the attachment has been downloaded type: integer format: int64 x-go-name: DownloadCount id: description: ID is the unique identifier for the attachment type: integer format: int64 x-go-name: ID name: description: Name is the filename of the attachment type: string x-go-name: Name size: description: Size is the file size in bytes type: integer format: int64 x-go-name: Size uuid: description: UUID is the unique identifier for the attachment file type: string x-go-name: UUID x-go-package: code.gitea.io/gitea/modules/structs PullRequestMeta: description: PullRequestMeta PR info if an issue is a PR type: object properties: draft: type: boolean x-go-name: IsWorkInProgress html_url: type: string x-go-name: HTMLURL merged: type: boolean x-go-name: HasMerged merged_at: type: string format: date-time x-go-name: Merged x-go-package: code.gitea.io/gitea/modules/structs IssueDeadline: description: IssueDeadline represents an issue deadline type: object properties: due_date: type: string format: date-time x-go-name: Deadline x-go-package: code.gitea.io/gitea/modules/structs EditIssueOption: description: EditIssueOption options for editing an issue type: object properties: assignee: description: deprecated type: string x-go-name: Assignee assignees: type: array items: type: string x-go-name: Assignees body: type: string x-go-name: Body content_version: description: The current version of the issue content to detect conflicts during editing type: integer format: int64 x-go-name: ContentVersion due_date: type: string format: date-time x-go-name: Deadline milestone: type: integer format: int64 x-go-name: Milestone ref: type: string x-go-name: Ref state: type: string x-go-name: State title: type: string x-go-name: Title unset_due_date: type: boolean x-go-name: RemoveDeadline x-go-package: code.gitea.io/gitea/modules/structs TimelineComment: description: TimelineComment represents a timeline comment (comment of any type) on a commit or issue type: object properties: assignee: $ref: '#/definitions/User' assignee_team: $ref: '#/definitions/Team' body: description: Body contains the timeline event content type: string x-go-name: Body created_at: type: string format: date-time x-go-name: Created dependent_issue: $ref: '#/definitions/Issue' html_url: description: HTMLURL is the web URL for viewing the comment type: string x-go-name: HTMLURL id: description: ID is the unique identifier for the timeline comment type: integer format: int64 x-go-name: ID issue_url: description: IssueURL is the API URL for the issue type: string x-go-name: IssueURL label: $ref: '#/definitions/Label' milestone: $ref: '#/definitions/Milestone' new_ref: type: string x-go-name: NewRef new_title: type: string x-go-name: NewTitle old_milestone: $ref: '#/definitions/Milestone' old_project_id: type: integer format: int64 x-go-name: OldProjectID old_ref: type: string x-go-name: OldRef old_title: type: string x-go-name: OldTitle project_id: type: integer format: int64 x-go-name: ProjectID pull_request_url: description: PRURL is the API URL for the pull request (if applicable) type: string x-go-name: PRURL ref_action: type: string x-go-name: RefAction ref_comment: $ref: '#/definitions/Comment' ref_commit_sha: description: commit SHA where issue/PR was referenced type: string x-go-name: RefCommitSHA ref_issue: $ref: '#/definitions/Issue' removed_assignee: description: whether the assignees were removed or added type: boolean x-go-name: RemovedAssignee resolve_doer: $ref: '#/definitions/User' review_id: type: integer format: int64 x-go-name: ReviewID tracked_time: $ref: '#/definitions/TrackedTime' type: description: Type indicates the type of timeline event type: string x-go-name: Type updated_at: type: string format: date-time x-go-name: Updated user: $ref: '#/definitions/User' x-go-package: code.gitea.io/gitea/modules/structs LockIssueOption: description: LockIssueOption options to lock an issue type: object properties: lock_reason: type: string x-go-name: Reason x-go-package: code.gitea.io/gitea/modules/structs AddTimeOption: description: AddTimeOption options for adding time to an issue type: object required: - time properties: created: type: string format: date-time x-go-name: Created time: description: time in seconds type: integer format: int64 x-go-name: Time user_name: description: username of the user who spent the time working on the issue (optional) type: string x-go-name: User x-go-package: code.gitea.io/gitea/modules/structs Reaction: description: Reaction contain one reaction type: object properties: content: description: The reaction content (e.g., emoji or reaction type) type: string x-go-name: Reaction created_at: type: string format: date-time x-go-name: Created user: $ref: '#/definitions/User' x-go-package: code.gitea.io/gitea/modules/structs Organization: description: Organization represents an organization type: object properties: avatar_url: description: The URL of the organization's avatar type: string x-go-name: AvatarURL description: description: The description of the organization type: string x-go-name: Description email: description: The email address of the organization type: string x-go-name: Email full_name: description: The full display name of the organization type: string x-go-name: FullName id: description: The unique identifier of the organization type: integer format: int64 x-go-name: ID location: description: The location of the organization type: string x-go-name: Location name: description: The name of the organization type: string x-go-name: Name repo_admin_change_team_access: description: Whether repository administrators can change team access type: boolean x-go-name: RepoAdminChangeTeamAccess username: description: 'username of the organization deprecated' type: string x-go-name: UserName visibility: description: The visibility level of the organization (public, limited, private) type: string x-go-name: Visibility website: description: The website URL of the organization type: string x-go-name: Website x-go-package: code.gitea.io/gitea/modules/structs CreateIssueCommentOption: description: CreateIssueCommentOption options for creating a comment on an issue type: object required: - body properties: body: type: string x-go-name: Body x-go-package: code.gitea.io/gitea/modules/structs Label: description: Label a label to an issue or a pr type: object properties: color: type: string x-go-name: Color example: 00aabb description: description: Description provides additional context about the label's purpose type: string x-go-name: Description exclusive: type: boolean x-go-name: Exclusive example: false id: description: ID is the unique identifier for the label type: integer format: int64 x-go-name: ID is_archived: type: boolean x-go-name: IsArchived example: false name: description: Name is the display name of the label type: string x-go-name: Name url: description: URL is the API endpoint for accessing this label type: string x-go-name: URL x-go-package: code.gitea.io/gitea/modules/structs EditIssueCommentOption: description: EditIssueCommentOption options for editing a comment type: object required: - body properties: body: type: string x-go-name: Body x-go-package: code.gitea.io/gitea/modules/structs EditAttachmentOptions: description: EditAttachmentOptions options for editing attachments type: object properties: name: description: Name is the new filename for the attachment type: string x-go-name: Name x-go-package: code.gitea.io/gitea/modules/structs responses: IssueList: description: IssueList schema: type: array items: $ref: '#/definitions/Issue' IssueDeadline: description: IssueDeadline schema: $ref: '#/definitions/IssueDeadline' Issue: description: Issue schema: $ref: '#/definitions/Issue' WatchInfo: description: WatchInfo schema: $ref: '#/definitions/WatchInfo' error: description: APIError is error format response headers: message: type: string url: type: string validationError: description: APIValidationError is error format response related to input validation headers: message: type: string url: type: string CommentList: description: CommentList schema: type: array items: $ref: '#/definitions/Comment' MilestoneList: description: MilestoneList schema: type: array items: $ref: '#/definitions/Milestone' Label: description: Label schema: $ref: '#/definitions/Label' Milestone: description: Milestone schema: $ref: '#/definitions/Milestone' Comment: description: Comment schema: $ref: '#/definitions/Comment' repoArchivedError: description: APIRepoArchivedError is an error that is raised when an archived repo should be modified headers: message: type: string url: type: string notFound: description: APINotFound is a not found empty response empty: description: APIEmpty is an empty response TrackedTimeList: description: TrackedTimeList schema: type: array items: $ref: '#/definitions/TrackedTime' ReactionList: description: ReactionList schema: type: array items: $ref: '#/definitions/Reaction' Reaction: description: Reaction schema: $ref: '#/definitions/Reaction' UserList: description: UserList schema: type: array items: $ref: '#/definitions/User' LabelList: description: LabelList schema: type: array items: $ref: '#/definitions/Label' TrackedTime: description: TrackedTime schema: $ref: '#/definitions/TrackedTime' AttachmentList: description: AttachmentList schema: type: array items: $ref: '#/definitions/Attachment' Attachment: description: Attachment schema: $ref: '#/definitions/Attachment' TimelineList: description: TimelineList schema: type: array items: $ref: '#/definitions/TimelineComment' forbidden: description: APIForbiddenError is a forbidden error response headers: message: type: string url: type: string securityDefinitions: AccessToken: description: This authentication option is deprecated for removal in Gitea 1.23. Please use AuthorizationHeaderToken instead. type: apiKey name: access_token in: query AuthorizationHeaderToken: description: API tokens must be prepended with "token" followed by a space. type: apiKey name: Authorization in: header BasicAuth: type: basic SudoHeader: description: Sudo API request as the user provided as the key. Admin privileges are required. type: apiKey name: Sudo in: header SudoParam: description: Sudo API request as the user provided as the key. Admin privileges are required. type: apiKey name: sudo in: query TOTPHeader: description: Must be used in combination with BasicAuth if two-factor authentication is enabled. type: apiKey name: X-GITEA-OTP in: header Token: description: This authentication option is deprecated for removal in Gitea 1.23. Please use AuthorizationHeaderToken instead. type: apiKey name: token in: query