Hold a slot
curl --request POST \
--url https://api.maxcare.ai/v2/schedule/holds \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Organization-Id: <x-organization-id>' \
--data '
{
"providerId": "<string>",
"facilityId": "<string>",
"appointmentTypeId": "<string>",
"startsAt": "2026-08-03T08:00:00-04:00",
"durationMinutes": 15,
"ttlSeconds": 600
}
'import requests
url = "https://api.maxcare.ai/v2/schedule/holds"
payload = {
"providerId": "<string>",
"facilityId": "<string>",
"appointmentTypeId": "<string>",
"startsAt": "2026-08-03T08:00:00-04:00",
"durationMinutes": 15,
"ttlSeconds": 600
}
headers = {
"X-Organization-Id": "<x-organization-id>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Organization-Id': '<x-organization-id>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
providerId: '<string>',
facilityId: '<string>',
appointmentTypeId: '<string>',
startsAt: '2026-08-03T08:00:00-04:00',
durationMinutes: 15,
ttlSeconds: 600
})
};
fetch('https://api.maxcare.ai/v2/schedule/holds', 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.maxcare.ai/v2/schedule/holds",
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([
'providerId' => '<string>',
'facilityId' => '<string>',
'appointmentTypeId' => '<string>',
'startsAt' => '2026-08-03T08:00:00-04:00',
'durationMinutes' => 15,
'ttlSeconds' => 600
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"X-Organization-Id: <x-organization-id>"
],
]);
$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.maxcare.ai/v2/schedule/holds"
payload := strings.NewReader("{\n \"providerId\": \"<string>\",\n \"facilityId\": \"<string>\",\n \"appointmentTypeId\": \"<string>\",\n \"startsAt\": \"2026-08-03T08:00:00-04:00\",\n \"durationMinutes\": 15,\n \"ttlSeconds\": 600\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Organization-Id", "<x-organization-id>")
req.Header.Add("Authorization", "Bearer <token>")
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.maxcare.ai/v2/schedule/holds")
.header("X-Organization-Id", "<x-organization-id>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"providerId\": \"<string>\",\n \"facilityId\": \"<string>\",\n \"appointmentTypeId\": \"<string>\",\n \"startsAt\": \"2026-08-03T08:00:00-04:00\",\n \"durationMinutes\": 15,\n \"ttlSeconds\": 600\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.maxcare.ai/v2/schedule/holds")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Organization-Id"] = '<x-organization-id>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"providerId\": \"<string>\",\n \"facilityId\": \"<string>\",\n \"appointmentTypeId\": \"<string>\",\n \"startsAt\": \"2026-08-03T08:00:00-04:00\",\n \"durationMinutes\": 15,\n \"ttlSeconds\": 600\n}"
response = http.request(request)
puts response.read_body{
"code": "success",
"data": {
"id": "hld_9f2c1d0e3b4a5968778695a4b3c2d1e0",
"expiresAt": "2026-07-26T13:10:00.000Z",
"advisory": true
}
}{
"code": "bad_request",
"message": "'id' must be a valid UUID",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "unauthorized",
"message": "Invalid or missing API key",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "forbidden",
"message": "Insufficient scope",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "conflict",
"message": "Cannot edit a signed note",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "rate_limit_exceeded",
"message": "Rate limit exceeded. Maximum 1000 requests per 60 seconds.",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "server_unresponsive",
"message": "EHR integration is not available for this note",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}Schedule
Hold a slot
Reserves a slot for ttlSeconds (default 600) so two booking sessions cannot sell it twice. Holds are shared across Max AI replicas and subtracted from slot search. advisory: true means the EHR is not holding anything — a human booking directly in the EHR can still take the slot, and the booking write re-validates against the EHR. Returns 409 slot_unavailable when the slot is already held.
POST
/
schedule
/
holds
Hold a slot
curl --request POST \
--url https://api.maxcare.ai/v2/schedule/holds \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Organization-Id: <x-organization-id>' \
--data '
{
"providerId": "<string>",
"facilityId": "<string>",
"appointmentTypeId": "<string>",
"startsAt": "2026-08-03T08:00:00-04:00",
"durationMinutes": 15,
"ttlSeconds": 600
}
'import requests
url = "https://api.maxcare.ai/v2/schedule/holds"
payload = {
"providerId": "<string>",
"facilityId": "<string>",
"appointmentTypeId": "<string>",
"startsAt": "2026-08-03T08:00:00-04:00",
"durationMinutes": 15,
"ttlSeconds": 600
}
headers = {
"X-Organization-Id": "<x-organization-id>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Organization-Id': '<x-organization-id>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
providerId: '<string>',
facilityId: '<string>',
appointmentTypeId: '<string>',
startsAt: '2026-08-03T08:00:00-04:00',
durationMinutes: 15,
ttlSeconds: 600
})
};
fetch('https://api.maxcare.ai/v2/schedule/holds', 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.maxcare.ai/v2/schedule/holds",
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([
'providerId' => '<string>',
'facilityId' => '<string>',
'appointmentTypeId' => '<string>',
'startsAt' => '2026-08-03T08:00:00-04:00',
'durationMinutes' => 15,
'ttlSeconds' => 600
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"X-Organization-Id: <x-organization-id>"
],
]);
$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.maxcare.ai/v2/schedule/holds"
payload := strings.NewReader("{\n \"providerId\": \"<string>\",\n \"facilityId\": \"<string>\",\n \"appointmentTypeId\": \"<string>\",\n \"startsAt\": \"2026-08-03T08:00:00-04:00\",\n \"durationMinutes\": 15,\n \"ttlSeconds\": 600\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Organization-Id", "<x-organization-id>")
req.Header.Add("Authorization", "Bearer <token>")
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.maxcare.ai/v2/schedule/holds")
.header("X-Organization-Id", "<x-organization-id>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"providerId\": \"<string>\",\n \"facilityId\": \"<string>\",\n \"appointmentTypeId\": \"<string>\",\n \"startsAt\": \"2026-08-03T08:00:00-04:00\",\n \"durationMinutes\": 15,\n \"ttlSeconds\": 600\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.maxcare.ai/v2/schedule/holds")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Organization-Id"] = '<x-organization-id>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"providerId\": \"<string>\",\n \"facilityId\": \"<string>\",\n \"appointmentTypeId\": \"<string>\",\n \"startsAt\": \"2026-08-03T08:00:00-04:00\",\n \"durationMinutes\": 15,\n \"ttlSeconds\": 600\n}"
response = http.request(request)
puts response.read_body{
"code": "success",
"data": {
"id": "hld_9f2c1d0e3b4a5968778695a4b3c2d1e0",
"expiresAt": "2026-07-26T13:10:00.000Z",
"advisory": true
}
}{
"code": "bad_request",
"message": "'id' must be a valid UUID",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "unauthorized",
"message": "Invalid or missing API key",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "forbidden",
"message": "Insufficient scope",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "conflict",
"message": "Cannot edit a signed note",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "rate_limit_exceeded",
"message": "Rate limit exceeded. Maximum 1000 requests per 60 seconds.",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "server_unresponsive",
"message": "EHR integration is not available for this note",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}Authorizations
Marketplace API key
Headers
Target clinic organization ID
Body
application/json
Provider ID (prv_…)
Facility ID (fac_…)
Appointment type ID (atp_…)
Slot start, ISO-8601 with explicit offset
Example:
"2026-08-03T08:00:00-04:00"
Slot length in minutes
Example:
15
Hold lifetime in seconds (30–1800). Defaults to 600.
Example:
600
