# Video Session URL: https://developers.vsee.io/use-cases/patient-video-session Log patient in using SSO, create an intake and walk-in visit, then redirect them directly into a video call with a provider. ## Step 1: Obtain patient access token POST /users/sso (auth: API Key + Secret) Call SSO with patient details (type=200). Use ?fields=vsee to include VSee ID and token in the response. headers: - X-ApiKey (required) — API Key - X-ApiSecret (required) — API Secret - X-AccountCode (required) — Account code queryParams: - fields — Set to 'vsee' to include VSee ID and token bodyFields: - first_name (required) — Patient's first name - last_name (required) — Patient's last name - type (required) — User type: 200 = Patient - email — Patient email address - code (required) — Unique patient identifier on your end (max 128 chars) ## Step 2: Create intake object POST /intakes (auth: User Token) Create an intake data object to capture the reason for visit. Uses the patient's access token from Step 1. headers: - X-ApiToken (required) — User access token from SSO response - X-AccountCode (required) — Account code bodyFields: - type (required) — Intake type (1 = standard) - room_code (required) — Room code for the waiting room - reason_for_visit — Reason for visit / chief complaint ## Step 3: Create a walk-in visit POST /visits/add_walkin (auth: User Token) Create a walk-in visit. The intake_id links the intake data from Step 2. headers: - X-ApiToken (required) — User access token from SSO response - X-AccountCode (required) — Account code bodyFields: - provider_id (required) — VSee member ID of the provider handling this visit (auto-fills from stored Provider Member ID) - intake_id (required) — Intake ID from Step 2 - room_code (required) — Room code for the waiting room ## Step 4: Redirect to video call Redirect: https://{your_clinic}.vseepreview.com/auth?sso_token={sso_token}&next=/visits/start/{visit_id} Redirect the patient directly into the video call/chat page for their visit.