Gitea API.
  1. issue
Gitea API.
  • admin
    • List cron tasks
    • Run cron task
    • List all organizations
    • List unadopted repositories
    • Delete unadopted files
    • Adopt unadopted files as a repository
    • List all users
    • Create a user
    • Delete a user
    • Edit an existing user
    • Add a public key on behalf of a user
    • Delete a user's public key
    • Create an organization
    • Create a repository on behalf of a user
  • miscellaneous
    • Render a markdown document as HTML
    • Render raw markdown as HTML
    • Get default signing-key.gpg
    • Returns the version of the Gitea application
  • notification
    • List users's notification threads
    • Mark notification threads as read, pinned or unread
    • Check if unread notifications exist
    • Get notification thread by ID
    • Mark notification thread as read by ID
    • List users's notification threads on a specific repo
    • Mark notification threads as read, pinned or unread on a specific repo
  • organization
    • Create a repository in an organization
    • Get list of organizations
    • Create an organization
    • Delete an organization
    • Get an organization
    • Edit an organization
    • List an organization's webhooks
    • Create a hook
    • Delete a hook
    • Get a hook
    • Update a hook
    • List an organization's labels
    • Create a label for an organization
    • Delete a label
    • Get a single label
    • Update a label
    • List an organization's members
    • Remove a member from an organization
    • Check if a user is a member of an organization
    • List an organization's public members
    • Conceal a user's membership
    • Check if a user is a public member of an organization
    • Publicize a user's membership
    • List an organization's repos
    • Create a repository in an organization
    • List an organization's teams
    • Create a team
    • Search for teams within an organization
    • Delete a team
    • Get a team
    • Edit a team
    • List a team's members
    • Remove a team member
    • List a particular member of team
    • Add a team member
    • List a team's repos
    • Remove a repository from a team
    • Add a repository to a team
    • List the current user's organizations
    • List a user's organizations
  • issue
    • Search for issues across the repositories that the user has access to
      GET
    • List a repository's issues
      GET
    • Create an issue. If using deadline only the date will be taken into account, and time of day ignored.
      POST
    • List all comments in a repository
      GET
    • Delete a comment
      DELETE
    • Get a comment
      GET
    • Edit a comment
      PATCH
    • Remove a reaction from a comment of an issue
      DELETE
    • Get a list of reactions from a comment of an issue
      GET
    • Add a reaction to a comment of an issue
      POST
    • Get an issue
      GET
    • Edit an issue. If using deadline only the date will be taken into account, and time of day ignored.
      PATCH
    • List all comments on an issue
      GET
    • Add a comment to an issue
      POST
    • Delete a comment
      DELETE
    • Edit a comment
      PATCH
    • 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.
      POST
    • Remove all labels from an issue
      DELETE
    • Get an issue's labels
      GET
    • Add a label to an issue
      POST
    • Replace an issue's labels
      PUT
    • Remove a label from an issue
      DELETE
    • Remove a reaction from an issue
      DELETE
    • Get a list reactions of an issue
      GET
    • Add a reaction to an issue
      POST
    • Delete an issue's existing stopwatch.
      DELETE
    • Start stopwatch on an issue.
      POST
    • Stop an issue's existing stopwatch.
      POST
    • Get users who subscribed on an issue.
      GET
    • Check if user is subscribed to an issue
      GET
    • Unsubscribe user from issue
      DELETE
    • Subscribe user to issue
      PUT
    • Reset a tracked time of an issue
      DELETE
    • List an issue's tracked times
      GET
    • Add tracked time to a issue
      POST
    • Delete specific tracked time
      DELETE
    • Get all of a repository's labels
      GET
    • Create a label
      POST
    • Delete a label
      DELETE
    • Get a single label
      GET
    • Update a label
      PATCH
    • Get all of a repository's opened milestones
      GET
    • Create a milestone
      POST
    • Delete a milestone
      DELETE
    • Get a milestone
      GET
    • Update a milestone
      PATCH
  • repository
    • Migrate a remote git repository
    • Search for repositories
    • Delete a repository
    • Get a repository
    • Edit a repository's properties. Only fields that are set will be changed.
    • Get an archive of a repository
    • Return all users that have write access and can be assigned to issues
    • List branch protections for a repository
    • Create a branch protections for a repository
    • Delete a specific branch protection for the repository
    • Get a specific branch protection for the repository
    • Edit a branch protections for a repository. Only fields that are set will be changed
    • List a repository's branches
    • Create a branch
    • Delete a specific branch from a repository
    • Retrieve a specific branch from a repository, including its effective branch protection
    • List a repository's collaborators
    • Delete a collaborator from a repository
    • Check if a user is a collaborator of a repository
    • Add a collaborator to a repository
    • Get a list of all commits from a repository
    • Get a commit's combined status, by branch/tag/commit reference
    • Get a commit's statuses, by branch/tag/commit reference
    • Gets the metadata of all the entries of the root dir
    • Delete a file in a repository
    • Gets the metadata and contents (if a file) of an entry in a repository, or a list of entries if a dir
    • Create a file in a repository
    • Update a file in a repository
    • Get the EditorConfig definitions of a file in a repository
    • List a repository's forks
    • Fork a repository
    • Gets the blob of a repository.
    • Get a single commit from a repository
    • Get a note corresponding to a single commit from a repository
    • Get specified ref or filtered repository's refs
    • Get specified ref or filtered repository's refs
    • Gets the tag object of an annotated tag (not lightweight tags)
    • Gets the tree of a repository.
    • List the hooks in a repository
    • Create a hook
    • List the Git hooks in a repository
    • Delete a Git hook in a repository
    • Get a Git hook
    • Edit a Git hook in a repository
    • Delete a hook in a repository
    • Get a hook
    • Edit a hook in a repository
    • Test a push webhook
    • Get available issue templates for a repository
    • List a repository's keys
    • Add a key to a repository
    • Delete a key from a repository
    • Get a repository's key by id
    • Get languages and number of bytes of code written
    • Sync a mirrored repository
    • List a repo's pull requests
    • Create a pull request
    • Get a pull request
    • Update a pull request. If using deadline only the date will be taken into account, and time of day ignored.
    • Get a pull request diff
    • Get a pull request patch file
    • Get commits for a pull request
    • Check if a pull request has been merged
    • Merge a pull request
    • cancel review requests for a pull request
    • create review requests for a pull request
    • List all reviews for a pull request
    • Create a review to an pull request
    • Delete a specific review from a pull request
    • Get a specific review for a pull request
    • Submit a pending review to an pull request
    • Get a specific review for a pull request
    • Dismiss a review for a pull request
    • Cancel to dismiss a review for a pull request
    • Merge PR's baseBranch into headBranch
    • Get a file from a repository
    • List a repo's releases
    • Create a release
    • Delete a release by tag name
    • Get a release by tag name
    • Delete a release
    • Get a release
    • Update a release
    • List release's attachments
    • Create a release attachment
    • Delete a release attachment
    • Get a release attachment
    • Edit a release attachment
    • Return all users that can be requested to review in this repo
    • Get signing-key.gpg for given repository
    • List a repo's stargazers
    • Get a commit's statuses
    • Create a commit status
    • List a repo's watchers
    • Unwatch a repo
    • Check if the current user is watching a repo
    • Watch a repo
    • List a repository's tags
    • Create a new git tag in a repository
    • Delete a repository's tag by name
    • Get the tag of a repository by tag name
    • List a repository's teams
    • Delete a team from a repository
    • Check if a team is assigned to a repository
    • Add a team to a repository
    • List a repo's tracked times
    • List a user's tracked times in a repo
    • Get list of topics that a repository has
    • Replace list of topics for a repository
    • Delete a topic from a repository
    • Add a topic to a repository
    • Transfer a repo ownership
    • Create a repository using a template
    • Get a repository by id
    • search topics via keyword
    • Create a repository
  • settings
    • Get instance's global settings for api
    • Get instance's global settings for Attachment
    • Get instance's global settings for repositories
    • Get instance's global settings for ui
  • user
    • Get the authenticated user
    • List the authenticated user's oauth2 applications
    • creates a new OAuth2 application
    • delete an OAuth2 Application
    • get an OAuth2 Application
    • update an OAuth2 Application, this includes regenerating the client secret
    • Delete email addresses
    • List the authenticated user's email addresses
    • Add email addresses
    • List the authenticated user's followers
    • List the users that the authenticated user is following
    • Unfollow a user
    • Check whether a user is followed by the authenticated user
    • Follow a user
    • Get a Token to verify
    • Verify a GPG key
    • List the authenticated user's GPG keys
    • Create a GPG key
    • Remove a GPG key
    • Get a GPG key
    • List the authenticated user's public keys
    • Create a public key
    • Delete a public key
    • Get a public key
    • List the repos that the authenticated user owns
    • Get user settings
    • Update user settings
    • The repos that the authenticated user has starred
    • Unstar the given repo
    • Whether the authenticated is starring the repo
    • Star the given repo
    • Get list of all existing stopwatches
    • List repositories watched by the authenticated user
    • List all the teams a user belongs to
    • List the current user's tracked times
    • Search for users
    • Check if one user is following another user
    • Get a user
    • List the given user's followers
    • List the users that the given user is following
    • List the given user's GPG keys
    • Get a user's heatmap
    • List the given user's public keys
    • List the repos owned by the given user
    • The repos that the given user has starred
    • List the repositories watched by a user
    • List the authenticated user's access tokens
    • Create an access token
    • delete an access token
  1. issue

