openapi: 3.0.0
info:
title: AI Service Actions API
version: 1.0.0
contact:
email: devel@keboola.com
license:
name: MIT
url: https://opensource.org/licenses/MIT
tags:
- name: Actions
paths:
/actions:
get:
summary: List available actions
description: 'Lists defined actions of a given component.
'
parameters:
- in: query
name: componentId
description: List actions for a given component.
required: true
schema:
type: string
examples:
id:
value: keboola.ex-example
responses:
'200':
description: Success response
content:
application/json:
schema:
type: array
items:
type: string
example:
- testConnection
- listTables
default:
description: Error response
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
tags:
- Actions
post:
summary: Process action
description: 'Runs the specified synchronous actions of the specified component.
'
requestBody:
content:
application/json:
schema:
type: object
required:
- componentId
- action
- configData
properties:
componentId:
type: string
example: keboola.ex-example
action:
type: string
example: testConnection
description: 'Use List available actions API call to get a allowed values.
'
configData:
description: 'Configuration data for the component.
'
type: object
example:
parameters:
foo: bar
mode:
type: string
enum:
- run
- debug
example: run
default: run
description: 'Mode of the action.
'
branchId:
type: string
example: '1234'
description: 'ID of the development branch. When empty the main branch is used.
'
tag:
type: string
example: 1.2.3
description: 'Version of the component to run. When empty, the latest published version is used.
'
examples:
Run configuration:
value:
component: keboola.ex-example
action: testConnection
configData:
foo: bar
Run debug configuration:
value:
component: keboola.ex-example
action: testConnection
mode: debug
configData:
foo: bar
Run configuration on a branch with a specific version of the component:
value:
component: keboola.ex-example
action: testConnection
configData:
foo: bar
tag: 1.2.3
branchId: '1234'
responses:
'201':
description: Action Succeeded
content:
application/json:
schema:
$ref: '#/components/schemas/Success'
default:
description: Error response
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
tags:
- Actions
components:
schemas:
Success:
type: object
description: Variable object with the response from the component.
example:
status: ok
Error:
type: object
required:
- error
- code
- status
- context
properties:
error:
type: string
example: The value foobar is invalid
code:
type: integer
example: 400
status:
type: string
enum:
- error
exceptionId:
type: string
example: exception-1234567890
context:
type: object
securitySchemes:
ApiKeyAuth:
type: apiKey
in: header
name: X-StorageApi-Token