Skip to main content
POST
/
api
/
interaction
/
create
Interaction Create
curl --request POST \
  --url https://app.apigene.ai/api/interaction/create \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "api_name": "<string>",
  "user_input": "<string>",
  "context": {},
  "response_format": "raw",
  "execution_mode": "apigene_execution",
  "customer_execution_context": {},
  "model": "<string>"
}
'
[
  {
    "action_name": "N/A",
    "status_code": 555,
    "raw_data": "<unknown>",
    "response_content": "<unknown>",
    "context": "<unknown>"
  }
]

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Example: 'Authorization: Bearer {token}'

Body

application/json
api_name
string
required

Name of the API.

user_input
string
required

User input data.

context
Context · object

Additional context parameters that may include relevant info for the LLM

response_format
string
default:raw

Control the response format available option are raw / formatted_html / formatted_md / formatted_text

execution_mode
enum<string>
default:apigene_execution

Controls how the request is executed: dry_run_execution (returns request without sending), apigene_execution (Apigene handles execution with stored credentials), customer_execution (request is forwarded to customer's webhook where the customer is responsible for executing it with their own credentials)

Available options:
dry_run_execution,
apigene_execution,
customer_execution
customer_execution_context
Customer Execution Context · object

Customer-specific context data for correlation and tracking in customer execution mode

model
string | null

Overide the default model that will be used for executing this interaction

Response

Successful Response

action_name
string
default:N/A

Name of the action.

status_code
integer
default:555

The status code of the response.

raw_data
any | null

Content of the request to relevant service.

response_content
any | null

Content of the response.

context
any | null

Addtional context information that is passed to the action