Add tracked time to a issue

POST
/repos/{owner}/{repo}/issues/{index}/times
issue
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/api/v1/repos///issues//times' \
--header 'Content-Type: application/json' \
--data-raw '{
    "created": "2019-08-24T14:15:22Z",
    "time": 0,
    "user_name": "string"
}'
Response Response Example
200 - Example 1
{
    "created": "2019-08-24T14:15:22Z",
    "id": 0,
    "issue": {
        "assignee": {
            "active": true,
            "avatar_url": "string",
            "created": "2019-08-24T14:15:22Z",
            "description": "string",
            "email": "user@example.com",
            "followers_count": 0,
            "following_count": 0,
            "full_name": "string",
            "id": 0,
            "is_admin": true,
            "language": "string",
            "last_login": "2019-08-24T14:15:22Z",
            "location": "string",
            "login": "string",
            "prohibit_login": true,
            "restricted": true,
            "starred_repos_count": 0,
            "visibility": "string",
            "website": "string"
        },
        "assignees": [
            {
                "active": true,
                "avatar_url": "string",
                "created": "2019-08-24T14:15:22Z",
                "description": "string",
                "email": "user@example.com",
                "followers_count": 0,
                "following_count": 0,
                "full_name": "string",
                "id": 0,
                "is_admin": true,
                "language": "string",
                "last_login": "2019-08-24T14:15:22Z",
                "location": "string",
                "login": "string",
                "prohibit_login": true,
                "restricted": true,
                "starred_repos_count": 0,
                "visibility": "string",
                "website": "string"
            }
        ],
        "body": "string",
        "closed_at": "2019-08-24T14:15:22Z",
        "comments": 0,
        "created_at": "2019-08-24T14:15:22Z",
        "due_date": "2019-08-24T14:15:22Z",
        "html_url": "string",
        "id": 0,
        "is_locked": true,
        "labels": [
            {
                "color": "00aabb",
                "description": "string",
                "id": 0,
                "name": "string",
                "url": "string"
            }
        ],
        "milestone": {
            "closed_at": "2019-08-24T14:15:22Z",
            "closed_issues": 0,
            "created_at": "2019-08-24T14:15:22Z",
            "description": "string",
            "due_on": "2019-08-24T14:15:22Z",
            "id": 0,
            "open_issues": 0,
            "state": "string",
            "title": "string",
            "updated_at": "2019-08-24T14:15:22Z"
        },
        "number": 0,
        "original_author": "string",
        "original_author_id": 0,
        "pull_request": {
            "merged": true,
            "merged_at": "2019-08-24T14:15:22Z"
        },
        "ref": "string",
        "repository": {
            "full_name": "string",
            "id": 0,
            "name": "string",
            "owner": "string"
        },
        "state": "string",
        "title": "string",
        "updated_at": "2019-08-24T14:15:22Z",
        "url": "string",
        "user": {
            "active": true,
            "avatar_url": "string",
            "created": "2019-08-24T14:15:22Z",
            "description": "string",
            "email": "user@example.com",
            "followers_count": 0,
            "following_count": 0,
            "full_name": "string",
            "id": 0,
            "is_admin": true,
            "language": "string",
            "last_login": "2019-08-24T14:15:22Z",
            "location": "string",
            "login": "string",
            "prohibit_login": true,
            "restricted": true,
            "starred_repos_count": 0,
            "visibility": "string",
            "website": "string"
        }
    },
    "issue_id": 0,
    "time": 0,
    "user_id": 0,
    "user_name": "string"
}

