Gitea repository API

The repository API from Gitea — 133 operation(s) for repository.

Documentation

Specifications

Code Examples

💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-repo-get-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-repo-update-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-issues-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-issue-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-pulls-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-pull-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-branches-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-commits-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-release-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-webhook-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-org-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-org-repos-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-user-get-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-user-repo-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-admin-user-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-notifications-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-packages-list-owner-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-repository-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-issue-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-pullrequest-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-release-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-hook-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-package-example.json

Schemas & Data

📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-repository-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-issue-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-pullrequest-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-branch-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-commit-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-release-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-hook-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-organization-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-team-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-user-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-notificationthread-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-package-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-label-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-milestone-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-tag-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-comment-schema.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-repository-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-issue-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-pullrequest-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-branch-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-commit-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-release-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-hook-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-organization-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-team-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-user-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-notificationthread-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-package-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-label-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-milestone-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-tag-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-comment-structure.json

Other Resources

OpenAPI Specification

gitea-repository-api-openapi.yml Raw ↑
swagger: '2.0'
info:
  description: This documentation describes the Gitea API.
  title: Gitea admin repository 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: repository
paths:
  /repos/migrate:
    post:
      consumes:
      - application/json
      produces:
      - application/json
      tags:
      - repository
      summary: Migrate a remote git repository
      operationId: repoMigrate
      parameters:
      - name: body
        in: body
        schema:
          $ref: '#/definitions/MigrateRepoOptions'
      responses:
        '201':
          $ref: '#/responses/Repository'
        '403':
          $ref: '#/responses/forbidden'
        '409':
          description: The repository with the same name already exists.
        '422':
          $ref: '#/responses/validationError'
  /repos/search:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Search for repositories
      operationId: repoSearch
      parameters:
      - type: string
        description: keyword
        name: q
        in: query
      - type: boolean
        description: Limit search to repositories with keyword as topic
        name: topic
        in: query
      - type: boolean
        description: include search of keyword within repository description
        name: includeDesc
        in: query
      - type: integer
        format: int64
        description: search only for repos that the user with the given id owns or contributes to
        name: uid
        in: query
      - type: integer
        format: int64
        description: repo owner to prioritize in the results
        name: priority_owner_id
        in: query
      - type: integer
        format: int64
        description: search only for repos that belong to the given team id
        name: team_id
        in: query
      - type: integer
        format: int64
        description: search only for repos that the user with the given id has starred
        name: starredBy
        in: query
      - type: boolean
        description: include private repositories this user has access to (defaults to true)
        name: private
        in: query
      - type: boolean
        description: show only pubic, private or all repositories (defaults to all)
        name: is_private
        in: query
      - type: boolean
        description: include template repositories this user has access to (defaults to true)
        name: template
        in: query
      - type: boolean
        description: show only archived, non-archived or all repositories (defaults to all)
        name: archived
        in: query
      - type: string
        description: type of repository to search for. Supported values are "fork", "source", "mirror" and "collaborative"
        name: mode
        in: query
      - type: boolean
        description: if `uid` is given, search only for repos that the user owns
        name: exclusive
        in: query
      - type: string
        description: sort repos by attribute. Supported values are "alpha", "created", "updated", "size", "git_size", "lfs_size", "stars", "forks" and "id". Default is "alpha"
        name: sort
        in: query
      - type: string
        description: sort order, either "asc" (ascending) or "desc" (descending). Default is "asc", ignored if "sort" is not specified.
        name: order
        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/SearchResults'
        '422':
          $ref: '#/responses/validationError'
  /repos/{owner}/{repo}:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Get a repository
      operationId: repoGet
      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
      responses:
        '200':
          $ref: '#/responses/Repository'
        '404':
          $ref: '#/responses/notFound'
    delete:
      produces:
      - application/json
      tags:
      - repository
      summary: Delete a repository
      operationId: repoDelete
      parameters:
      - type: string
        description: owner of the repo to delete
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repo to delete
        name: repo
        in: path
        required: true
      responses:
        '204':
          $ref: '#/responses/empty'
        '403':
          $ref: '#/responses/forbidden'
        '404':
          $ref: '#/responses/notFound'
    patch:
      produces:
      - application/json
      tags:
      - repository
      summary: Edit a repository's properties. Only fields that are set will be changed.
      operationId: repoEdit
      parameters:
      - type: string
        description: owner of the repo to edit
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repo to edit
        name: repo
        in: path
        required: true
      - description: Properties of a repo that you can edit
        name: body
        in: body
        schema:
          $ref: '#/definitions/EditRepoOption'
      responses:
        '200':
          $ref: '#/responses/Repository'
        '403':
          $ref: '#/responses/forbidden'
        '404':
          $ref: '#/responses/notFound'
        '422':
          $ref: '#/responses/validationError'
  /repos/{owner}/{repo}/actions/artifacts:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Lists all artifacts for a repository
      operationId: getArtifacts
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: name of the artifact
        name: name
        in: query
      responses:
        '200':
          $ref: '#/responses/ArtifactsList'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/artifacts/{artifact_id}:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Gets a specific artifact for a workflow run
      operationId: getArtifact
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: id of the artifact
        name: artifact_id
        in: path
        required: true
      responses:
        '200':
          $ref: '#/responses/Artifact'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
    delete:
      produces:
      - application/json
      tags:
      - repository
      summary: Deletes a specific artifact for a workflow run
      operationId: deleteArtifact
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: id of the artifact
        name: artifact_id
        in: path
        required: true
      responses:
        '204':
          description: No Content
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/artifacts/{artifact_id}/zip:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Downloads a specific artifact for a workflow run redirects to blob url
      operationId: downloadArtifact
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: id of the artifact
        name: artifact_id
        in: path
        required: true
      responses:
        '302':
          description: redirect to the blob download
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/jobs:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Lists all jobs for a repository
      operationId: listWorkflowJobs
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: workflow status (pending, queued, in_progress, failure, success, skipped)
        name: status
        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/WorkflowJobsList'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/jobs/{job_id}:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Gets a specific workflow job for a workflow run
      operationId: getWorkflowJob
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: id of the job
        name: job_id
        in: path
        required: true
      responses:
        '200':
          $ref: '#/responses/WorkflowJob'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/jobs/{job_id}/logs:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Downloads the job logs for a workflow run
      operationId: downloadActionsRunJobLogs
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: id of the job
        name: job_id
        in: path
        required: true
      responses:
        '200':
          description: output blob content
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/runners:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Get repo-level runners
      operationId: getRepoRunners
      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: boolean
        description: filter by disabled status (true or false)
        name: disabled
        in: query
      responses:
        '200':
          $ref: '#/responses/RunnerList'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/runners/registration-token:
    post:
      produces:
      - application/json
      tags:
      - repository
      summary: Get a repository's actions runner registration token
      operationId: repoCreateRunnerRegistrationToken
      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
      responses:
        '200':
          $ref: '#/responses/RegistrationToken'
  /repos/{owner}/{repo}/actions/runners/{runner_id}:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Get a repo-level runner
      operationId: getRepoRunner
      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: id of the runner
        name: runner_id
        in: path
        required: true
      responses:
        '200':
          $ref: '#/responses/Runner'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
    delete:
      produces:
      - application/json
      tags:
      - repository
      summary: Delete a repo-level runner
      operationId: deleteRepoRunner
      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: id of the runner
        name: runner_id
        in: path
        required: true
      responses:
        '204':
          description: runner has been deleted
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
    patch:
      consumes:
      - application/json
      produces:
      - application/json
      tags:
      - repository
      summary: Update a repo-level runner
      operationId: updateRepoRunner
      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: id of the runner
        name: runner_id
        in: path
        required: true
      - name: body
        in: body
        schema:
          $ref: '#/definitions/EditActionRunnerOption'
      responses:
        '200':
          $ref: '#/responses/Runner'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
        '422':
          $ref: '#/responses/validationError'
  /repos/{owner}/{repo}/actions/runs:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Lists all runs for a repository run
      operationId: getWorkflowRuns
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: workflow event name
        name: event
        in: query
      - type: string
        description: workflow branch
        name: branch
        in: query
      - type: string
        description: workflow status (pending, queued, in_progress, failure, success, skipped)
        name: status
        in: query
      - type: string
        description: triggered by user
        name: actor
        in: query
      - type: string
        description: triggering sha of the workflow run
        name: head_sha
        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/WorkflowRunsList'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/runs/{run}:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Gets a specific workflow run
      operationId: GetWorkflowRun
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: id of the run
        name: run
        in: path
        required: true
      responses:
        '200':
          $ref: '#/responses/WorkflowRun'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
    delete:
      produces:
      - application/json
      tags:
      - repository
      summary: Delete a workflow run
      operationId: deleteActionRun
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: runid of the workflow run
        name: run
        in: path
        required: true
      responses:
        '204':
          description: No Content
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/runs/{run}/artifacts:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Lists all artifacts for a repository run
      operationId: getArtifactsOfRun
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: runid of the workflow run
        name: run
        in: path
        required: true
      - type: string
        description: name of the artifact
        name: name
        in: query
      responses:
        '200':
          $ref: '#/responses/ArtifactsList'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/runs/{run}/jobs:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Lists all jobs for a workflow run
      operationId: listWorkflowRunJobs
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: runid of the workflow run
        name: run
        in: path
        required: true
      - type: string
        description: workflow status (pending, queued, in_progress, failure, success, skipped)
        name: status
        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/WorkflowJobsList'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/runs/{run}/jobs/{job_id}/rerun:
    post:
      produces:
      - application/json
      tags:
      - repository
      summary: Reruns a specific workflow job in a run
      operationId: rerunWorkflowJob
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: id of the run
        name: run
        in: path
        required: true
      - type: integer
        description: id of the job
        name: job_id
        in: path
        required: true
      responses:
        '201':
          $ref: '#/responses/WorkflowJob'
        '400':
          $ref: '#/responses/error'
        '403':
          $ref: '#/responses/forbidden'
        '404':
          $ref: '#/responses/notFound'
        '422':
          $ref: '#/responses/validationError'
  /repos/{owner}/{repo}/actions/runs/{run}/rerun:
    post:
      produces:
      - application/json
      tags:
      - repository
      summary: Reruns an entire workflow run
      operationId: rerunWorkflowRun
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: id of the run
        name: run
        in: path
        required: true
      responses:
        '201':
          $ref: '#/responses/WorkflowRun'
        '400':
          $ref: '#/responses/error'
        '403':
          $ref: '#/responses/forbidden'
        '404':
          $ref: '#/responses/notFound'
        '422':
          $ref: '#/responses/validationError'
  /repos/{owner}/{repo}/actions/runs/{run}/rerun-failed-jobs:
    post:
      tags:
      - repository
      summary: Reruns all failed jobs in a workflow run
      operationId: rerunFailedWorkflowRun
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: integer
        description: id of the run
        name: run
        in: path
        required: true
      responses:
        '201':
          $ref: '#/responses/empty'
        '400':
          $ref: '#/responses/error'
        '403':
          $ref: '#/responses/forbidden'
        '404':
          $ref: '#/responses/notFound'
        '422':
          $ref: '#/responses/validationError'
  /repos/{owner}/{repo}/actions/secrets:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: List an repo's actions secrets
      operationId: repoListActionsSecrets
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        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/SecretList'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/secrets/{secretname}:
    put:
      consumes:
      - application/json
      produces:
      - application/json
      tags:
      - repository
      summary: Create or Update a secret value in a repository
      operationId: updateRepoSecret
      parameters:
      - type: string
        description: owner of the repository
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: name of the secret
        name: secretname
        in: path
        required: true
      - name: body
        in: body
        schema:
          $ref: '#/definitions/CreateOrUpdateSecretOption'
      responses:
        '201':
          description: response when creating a secret
        '204':
          description: response when updating a secret
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
    delete:
      consumes:
      - application/json
      produces:
      - application/json
      tags:
      - repository
      summary: Delete a secret in a repository
      operationId: deleteRepoSecret
      parameters:
      - type: string
        description: owner of the repository
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: name of the secret
        name: secretname
        in: path
        required: true
      responses:
        '204':
          description: delete one secret of the repository
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/tasks:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: List a repository's action tasks
      operationId: ListActionTasks
      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, default maximum page size is 50
        name: limit
        in: query
      responses:
        '200':
          $ref: '#/responses/TasksList'
        '400':
          $ref: '#/responses/error'
        '403':
          $ref: '#/responses/forbidden'
        '404':
          $ref: '#/responses/notFound'
        '409':
          $ref: '#/responses/conflict'
        '422':
          $ref: '#/responses/validationError'
  /repos/{owner}/{repo}/actions/variables:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Get repo-level variables list
      operationId: getRepoVariablesList
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        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/VariableList'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/variables/{variablename}:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Get a repo-level variable
      operationId: getRepoVariable
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: name of the variable
        name: variablename
        in: path
        required: true
      responses:
        '200':
          $ref: '#/responses/ActionVariable'
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
    put:
      produces:
      - application/json
      tags:
      - repository
      summary: Update a repo-level variable
      operationId: updateRepoVariable
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: name of the variable
        name: variablename
        in: path
        required: true
      - name: body
        in: body
        schema:
          $ref: '#/definitions/UpdateVariableOption'
      responses:
        '201':
          description: response when updating a repo-level variable
        '204':
          description: response when updating a repo-level variable
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
    post:
      produces:
      - application/json
      tags:
      - repository
      summary: Create a repo-level variable
      operationId: createRepoVariable
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: name of the variable
        name: variablename
        in: path
        required: true
      - name: body
        in: body
        schema:
          $ref: '#/definitions/CreateVariableOption'
      responses:
        '201':
          description: response when creating a repo-level variable
        '400':
          $ref: '#/responses/error'
        '409':
          description: variable name already exists.
        '500':
          $ref: '#/responses/error'
    delete:
      produces:
      - application/json
      tags:
      - repository
      summary: Delete a repo-level variable
      operationId: deleteRepoVariable
      parameters:
      - type: string
        description: owner of the repo
        name: owner
        in: path
        required: true
      - type: string
        description: name of the repository
        name: repo
        in: path
        required: true
      - type: string
        description: name of the variable
        name: variablename
        in: path
        required: true
      responses:
        '200':
          $ref: '#/responses/ActionVariable'
        '201':
          description: response when deleting a variable
        '204':
          description: response when deleting a variable
        '400':
          $ref: '#/responses/error'
        '404':
          $ref: '#/responses/notFound'
  /repos/{owner}/{repo}/actions/workflows:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: List repository workflows
      operationId: ActionsListRepositoryWorkflows
      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
      responses:
        '200':
          $ref: '#/responses/ActionWorkflowList'
        '400':
          $ref: '#/responses/error'
        '403':
          $ref: '#/responses/forbidden'
        '404':
          $ref: '#/responses/notFound'
        '422':
          $ref: '#/responses/validationError'
        '500':
          $ref: '#/responses/error'
  /repos/{owner}/{repo}/actions/workflows/{workflow_id}:
    get:
      produces:
      - application/json
      tags:
      - repository
      summary: Get a workflow
      operationId: ActionsGetWorkflow
      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
        requir

# --- truncated at 32 KB (328 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/openapi/gitea-repository-api-openapi.yml