MadHive Ability to pause a campaign and all of its associated line items and creatives API

The Ability to pause a campaign and all of its associated line items and creatives API from MadHive — 1 operation(s) for ability to pause a campaign and all of its associated line items and creatives.

OpenAPI Specification

madhive-ability-to-pause-a-campaign-and-all-of-its-associated-line-items-and-creatives-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Madhive Ability to pause a campaign and all of its associated line items and creatives API
  version: 1.0.0
  description: "The Madhive API provides a comprehensive interface for digital advertising clients and services.\n\n## Authentication\nThis API uses OAuth 2.0 client credentials flow for authentication. To access protected endpoints:\n\n1. **Obtain an access token** using the `/oauth/token` endpoint with your client credentials\n2. **Include the token** in subsequent API requests using the `Authorization` header:\n   ```\n   Authorization: Bearer YOUR_ACCESS_TOKEN_HERE\n   ```\n\n### Token Usage Example\n```bash\n# Get access token\ncurl -X POST \"https://api2.madhive.com/oauth/token\" \\\n  -H \"Content-Type: application/x-www-form-urlencoded\" \\\n  -d \"grant_type=client_credentials&client_id=YOUR_CLIENT_ID&client_secret=YOUR_CLIENT_SECRET\"\n\n# Use token in API requests\ncurl -H \"Authorization: Bearer YOUR_ACCESS_TOKEN_HERE\" \\\n  \"https://api2.madhive.com/v1/campaigns\"\n```\n\n**Note:** Access tokens have an expiration time. You should handle token refresh in your application logic.\n"
servers:
- url: https://api2.madhive.com/api
  description: apigee
tags:
- name: Ability to pause a campaign and all of its associated line items and creatives
paths:
  /v1/campaigns/{id}/activation:
    delete:
      tags:
      - Ability to pause a campaign and all of its associated line items and creatives
      summary: Ability to pause a campaign and all of its associated line items and creatives
      description: Ability to pause a campaign and all of its associated line items and creatives. If a line item is not live it is not affected
      operationId: deactivateCampaignById
      parameters:
      - $ref: '#/components/parameters/PathID'
      responses:
        '200':
          $ref: '#/components/responses/200PauseResource'
        '400':
          $ref: '#/components/responses/400InvalidID'
        '401':
          $ref: '#/components/responses/401Unauthorized'
      security:
      - oauth2: []
components:
  responses:
    400InvalidID:
      description: Invalid input
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            response:
              $ref: '#/components/examples/400InvalidID'
    200PauseResource:
      description: successful pause operation
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/GenericResponse'
          examples:
            response:
              $ref: '#/components/examples/200PauseResource'
    401Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            response:
              $ref: '#/components/examples/401Ex'
  schemas:
    ErrorResponse:
      type: object
      required:
      - transaction
      properties:
        errors:
          type: array
          x-go-type-skip-optional-pointer: true
          items:
            type: string
          description: many error messages
        error:
          type: string
          x-go-type-skip-optional-pointer: true
          description: error message
          example: Unauthorized
        status:
          type: string
          x-go-type-skip-optional-pointer: true
          description: status of the service
          example: ERROR
        transaction:
          $ref: '#/components/schemas/Transaction'
    Transaction:
      type: object
      x-go-type-skip-optional-pointer: true
      x-omitempty: false
      required:
      - id
      - taskId
      - created
      properties:
        id:
          type: string
          description: trace id
          example: 4af459ff8e1a36b6bb74fb88f1a02477
        taskId:
          type: string
          x-omitempty: true
          description: task id
          example: '14158884487309867565'
        created:
          type: string
          description: 'order created date, format: yyyy-mm-dd hh:mm:ss'
          example: '2030-11-02T15:04:00Z'
    GenericResponse:
      type: object
      required:
      - id
      - message
      - transaction
      properties:
        id:
          type: string
          description: resource id
          example: 4af459ff8e1a36b6bb74fb88f1a02477
        message:
          type: string
          description: response message
          example: success
        error:
          type: string
          description: error message
          example: unable to process request
        transaction:
          $ref: '#/components/schemas/Transaction'
  parameters:
    PathID:
      name: id
      in: path
      description: resource id
      required: true
      schema:
        type: string
        x-oapi-codegen-extra-tags:
          validate: required,min=28,max=28
  examples:
    401Ex:
      value:
        error: unauthorized
        status: ERROR
        transaction:
          id: 4af459ff8e1a36b6bb74fb88f1a02477
          taskId: '14158884487309867565'
          created: '2030-11-02T15:04:00Z'
    400InvalidID:
      value:
        error: invalid resource id
        status: ERROR
        transaction:
          id: 4af459ff8e1a36b6bb74fb88f1a02477
          taskId: '14158884487309867565'
          created: '2030-11-02T15:04:00Z'
    200PauseResource:
      value:
        id: UoMlEJ6pH6tcSOKgnERrWH7lWfwL
        message: resource successfully paused
        transaction:
          id: 4af459ff8e1a36b6bb74fb88f1a02477
          taskId: '14158884487309867565'
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://api2.madhive.com/oauth/token
          scopes: {}
    basicAuth:
      type: http
      description: Basic Authentication Not Implemented
      scheme: basic
    bearerAuth:
      type: apiKey
      name: Authorization
      in: header
      description: jwt access token for authentication