Function Calling
Custom Functions
Custom functions will POST to the provided URL with the following application/json body schema:
interface FunctionCallPayload { org_id: string campaign_id: string call_id: string job_id: string job_data: Record<string, any> // the `data` field from the Job job_metadata: Record<string, any> // the `metadata` field from the Job function: string parameters: Record<string, any> // param name -> value}Injecting context
What ever you return from this call will be injected into the conversation context. If you do not wish to inject context, return a blank body.
If you do not have explicit information to add, return a blank body. We will ensure that the agent knows that the action has completed.
Auth
To verify that a function call came from Cobbery, store some API secret in the job data that you can then check when receiving the request.