AI Call Endpoint
curl --request GET \
--url https://app.aisync.link/api/ai/agent/call-endpoint \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.aisync.link/api/ai/agent/call-endpoint"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.aisync.link/api/ai/agent/call-endpoint', 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://app.aisync.link/api/ai/agent/call-endpoint",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.aisync.link/api/ai/agent/call-endpoint"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.aisync.link/api/ai/agent/call-endpoint")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.aisync.link/api/ai/agent/call-endpoint")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"status": "success",
"data": {
"endpoint": "",
"Method": "POST",
"form_data": [
"phone_number",
"email",
"first_name",
"last_name",
"ghl_contact_id",
"override_agent_id",
"local_presence_number=No (Yes/No)<br> [If Yes, then the call will be made from AI local presence number]"
]
}
}{
"error": "<string>",
"error_description": "<string>",
"message": "<string>"
}{
"error": "<string>",
"error_description": "<string>",
"message": "<string>"
}{
"error": "<string>",
"error_description": "<string>",
"message": "<string>"
}AI Agents
AI Call Endpoint
Retrieve the call endpoint URL for a specific AI agent. This endpoint provides the unique URL that can be used to initiate calls with the specified agent.
GET
/
api
/
ai
/
agent
/
call-endpoint
AI Call Endpoint
curl --request GET \
--url https://app.aisync.link/api/ai/agent/call-endpoint \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.aisync.link/api/ai/agent/call-endpoint"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.aisync.link/api/ai/agent/call-endpoint', 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://app.aisync.link/api/ai/agent/call-endpoint",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.aisync.link/api/ai/agent/call-endpoint"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.aisync.link/api/ai/agent/call-endpoint")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.aisync.link/api/ai/agent/call-endpoint")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"status": "success",
"data": {
"endpoint": "",
"Method": "POST",
"form_data": [
"phone_number",
"email",
"first_name",
"last_name",
"ghl_contact_id",
"override_agent_id",
"local_presence_number=No (Yes/No)<br> [If Yes, then the call will be made from AI local presence number]"
]
}
}{
"error": "<string>",
"error_description": "<string>",
"message": "<string>"
}{
"error": "<string>",
"error_description": "<string>",
"message": "<string>"
}{
"error": "<string>",
"error_description": "<string>",
"message": "<string>"
}AI Call Endpoint
Retrieve the call endpoint URL for a specific AI agent. This endpoint provides the unique URL that can be used to initiate calls with the specified agent.string
required
The unique identifier of the agent (e.g.,
agent_07a9005357b35d0943f7359ad9)string
required
Bearer token in the format:
Bearer {access_token}string
required
Must be set to
application/jsoncurl --location 'https://app.aisync.link/api/ai/agent/call-endpoint?agent_id=agent_07a9005357b35d0943f7359ad9' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer {{bearer_token}}'
string
Response status (e.g., “success”)
object
Response data object containing endpoint information
string
The unique endpoint URL for initiating calls with this agent
string
The HTTP method to use when calling the endpoint (typically “POST”)
array
Array of form field names that must be included when making a POST request to the endpoint:
phone_number: The phone number to callemail: Contact email addressfirst_name: Contact’s first namelast_name: Contact’s last nameghl_contact_id: GoHighLevel contact IDoverride_agent_id: Agent ID override (optional)local_presence_number: Set to “Yes” to make the call from AI local presence number, or “No” otherwise
Use the returned endpoint URL with POST method and include the required form_data fields to initiate conversations with your AI agent. The endpoint is unique to each agent. When
local_presence_number is set to “Yes”, the call will be made from the AI local presence number.Authorizations
Bearer token authentication. Include the access token in the Authorization header as 'Bearer {access_token}'
Query Parameters
The unique identifier of the agent (e.g., agent_07a9005357b35d0943f7359ad9)