Suggest Meetings
curl --request POST \
--url https://api.example.com/v1/ai/suggest-meetings \
--header 'Content-Type: application/json' \
--data '
{
"contact_ids": [
{}
],
"window_days": 123,
"count": 123,
"only_open_deals": true
}
'import requests
url = "https://api.example.com/v1/ai/suggest-meetings"
payload = {
"contact_ids": [{}],
"window_days": 123,
"count": 123,
"only_open_deals": True
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({contact_ids: [{}], window_days: 123, count: 123, only_open_deals: true})
};
fetch('https://api.example.com/v1/ai/suggest-meetings', 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://api.example.com/v1/ai/suggest-meetings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'contact_ids' => [
[
]
],
'window_days' => 123,
'count' => 123,
'only_open_deals' => true
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/ai/suggest-meetings"
payload := strings.NewReader("{\n \"contact_ids\": [\n {}\n ],\n \"window_days\": 123,\n \"count\": 123,\n \"only_open_deals\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/v1/ai/suggest-meetings")
.header("Content-Type", "application/json")
.body("{\n \"contact_ids\": [\n {}\n ],\n \"window_days\": 123,\n \"count\": 123,\n \"only_open_deals\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/ai/suggest-meetings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"contact_ids\": [\n {}\n ],\n \"window_days\": 123,\n \"count\": 123,\n \"only_open_deals\": true\n}"
response = http.request(request)
puts response.read_body{
"data": {
"suggestions": [
{
"contact_id": "<string>",
"contact_name": "<string>",
"reason": "<string>",
"deal_id": "<string>",
"opportunity_value": 123,
"priority": "<string>",
"suggested_agenda": [
{}
],
"suggested_when": "<string>",
"confidence": 123
}
],
"credits_remaining": 123
}
}AI Analysis
Suggest Meetings
Suggest who the user should meet next across their pipeline, ranked by opportunity value
POST
/
v1
/
ai
/
suggest-meetings
Suggest Meetings
curl --request POST \
--url https://api.example.com/v1/ai/suggest-meetings \
--header 'Content-Type: application/json' \
--data '
{
"contact_ids": [
{}
],
"window_days": 123,
"count": 123,
"only_open_deals": true
}
'import requests
url = "https://api.example.com/v1/ai/suggest-meetings"
payload = {
"contact_ids": [{}],
"window_days": 123,
"count": 123,
"only_open_deals": True
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({contact_ids: [{}], window_days: 123, count: 123, only_open_deals: true})
};
fetch('https://api.example.com/v1/ai/suggest-meetings', 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://api.example.com/v1/ai/suggest-meetings",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'contact_ids' => [
[
]
],
'window_days' => 123,
'count' => 123,
'only_open_deals' => true
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/v1/ai/suggest-meetings"
payload := strings.NewReader("{\n \"contact_ids\": [\n {}\n ],\n \"window_days\": 123,\n \"count\": 123,\n \"only_open_deals\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/v1/ai/suggest-meetings")
.header("Content-Type", "application/json")
.body("{\n \"contact_ids\": [\n {}\n ],\n \"window_days\": 123,\n \"count\": 123,\n \"only_open_deals\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/v1/ai/suggest-meetings")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"contact_ids\": [\n {}\n ],\n \"window_days\": 123,\n \"count\": 123,\n \"only_open_deals\": true\n}"
response = http.request(request)
puts response.read_body{
"data": {
"suggestions": [
{
"contact_id": "<string>",
"contact_name": "<string>",
"reason": "<string>",
"deal_id": "<string>",
"opportunity_value": 123,
"priority": "<string>",
"suggested_agenda": [
{}
],
"suggested_when": "<string>",
"confidence": 123
}
],
"credits_remaining": 123
}
}This endpoint consumes 3 AI credits per call. If the workspace balance is insufficient, the API returns
402 insufficient_credits.Request
Headers
Authorization: Bearer wbk_your_api_key_here
Content-Type: application/json
string
Optional UUID for retry deduplication.
Body Parameters
array
Optional array of contact UUIDs to rank. When omitted, the endpoint considers the entire pipeline.
integer
default:"14"
Horizon in days for the suggested meeting time.
integer
default:"5"
Number of suggestions to return (1 - 20).
boolean
default:"true"
Restrict to contacts associated with open deals.
Response
object
Show properties
Show properties
array
Show Meeting suggestion
Show Meeting suggestion
integer
Balance after this call
X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset, and X-Request-ID.
curl -X POST \
https://data.leadlex.com/functions/v1/api-gateway/v1/ai/suggest-meetings \
-H "Authorization: Bearer wbk_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{"count": 5, "window_days": 14}'
import requests
API_KEY = "wbk_your_api_key_here"
BASE_URL = "https://data.leadlex.com/functions/v1/api-gateway"
r = requests.post(
f"{BASE_URL}/v1/ai/suggest-meetings",
headers={
"Authorization": f"Bearer {API_KEY}",
"Content-Type": "application/json",
},
json={"count": 5, "window_days": 14},
)
for s in r.json()["data"]["suggestions"]:
print(s["contact_name"], s["priority"], s["opportunity_value"])
const res = await fetch(
'https://data.leadlex.com/functions/v1/api-gateway/v1/ai/suggest-meetings',
{
method: 'POST',
headers: {
'Authorization': 'Bearer wbk_your_api_key_here',
'Content-Type': 'application/json',
},
body: JSON.stringify({ count: 5 }),
}
);
const { data } = await res.json();
console.log(data.suggestions);
Example Response
{
"data": {
"suggestions": [
{
"contact_id": "123e4567-e89b-12d3-a456-426614174000",
"contact_name": "Jane Doe",
"reason": "Open deal in Proposal stage with no meeting scheduled in the last 21 days.",
"deal_id": "deal_01HY1",
"opportunity_value": 45000,
"priority": "high",
"suggested_agenda": [
"Review fee proposal",
"Walk through engagement scope",
"Confirm kick-off date"
],
"suggested_when": "Within the next 3 business days",
"confidence": 0.87
}
],
"credits_remaining": 4858
}
}
Errors
| Status | Code | Description |
|---|---|---|
| 400 | validation_error | Invalid count or window_days |
| 401 | invalid_key | Invalid or expired API key |
| 402 | insufficient_credits | Workspace credit balance is exhausted |
| 403 | insufficient_permissions | Missing write:ai permission |
| 429 | rate_limited | Rate limit exceeded |