Skip to main content
POST
/
calendar
/
self-schedule
/
appointment
Create Appointment
curl --request POST \
  --url https://api.decodahealth.com/calendar/self-schedule/appointment \
  --header 'API-KEY: <api-key>' \
  --header 'Content-Type: application/json' \
  --header 'TENANT: <tenant>' \
  --data '
{
  "serviceId": "<string>",
  "organizerId": "<string>",
  "providerId": "<string>",
  "locationId": "<string>",
  "start": "2023-11-07T05:31:56Z",
  "end": "2023-11-07T05:31:56Z",
  "notes": "<string>",
  "cancelEventId": "<string>"
}
'
{
  "id": "<string>",
  "title": "<string>",
  "start": "2023-11-07T05:31:56Z",
  "end": "2023-11-07T05:31:56Z",
  "type": "APPOINTMENT",
  "status": "PENDING",
  "organizer": {
    "id": "<string>",
    "type": "PROVIDER",
    "firstName": "<string>",
    "lastName": "<string>",
    "phoneNumber": "<string>",
    "email": "<string>",
    "locationId": "<string>"
  },
  "location": {
    "id": "<string>",
    "isVirtual": true,
    "name": "<string>",
    "addressLineOne": "<string>",
    "addressLineTwo": "<string>",
    "city": "<string>",
    "state": "<string>",
    "zipCode": "<string>",
    "country": "<string>",
    "createdDate": "2023-11-07T05:31:56Z",
    "spakinectLocationId": "<string>"
  },
  "attendees": [],
  "recurringEventId": "<string>",
  "recurringEvent": {
    "id": "<string>",
    "rrule": "<string>",
    "startDate": "2023-11-07T05:31:56Z",
    "durationMinutes": 123,
    "timezone": "<string>",
    "type": "APPOINTMENT",
    "title": "<string>",
    "organizerId": "<string>",
    "serviceIds": [
      "<string>"
    ],
    "capacity": 123,
    "attendeeIds": [
      "<string>"
    ],
    "locationId": "<string>"
  },
  "eventServices": [],
  "icons": [],
  "capacity": 123,
  "meetingLink": "<string>",
  "locationId": "<string>",
  "formCompleted": true,
  "reminders": [],
  "recurrenceModificationMode": "this",
  "createdDate": "2023-11-07T05:31:56Z",
  "quickNotes": [
    {
      "id": "<string>",
      "patientId": "<string>",
      "note": "<string>",
      "creator": {
        "id": "<string>",
        "type": "PROVIDER",
        "firstName": "<string>",
        "lastName": "<string>",
        "phoneNumber": "<string>",
        "email": "<string>",
        "locationId": "<string>"
      },
      "createdDate": "2023-11-07T05:31:56Z",
      "eventId": "<string>",
      "updatedDate": "2023-11-07T05:31:56Z",
      "isArchived": false
    }
  ]
}

Headers

TENANT
string
required

The tenant you are making this request on behalf of

API-KEY
string
required

Your api key

Body

application/json
serviceId
string
required
organizerId
string
required
providerId
string | null
locationId
string | null
start
string<date-time> | null
end
string<date-time> | null
notes
string | null
cancelEventId
string | null

Response

EventDetail · object | null

Successful Response

id
string
required
title
string
required
start
string<date-time>
required
end
string<date-time>
required
type
enum<string>
required
Available options:
APPOINTMENT,
SHIFT,
BLOCK
status
enum<string>
required
Available options:
PENDING,
RESERVED,
CONFIRMED,
CANCELLED,
COMPLETED,
OVERRIDABLE,
NO_SHOW
organizer
UserTiny · object
required
location
LocationSummary · object
attendees
AttendeeDetail · object[]
recurringEventId
string | null
recurringEvent
RecurringEventDetail · object
eventServices
EventServiceDetail · object[]
icons
enum<string>[]
Available options:
BOOKING_FEE_PAID,
NEW_PATIENT,
SCHEDULED_BY_AI,
FORM_COMPLETED,
CHECKED_IN
capacity
integer | null
locationId
string | null
formCompleted
boolean | null
reminders
string<date-time>[]
recurrenceModificationMode
enum<string> | null

Enum representing the different modes for handling recurring event modifications Used when modifying recurring events to specify which occurrences should be affected

Available options:
this,
future,
all
createdDate
string<date-time> | null
quickNotes
QuickNoteSummary · object[] | null