
Custom Function Fields
Each field changes how the agent calls the external service.| Field | Purpose |
|---|---|
| Description | Tells the model when and why to use the function. |
| API Endpoint | The URL of the service the function calls. |
| HTTP Method | The request method used by the function. |
| API Token | Optional bearer-style credential for the target API. |
| Timeout | Maximum wait time in milliseconds. The default reducer value is 120000. |
| Headers | Additional key-value headers. |
| Query Parameters | Key-value values appended to the URL. |
| Response Variables | Named values the agent can use after the API response. |
| JSON Schema | Defines the format the model should return for function arguments. |
Dynamic Authorization For Chained API Calls
Custom function authentication can use values returned or supplied during the same tool call flow. This is useful when one function obtains a token and a later function must send that token to another API.| Pattern | Behavior |
|---|---|
| Static API token | Saved token is sent as Authorization when no custom header already sets it. |
| Token argument | Arguments named access_token, auth_token, api_token, or authorization can be used for the Authorization header. |
| Template token | API token values such as Bearer %(access_token)s are filled from function arguments. |
| Template headers | Custom headers can also use %(key)s substitutions from function arguments. |
Bearer <token> when they come from token argument fields. If the argument is named authorization, DialNexa sends the value as provided.
Example JSON Schema Pattern
Speech Behavior While A Function Runs
Callers should not sit in silence without context.Holding message
Short message spoken before calling the tool, useful when the API may take time.
Speak during execution
Allows the agent to keep the caller informed while the tool runs.
Speak after execution
Lets the agent explain the result after the tool returns.
Response variables
Expose API result values that the agent can mention or use in the next turn.
Custom Function Review Questions
Can the function fail gracefully?
Can the function fail gracefully?
Write prompt instructions for API errors, missing data, and timeouts.
Is the timeout realistic?
Is the timeout realistic?
A very long timeout may keep a caller waiting. A very short one may fail healthy APIs.
Are secrets in the right place?
Are secrets in the right place?
Use the API token or connection fields, not dynamic variables in prompts.
Can the model produce valid arguments?
Can the model produce valid arguments?
Keep JSON schema simple and test edge cases.
Related Reading
Functions
See all function types.
External Webhooks
Configure event delivery separately.
Dashboard Integrations
Use managed provider actions when they fit the job.
Testing Agents
Test function calls in real calls.