Skip to main content
POST
Create Session

Authorizations

Authorization
string
header
required

Org API key as Token token=ei_live_...

Headers

Idempotency-Key
string | null

Body

application/json

POST /v1/sessions → tutor_sessions. Creates a SCHEDULED session only.

No charge is initiated here (see public_writes_batch2.py — real charging stays in the existing Stripe PaymentIntent + webhook flow). organization_id, creator_id, status ('scheduled'), the per-hour rate snapshot (resolved from the org rate matrix onto the session's participant), and timestamps are ALL server-set. tutor_id / student_id must be org-scoped. math_level_id is the subject identifier (text, e.g. 'methods_34').

tutor_id
string
required
student_id
string
required
math_level_id
string
required

Subject identifier, e.g. 'methods_34'

starts_at
string
required

ISO 8601 timestamp

ends_at
string
required

ISO 8601 timestamp; must be after starts_at

duration_minutes
integer
required

One of 30, 45, 60 (tutor_sessions CHECK)

mode
string
required

online | in_person

title
string | null

Optional; defaults server-side if omitted

Response

Successful Response

id
string
required
status
string | null
title
string | null
tutor_id
string | null
student_id
string | null
starts_at
string | null
ends_at
string | null
duration_minutes
integer | null
tutor_pay_rate_cents
integer | null
student_rate_cents
integer | null
amount_owed_cents
integer | null
mode
string | null
subject_id
string | null
created_at
string | null
completed_at
string | null