Executions
An execution is a single run of an app, it contains the inputs, outputs, and status of the run, and can be used to check the status of the run.
Returns the execution with the given uuid. You can use this endpoint to check the status of the execution.
The execution uuid
Execution found
successPossible values: 212334{"name":"John Doe"}{"greet":"Hello John Doe!"}The time it took to execute the app in seconds
34c3405f16-d0e8-4d5c-8ad9-85ef332c44ee12024-02-01 16:39:28.161000000 Z2024-02-01 16:39:28.161000000 ZAuthentication error
GET /public_api/airops_apps/executions/{execution_uuid} HTTP/1.1
Host: api.airops.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"id": 22,
"status": "success",
"airops_apps_version_id": 21,
"conversation_id": 23,
"credits_used": 34,
"error_code": null,
"error_message": null,
"feedback": "positive",
"inputs": {
"name": "John Doe"
},
"output": {
"greet": "Hello John Doe!"
},
"runtime": 34,
"source": null,
"uuid": "c3405f16-d0e8-4d5c-8ad9-85ef332c44ee",
"workspace_id": 1,
"createdAt": "2024-02-01 16:39:28.161000000 Z",
"updatedAt": "2024-02-01 16:39:28.161000000 Z"
}This endpoint allows you to execute an app. You can use this endpoint to execute an app and get the output of the execution.
Preconditions: the app must be published.
This endpoint executes the app immediately and returns the result, unless you are at your current capacity, or your app takes more than 10 minutes to run, in which case it will fail.
If you want to execute an app asynchronously, use the async_execute endpoint.
The app uuid
The version of the app (will use the default version if not provided)
12The inputs of the app
{"name":"John Doe"}Execution created
Invalid input
Authentication error
POST /public_api/airops_apps/{app_uuid}/execute HTTP/1.1
Host: api.airops.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 30
{
"inputs": {
"name": "John Doe"
}
}{
"id": 22,
"status": "success",
"airops_apps_version_id": 21,
"conversation_id": 23,
"credits_used": 34,
"error_code": null,
"error_message": null,
"feedback": "positive",
"inputs": {
"name": "John Doe"
},
"output": {
"greet": "Hello John Doe!"
},
"runtime": 34,
"source": null,
"uuid": "c3405f16-d0e8-4d5c-8ad9-85ef332c44ee",
"workspace_id": 1,
"createdAt": "2024-02-01 16:39:28.161000000 Z",
"updatedAt": "2024-02-01 16:39:28.161000000 Z"
}This endpoint allows you to execute an app asynchronously. You can use this endpoint to execute an app and get the execution id to check the status of the execution.
Preconditions: the app must be published.
Executions created through this endpoint will be queued and executed at your workspace's capacity.
If you want to execute an app immediately, use the execute endpoint.
The app uuid, you can find the app uuid by going to the App => Integrate
The version of the app (will use the default version if not provided)
12The inputs of the app
{"name":"John Doe"}Execution created
Invalid input
Authentication error
POST /public_api/airops_apps/{app_uuid}/async_execute HTTP/1.1
Host: api.airops.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 30
{
"inputs": {
"name": "John Doe"
}
}{
"id": 22,
"status": "pending",
"airops_apps_version_id": 21,
"conversation_id": null,
"credits_used": 34,
"error_code": null,
"error_message": null,
"feedback": null,
"inputs": {
"name": "John Doe"
},
"output": null,
"runtime": null,
"source": null,
"uuid": "c3405f16-d0e8-4d5c-8ad9-85ef332c44ee",
"workspace_id": 1,
"createdAt": "2024-02-01 16:39:28.161000000 Z",
"updatedAt": "2024-02-01 16:39:28.161000000 Z"
}This endpoint allows you to execute an app asynchronously as a webhook for an external service.
The payload of the request will be mapped to the first input of your app.
Preconditions: the app must be published.
More information on how to use this endpoint can be found here.
The app uuid, you can find the app uuid by going to the App => Integrate
Your workspace API key
23iu3h23-34n43yib4-3243n34b4-34n434hThe version of the app (will use the default version if not provided)
12The inputs of the app
{"name":"John Doe"}Execution created
Invalid input
Authentication error
POST /public_api/airops_apps/{app_uuid}/webhook_async_execute?auth_token=23iu3h23-34n43yib4-3243n34b4-34n434h HTTP/1.1
Host: api.airops.com
Content-Type: application/json
Accept: */*
Content-Length: 30
{
"inputs": {
"name": "John Doe"
}
}[
{
"id": 22,
"status": "success",
"airops_apps_version_id": 21,
"conversation_id": 23,
"credits_used": 34,
"error_code": null,
"error_message": null,
"feedback": "positive",
"inputs": {
"name": "John Doe"
},
"output": {
"greet": "Hello John Doe!"
},
"runtime": 34,
"source": null,
"uuid": "c3405f16-d0e8-4d5c-8ad9-85ef332c44ee",
"workspace_id": 1,
"createdAt": "2024-02-01 16:39:28.161000000 Z",
"updatedAt": "2024-02-01 16:39:28.161000000 Z"
}
]This endpoint allows you to cancel an execution.
Preconditions: the execution must be in the pending or running status.
The execution uuid
Execution cancelled
No content
Authentication error
PATCH /public_api/airops_apps/executions/{execution_uuid}/cancel HTTP/1.1
Host: api.airops.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
No content
This endpoint allows you to retry an execution from the last failed step.
Preconditions: the execution must be in the error status.
The execution uuid
Execution retried
No content
Execution is not in error status
Authentication error
POST /public_api/airops_apps/executions/{execution_uuid}/retry HTTP/1.1
Host: api.airops.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
No content
This endpoint allows you to rate an execution.
Preconditions: the execution must be in the success status.
The execution uuid
The feedback of the execution
positivePossible values: Feedback sent
No content
Authentication error
PATCH /public_api/airops_apps/executions/{execution_uuid}/feedback HTTP/1.1
Host: api.airops.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 23
{
"feedback": "positive"
}No content
Returns all the executions for a given Airops app. You can use this endpoint to check the status/input/output of all the executions.
The Airops app ID to fetch executions from
The cursor value to use for pagination
The amount of items to fetch
10Executions found
Authentication error
GET /public_api/airops_apps/:airops_app_id/executions?airops_app_id=1 HTTP/1.1
Host: api.airops.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
[
{
"data": [
{
"id": 22,
"status": "success",
"airops_apps_version_id": 21,
"conversation_id": 23,
"credits_used": 34,
"error_code": null,
"error_message": null,
"feedback": "positive",
"inputs": {
"name": "John Doe"
},
"output": {
"greet": "Hello John Doe!"
},
"runtime": 34,
"source": null,
"uuid": "c3405f16-d0e8-4d5c-8ad9-85ef332c44ee",
"workspace_id": 1,
"createdAt": "2024-02-01 16:39:28.161000000 Z",
"updatedAt": "2024-02-01 16:39:28.161000000 Z"
}
],
"meta": {
"count": 2,
"has_more": true,
"cursor": 22
}
}
]Last updated
Was this helpful?