Apache OpenWhisk Triggers API

The Triggers API from Apache OpenWhisk — 2 operation(s) for triggers.

OpenAPI Specification

apache-openwhisk-triggers-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Apache OpenWhisk REST Actions Triggers API
  description: Apache OpenWhisk is an open-source serverless cloud platform. The REST API provides endpoints for managing actions, triggers, rules, packages, and activations for serverless function development.
  version: 1.0.0
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0
  contact:
    url: https://openwhisk.apache.org/
servers:
- url: https://{host}/api/v1
  description: Apache OpenWhisk API server
  variables:
    host:
      default: localhost:443
security:
- basicAuth: []
tags:
- name: Triggers
paths:
  /namespaces/{namespace}/triggers:
    get:
      operationId: listTriggers
      summary: Apache OpenWhisk List Triggers
      description: List all triggers in the namespace.
      tags:
      - Triggers
      parameters:
      - $ref: '#/components/parameters/namespace'
      - name: limit
        in: query
        schema:
          type: integer
        description: Maximum number of triggers to return
      responses:
        '200':
          description: List of triggers
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Trigger'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /namespaces/{namespace}/triggers/{triggerName}:
    get:
      operationId: getTrigger
      summary: Apache OpenWhisk Get Trigger
      description: Get a trigger by name.
      tags:
      - Triggers
      parameters:
      - $ref: '#/components/parameters/namespace'
      - $ref: '#/components/parameters/triggerName'
      responses:
        '200':
          description: Trigger details
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Trigger'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    put:
      operationId: createOrUpdateTrigger
      summary: Apache OpenWhisk Create or Update Trigger
      description: Create or update a trigger.
      tags:
      - Triggers
      parameters:
      - $ref: '#/components/parameters/namespace'
      - $ref: '#/components/parameters/triggerName'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TriggerRequest'
      responses:
        '200':
          description: Trigger created or updated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Trigger'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    post:
      operationId: fireTrigger
      summary: Apache OpenWhisk Fire Trigger
      description: Fire a trigger, activating all associated rules.
      tags:
      - Triggers
      parameters:
      - $ref: '#/components/parameters/namespace'
      - $ref: '#/components/parameters/triggerName'
      requestBody:
        content:
          application/json:
            schema:
              type: object
              description: Trigger payload
      responses:
        '200':
          description: Trigger fired
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ActivationRef'
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    delete:
      operationId: deleteTrigger
      summary: Apache OpenWhisk Delete Trigger
      description: Delete a trigger.
      tags:
      - Triggers
      parameters:
      - $ref: '#/components/parameters/namespace'
      - $ref: '#/components/parameters/triggerName'
      responses:
        '200':
          description: Trigger deleted
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    Trigger:
      type: object
      properties:
        namespace:
          type: string
          example: guest
        name:
          type: string
          example: myTrigger
        version:
          type: string
          example: 0.0.1
        publish:
          type: boolean
          example: false
        annotations:
          type: array
          items:
            $ref: '#/components/schemas/KeyValue'
        parameters:
          type: array
          items:
            $ref: '#/components/schemas/KeyValue'
        updated:
          type: integer
          example: 1718153645993
    TriggerRequest:
      type: object
      properties:
        annotations:
          type: array
          items:
            $ref: '#/components/schemas/KeyValue'
        parameters:
          type: array
          items:
            $ref: '#/components/schemas/KeyValue'
    KeyValue:
      type: object
      properties:
        key:
          type: string
          description: Parameter key
          example: name
        value:
          description: Parameter value
          example: World
    ActivationRef:
      type: object
      properties:
        activationId:
          type: string
          description: Activation identifier for async invocations
          example: 44794bd6aab74415b4e42a308d880727
  parameters:
    triggerName:
      name: triggerName
      in: path
      required: true
      description: Trigger name
      schema:
        type: string
        example: myTrigger
    namespace:
      name: namespace
      in: path
      required: true
      description: OpenWhisk namespace
      schema:
        type: string
        example: guest
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: HTTP Basic authentication using OpenWhisk credentials
x-generated-from: documentation