Request

Path Params
owner
string 
required
owner of the repo
repo
string 
required
name of the repo
index
integer 
required
index of the issue
Body Params application/json
AddTimeOption options for adding time to an issue
created
string <date-time>
optional
time
integer <int64>
required
time in seconds
user_name
string 
optional
User who spent the time (optional)
Examples

Responses

🟢200OK
application/json
Body
TrackedTime worked time for an issue / pr
created
string <date-time>
optional
id
integer <int64>
optional
issue
object (Issue) 
optional
Issue represents an issue in a repository
assignee
object (User) 
optional
User represents a user
assignees
array[object (User) {19}] 
optional
body
string 
optional
closed_at
string <date-time>
optional
comments
integer <int64>
optional
created_at
string <date-time>
optional
due_date
string <date-time>
optional
html_url
string 
optional
id
integer <int64>
optional
is_locked
boolean 
optional
labels
array[object (Label) {5}] 
optional
milestone
object (Milestone) 
optional
Milestone milestone is a collection of issues on one repository
number
integer <int64>
optional
original_author
string 
optional
original_author_id
integer <int64>
optional
pull_request
object (PullRequestMeta) 
optional
PullRequestMeta PR info if an issue is a PR
ref
string 
optional
repository
object (RepositoryMeta) 
optional
RepositoryMeta basic repository information
state
string 
optional
StateType issue state type
title
string 
optional
updated_at
string <date-time>
optional
url
string 
optional
user
object (User) 
optional
User represents a user
issue_id
integer <int64>
optional
deprecated (only for backwards compatibility)
time
integer <int64>
optional
Time in seconds
user_id
integer <int64>
optional
deprecated (only for backwards compatibility)
user_name
string 
optional
🟠400400
🟠403403
Modified at 2022-09-10 23:12:52
Previous
List an issue's tracked times
Next
Delete specific tracked time
Built with