AI Actions (Functions)
Let the assistant call your own REST API mid-conversation — look up an order, capture a lead in your CRM, schedule a callback — and answer using the live result.
How it works
Open a chatbot → Functions. Define one or more actions (each maps to a REST endpoint on your API). During a conversation the assistant decides — based on each action's description — whether to call one. AskGPT executes the HTTP request server-side and feeds the response back into the reply, so the answer reflects live data from your system.
1. Configure the API connection
Set the shared Base URL and (optionally) an auth header that all actions use. The base URL must be a public HTTPS endpoint; internal/localhost addresses are blocked. The secret value is encrypted at rest and never returned to the browser.
- →Base URL — e.g. https://api.yoursite.com
- →Secret header — e.g. Authorization
- →Secret value — e.g. Bearer <token> (stored encrypted)
2. Add an action
Each action needs a name, a clear description (this is how the AI knows when to call it), a path appended to the base URL, an HTTP method, and any parameters the AI should fill.
- →Name — e.g. Check order status
- →Description — e.g. "Look up an order's status by its ID"
- →Path — e.g. /orders/{orderId} ({name} placeholders are filled from parameters)
- →Parameters — name, type (string/number/boolean), description, required
Triggers
Control when an action is offered to the assistant.
- →Always available — offered on every message
- →On user request — offered; the AI calls it when relevant
- →After lead captured — only once the visitor has shared their email
- →On human handoff — only after the chat is escalated
Request format
For POST/PUT/PATCH actions AskGPT sends a JSON body; GET/DELETE send parameters as the query string. Placeholders in the path are substituted first.
Security
Outbound calls are SSRF-hardened: the host is locked to your configured base URL (the AI can only choose the path/params, never the host), the resolved URL must be public HTTPS, internal/loopback/link-local IPs are blocked, redirects are not followed, and each call times out at 8 seconds. Responses are truncated before being passed to the model.
Scheduled (CRON) actions
The Functions tab lists a 'Schedule a function (CRON)' option, but timed execution requires a separate background worker and is not run by the app yet. Action calls triggered during a live conversation work today; scheduled runs are on the roadmap.
Need more help?
Contact support and we'll get back to you within 24 hours.