Session grant endpoint

Session grant object

id string

Uniquely identifies this session grant.


claimed_at datetime

The moment this session grant was used to sign in as a Fullscript user.


expires_at datetime

Time the session grant expires at. Set to 120 seconds from the creation. Must be used in that time frame.


secret_token string

The string you’ll use to authenticate the Fullscript user when initializing your embeddable Fullscript.js feature.


user hash

Child attributes

  • id (string) The user’s unique Fullscript identifier (uid).
  • type (string) Type of user. One of Practitioner or Staff.

HTTP Request

POST https://api-us-snd.fullscript.io/api/clinic/embeddable/session_grants

Authorization Required

Bearer XXXXXXXXXXXXXXXXXXXX

Where XXXXXXXXXXXXXXXXXXXX is the current user’s OAuth access token.


Content-Type

application/json


Arguments

user_id

The user’s unique Fullscript user identifier (id). Required only when using clinic-level OAuth. Newer applications that use role-based OAuth don’t need to provide this, because it’s contained in the access token.


user_type

Practitioner or Staff. Required only when using clinic-level OAuth. Newer applications that use role-based OAuth don’t need to provide this, because it’s contained in the access token.


HTTP response

Returns a Session Grant object.

Example request

curl -X "POST" "https://api-us-snd.fullscript.io/api/clinic/embeddable/session_grants" \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer XXXXXXXXXXXXXXXXXXXX'

Example response

{
  "id": "aa43f1b7-8c3c-4dcb-9d49-e5c28601b10e",
  "secret_token": "yLGAfKXXXXz7LZufJRIIXXXXVCX0bXXXXpBVLXXXXZiEchU",
  "claimed_at": null,
  "expires_at": "2019-01-24T18:06:44.000Z",
  "user": {
    "type": "Practitioner",
    "id": "x1x0196x-5615-4874-xxx4-48x459180x09"
  }
}