Skip to main content
POST
/
bots
/
{botId}
/
scheduling
/
appointments
Schedule an appointment
curl --request POST \
  --url https://api.helloannie.com/v1/bots/{botId}/scheduling/appointments \
  --header 'Content-Type: application/json' \
  --data '
{
  "appointmentTypeId": "<string>",
  "startTime": "2026-06-15T20:00:00.000Z",
  "endTime": "2026-06-15T20:00:00.000Z",
  "patientInfo": {
    "firstName": "<string>",
    "lastName": "<string>",
    "dateOfBirth": "<string>",
    "phone": "+15551234567",
    "email": "jsmith@example.com",
    "patientId": "<string>"
  }
}
'
import requests

url = "https://api.helloannie.com/v1/bots/{botId}/scheduling/appointments"

payload = {
"appointmentTypeId": "<string>",
"startTime": "2026-06-15T20:00:00.000Z",
"endTime": "2026-06-15T20:00:00.000Z",
"patientInfo": {
"firstName": "<string>",
"lastName": "<string>",
"dateOfBirth": "<string>",
"phone": "+15551234567",
"email": "jsmith@example.com",
"patientId": "<string>"
}
}
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({
appointmentTypeId: '<string>',
startTime: '2026-06-15T20:00:00.000Z',
endTime: '2026-06-15T20:00:00.000Z',
patientInfo: {
firstName: '<string>',
lastName: '<string>',
dateOfBirth: '<string>',
phone: '+15551234567',
email: 'jsmith@example.com',
patientId: '<string>'
}
})
};

fetch('https://api.helloannie.com/v1/bots/{botId}/scheduling/appointments', 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.helloannie.com/v1/bots/{botId}/scheduling/appointments",
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([
'appointmentTypeId' => '<string>',
'startTime' => '2026-06-15T20:00:00.000Z',
'endTime' => '2026-06-15T20:00:00.000Z',
'patientInfo' => [
'firstName' => '<string>',
'lastName' => '<string>',
'dateOfBirth' => '<string>',
'phone' => '+15551234567',
'email' => 'jsmith@example.com',
'patientId' => '<string>'
]
]),
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.helloannie.com/v1/bots/{botId}/scheduling/appointments"

payload := strings.NewReader("{\n \"appointmentTypeId\": \"<string>\",\n \"startTime\": \"2026-06-15T20:00:00.000Z\",\n \"endTime\": \"2026-06-15T20:00:00.000Z\",\n \"patientInfo\": {\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"dateOfBirth\": \"<string>\",\n \"phone\": \"+15551234567\",\n \"email\": \"jsmith@example.com\",\n \"patientId\": \"<string>\"\n }\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.helloannie.com/v1/bots/{botId}/scheduling/appointments")
.header("Content-Type", "application/json")
.body("{\n \"appointmentTypeId\": \"<string>\",\n \"startTime\": \"2026-06-15T20:00:00.000Z\",\n \"endTime\": \"2026-06-15T20:00:00.000Z\",\n \"patientInfo\": {\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"dateOfBirth\": \"<string>\",\n \"phone\": \"+15551234567\",\n \"email\": \"jsmith@example.com\",\n \"patientId\": \"<string>\"\n }\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.helloannie.com/v1/bots/{botId}/scheduling/appointments")

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 \"appointmentTypeId\": \"<string>\",\n \"startTime\": \"2026-06-15T20:00:00.000Z\",\n \"endTime\": \"2026-06-15T20:00:00.000Z\",\n \"patientInfo\": {\n \"firstName\": \"<string>\",\n \"lastName\": \"<string>\",\n \"dateOfBirth\": \"<string>\",\n \"phone\": \"+15551234567\",\n \"email\": \"jsmith@example.com\",\n \"patientId\": \"<string>\"\n }\n}"

response = http.request(request)
puts response.read_body
{
  "success": true,
  "data": {
    "appointmentId": "<string>"
  }
}
{
"success": false,
"data": {},
"message": "<string>"
}
{
"success": false,
"data": {},
"message": "<string>"
}
{
"success": false,
"data": {},
"message": "<string>"
}
{
"success": false,
"data": {},
"message": "<string>"
}

Path Parameters

botId
string<uuid>
required

The ID of the bot

Body

Payload required to schedule an appointment. startTime and endTime may be copied directly from a returned availability slot.

appointmentTypeId
string
required

Opaque appointment type ID returned by the appointment-types endpoint

startTime
string
required

Whole-second UTC ISO 8601 timestamp ending in Z

Pattern: ^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}Z$
Example:

"2026-06-15T20:00:00.000Z"

endTime
string
required

Whole-second UTC ISO 8601 timestamp ending in Z

Pattern: ^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}Z$
Example:

"2026-06-15T20:00:00.000Z"

patientInfo
object
required

Patient information required to schedule an appointment

Response

Response returned after scheduling an appointment

success
enum<boolean>
required
Available options:
true
data
object
required

Data returned after scheduling an appointment