Apigee Operations API

Manage long-running operations

Documentation

Specifications

Schemas & Data

Other Resources

OpenAPI Specification

apigee-operations-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Apigee API Hub Analytics Operations API
  description: API for cataloging, organizing, and governing APIs across an organization. Enables API discovery, metadata management, dependency mapping, deployment tracking, and AI-powered specification boost.
  version: 1.0.0
  contact:
    name: Google Cloud Apigee
    url: https://cloud.google.com/apigee/docs/apihub/what-is-api-hub
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0
  termsOfService: https://cloud.google.com/terms
servers:
- url: https://apihub.googleapis.com/v1
  description: Apigee API Hub Production Server
security:
- oauth2: []
tags:
- name: Operations
  description: Manage long-running operations
paths:
  /projects/{projectId}/locations/{locationId}/operations:
    get:
      operationId: listOperations
      summary: Apigee List Operations
      description: Lists long-running operations in the specified project and location.
      tags:
      - Operations
      parameters:
      - $ref: '#/components/parameters/projectId'
      - $ref: '#/components/parameters/locationId'
      - $ref: '#/components/parameters/pageSize'
      - $ref: '#/components/parameters/pageToken'
      - name: filter
        in: query
        description: Filter expression.
        schema:
          type: string
      responses:
        '200':
          description: Successful response with list of operations
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListOperationsResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
  /projects/{projectId}/locations/{locationId}/operations/{operationId}:
    get:
      operationId: getOperation
      summary: Apigee Get an Operation
      description: Gets the status of a long-running operation.
      tags:
      - Operations
      parameters:
      - $ref: '#/components/parameters/projectId'
      - $ref: '#/components/parameters/locationId'
      - name: operationId
        in: path
        description: Operation identifier.
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Successful response with operation status
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Operation'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
  /projects/{projectId}/locations/{locationId}/operations/{operationId}:cancel:
    post:
      operationId: cancelOperation
      summary: Apigee Cancel an Operation
      description: Cancels a long-running operation.
      tags:
      - Operations
      parameters:
      - $ref: '#/components/parameters/projectId'
      - $ref: '#/components/parameters/locationId'
      - name: operationId
        in: path
        description: Operation identifier.
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Successful response confirming cancellation
          content:
            application/json:
              schema:
                type: object
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  parameters:
    locationId:
      name: locationId
      in: path
      description: Google Cloud region or location.
      required: true
      schema:
        type: string
    pageToken:
      name: pageToken
      in: query
      description: Page token returned from a previous list request.
      schema:
        type: string
    pageSize:
      name: pageSize
      in: query
      description: Maximum number of items to return per page.
      schema:
        type: integer
        format: int32
    projectId:
      name: projectId
      in: path
      description: Google Cloud project ID.
      required: true
      schema:
        type: string
  schemas:
    Error:
      type: object
      description: Error response.
      properties:
        error:
          type: object
          properties:
            code:
              type: integer
              format: int32
            message:
              type: string
            status:
              type: string
    Operation:
      type: object
      description: A long-running operation.
      properties:
        name:
          type: string
          description: Name of the operation resource.
        metadata:
          type: object
          description: Service-specific metadata.
          additionalProperties: true
        done:
          type: boolean
          description: Whether the operation is complete.
        error:
          $ref: '#/components/schemas/Status'
        response:
          type: object
          description: The normal response of the operation.
          additionalProperties: true
    ListOperationsResponse:
      type: object
      properties:
        operations:
          type: array
          items:
            $ref: '#/components/schemas/Operation'
        nextPageToken:
          type: string
    Status:
      type: object
      description: The Status type defines a logical error model.
      properties:
        code:
          type: integer
          format: int32
        message:
          type: string
        details:
          type: array
          items:
            type: object
            additionalProperties: true
  responses:
    Forbidden:
      description: Forbidden. The caller does not have permission.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Unauthorized. Authentication credentials are missing or invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Not found. The specified resource does not exist.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    oauth2:
      type: oauth2
      description: Google OAuth 2.0 authentication
      flows:
        authorizationCode:
          authorizationUrl: https://accounts.google.com/o/oauth2/auth
          tokenUrl: https://oauth2.googleapis.com/token
          scopes:
            https://www.googleapis.com/auth/cloud-platform: Full access to Google Cloud Platform resources
externalDocs:
  description: Apigee API Hub API Reference Documentation
  url: https://cloud.google.com/apigee/docs/reference/apis/apihub/rest