Run an action
curl --request POST \
--url https://api.aisa.one/apis/v1/connector/actions/run \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"actionKey": "<string>",
"connectionId": "<string>",
"externalUserId": "<string>",
"input": "<unknown>"
}
'import requests
url = "https://api.aisa.one/apis/v1/connector/actions/run"
payload = {
"actionKey": "<string>",
"connectionId": "<string>",
"externalUserId": "<string>",
"input": "<unknown>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
actionKey: '<string>',
connectionId: '<string>',
externalUserId: '<string>',
input: '<unknown>'
})
};
fetch('https://api.aisa.one/apis/v1/connector/actions/run', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/connector/actions/run",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'actionKey' => '<string>',
'connectionId' => '<string>',
'externalUserId' => '<string>',
'input' => '<unknown>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/connector/actions/run"
payload := strings.NewReader("{\n \"actionKey\": \"<string>\",\n \"connectionId\": \"<string>\",\n \"externalUserId\": \"<string>\",\n \"input\": \"<unknown>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/connector/actions/run")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"actionKey\": \"<string>\",\n \"connectionId\": \"<string>\",\n \"externalUserId\": \"<string>\",\n \"input\": \"<unknown>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/connector/actions/run")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"actionKey\": \"<string>\",\n \"connectionId\": \"<string>\",\n \"externalUserId\": \"<string>\",\n \"input\": \"<unknown>\"\n}"
response = http.request(request)
puts response.read_body{
"connectionId": "<string>",
"output": "<unknown>",
"runId": "<string>"
}{
"error": {
"code": "<string>",
"details": {},
"message": "<string>",
"param": "<string>",
"retryHint": "<string>",
"retryable": true,
"type": "<string>"
}
}AIsa Connect
Run an action
Runs one action as one of your end users, on connectionId or on the end user’s newest active connection of the action’s app. The input is checked against the action’s input schema before anything is sent; the action is sent once and never retried. Send an Idempotency-Key to retry safely.
POST
https://api.aisa.one
/
apis
/
v1
/
connector
/
actions
/
run
Run an action
curl --request POST \
--url https://api.aisa.one/apis/v1/connector/actions/run \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"actionKey": "<string>",
"connectionId": "<string>",
"externalUserId": "<string>",
"input": "<unknown>"
}
'import requests
url = "https://api.aisa.one/apis/v1/connector/actions/run"
payload = {
"actionKey": "<string>",
"connectionId": "<string>",
"externalUserId": "<string>",
"input": "<unknown>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
actionKey: '<string>',
connectionId: '<string>',
externalUserId: '<string>',
input: '<unknown>'
})
};
fetch('https://api.aisa.one/apis/v1/connector/actions/run', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/connector/actions/run",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'actionKey' => '<string>',
'connectionId' => '<string>',
'externalUserId' => '<string>',
'input' => '<unknown>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/connector/actions/run"
payload := strings.NewReader("{\n \"actionKey\": \"<string>\",\n \"connectionId\": \"<string>\",\n \"externalUserId\": \"<string>\",\n \"input\": \"<unknown>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/connector/actions/run")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"actionKey\": \"<string>\",\n \"connectionId\": \"<string>\",\n \"externalUserId\": \"<string>\",\n \"input\": \"<unknown>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/connector/actions/run")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"actionKey\": \"<string>\",\n \"connectionId\": \"<string>\",\n \"externalUserId\": \"<string>\",\n \"input\": \"<unknown>\"\n}"
response = http.request(request)
puts response.read_body{
"connectionId": "<string>",
"output": "<unknown>",
"runId": "<string>"
}{
"error": {
"code": "<string>",
"details": {},
"message": "<string>",
"param": "<string>",
"retryHint": "<string>",
"retryable": true,
"type": "<string>"
}
}Request contract
- Method and path: POST /apis/v1/connector/actions/run
- Availability: enabled
- Request URL template:
https://api.aisa.one/apis/v1/connector/actions/run - Idempotency-Key: header; optional
{
"operationId": "post_aisa_connector_apis_v1_connector_actions_run",
"method": "POST",
"path": "/apis/v1/connector/actions/run",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [
{
"description": "A retry with the same key never runs the action again and is never charged again: it answers the first run's result, or idempotency_conflict while the first run is still in progress. AIsa never retries a run for you.",
"in": "header",
"name": "Idempotency-Key",
"required": false,
"schema": {
"maxLength": 191,
"minLength": 1,
"type": "string"
}
}
],
"security": [
{
"bearerAuth": []
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"additionalProperties": false,
"properties": {
"actionKey": {
"type": [
"string",
"null"
]
},
"connectionId": {
"type": [
"string",
"null"
]
},
"externalUserId": {
"type": [
"string",
"null"
]
},
"input": {}
},
"type": "object"
}
}
},
"required": true
},
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
Cost and request rules
Published reference price: $0.0003 USD per successful request. Failed or unknown outcomes are not charged. The same price applies on every plan.Authorizations
Headers
Body
application/json