Skip to main content

Spakinect EMR Integration API (1.0.0)

Download OpenAPI specification:Download

Spakinect Support: support@spakinect.com

API for External Electronic Medical Record (EMR) systems to integrate with Spakinect telemedicine platform. Provides endpoints for managing appointments, retrieving treatments, and checking visit statuses.

Appointments

Operations for creating and managing Good Faith Exam appointments

Creates a new At-Home Visit

Creates a new At-Home Visit (Good Faith Exam (GFE)) in the Spakinect system. The patient will be emailed and texted a link to complete their GFE prior to their appointment at the medspa. Optionally, EMR systems can submit intake answers when creating the appointment; these are pre-filled for the patient when they start the visit.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
required
object (PatientDetails)
location_id
required
string

The ID of the location where the appointment will take place

appointment_time
required
integer >= 1

Unix timestamp of the appointment date and time with the medspa. This is different from the appointment time with Spakinect (provider). To schedule an appointment with a Spakinect provider, the patient can use the Schedule link in the email sent from Spakinect.

requested_treatments
required
Array of strings non-empty

List of treatment names requested for this appointment

Array of objects
optional: true

Submit intake question answers while creating the appointment for at-home visit patients so they can review and modify them if needed.

Supported question codes:

  • pregnant-breastfeeding-ivf (pregnancy/breastfeeding/IVF status)
  • medications
  • allergies
  • medical-conditions

Responses

Request samples

Content type
application/json
Example
{
  • "patient_details": {
    },
  • "location_id": "loc_12345",
  • "appointment_time": 1640995200,
  • "requested_treatments": [
    ]
}

Response samples

Content type
application/json
{
  • "success": true,
  • "gfe_id": "gfe_abc123xyz789"
}

Get Visit Status

Retrieves the current status and details of a Good Faith Exam (GFE) visit by ID. Only returns visits that the authenticated EMR has access to based on location permissions. When the visit status is "Completed", the response includes decision outcomes mapped to treatment names: approved_treatments, conditionally_approved_treatments, and deferred_treatments.

Authorizations:
ApiKeyAuth
path Parameters
gfe_id
required
string
Example: gfe_abc123xyz789

The unique identifier of the GFE visit

Responses

Response samples

Content type
application/json
Example
{
  • "success": true,
  • "data": {
    }
}

Cancels an At-Home Visit

Cancels an At-Home Visit Good Faith Exam by ID. Only visits with status "Processing", "Scheduled", or "Not Completed" can be cancelled. The visit status will be updated to "Cancelled by client". Only appointments that the authenticated EMR has access to based on location permissions can be cancelled.

Authorizations:
ApiKeyAuth
path Parameters
gfe_id
required
string
Example: gfe_abc123xyz789

The unique identifier of the GFE appointment to cancel

Responses

Response samples

Content type
application/json
{
  • "gfe_id": "gfe_abc123xyz789",
  • "status": "Cancelled by client"
}

GFEs

Operations for retrieving Good Faith Exam visits by location

Get All GFEs by Location

Retrieves all Good Faith Exam (GFE) visits for a specific location. Only returns visits that the authenticated EMR has access to based on location permissions. When visit status is "Completed", each visit includes decision outcomes mapped to treatment names: approved_treatments, conditionally_approved_treatments, and deferred_treatments.

Authorizations:
ApiKeyAuth
path Parameters
location_id
required
string
Example: loc_12345

The unique identifier of the location

Responses

Response samples

Content type
application/json
Example
{
  • "success": true,
  • "location_id": "loc_12345",
  • "count": 2,
  • "gfes": [
    ]
}

Treatments

Operations for retrieving available medical treatments

Get Available Treatments

Retrieves treatments. Returns all available treatments by default, or favorite treatments when type=favorites and location_id are provided.

URLs:

  • All treatments: GET /treatments
  • Favorite treatments: GET /treatments?type=favorites&location_id=<location_id>
Authorizations:
ApiKeyAuth
query Parameters
type
string
Value: "favorites"

When set to 'favorites', returns the client's favorite treatments for the given location. Requires location_id.

location_id
string
Example: location_id=loc_12345

Required when type=favorites. The unique identifier of the location. Used to resolve the client and fetch their favorite treatments.

Responses

Response samples

Content type
application/json
Example
{
  • "data": [
    ]
}

InPerson

Operations for creating and managing in-person intake visits

Get Visit Status

Retrieves the current status and details of a Good Faith Exam (GFE) visit by ID. Only returns visits that the authenticated EMR has access to based on location permissions. When the visit status is "Completed", the response includes decision outcomes mapped to treatment names: approved_treatments, conditionally_approved_treatments, and deferred_treatments.

Authorizations:
ApiKeyAuth
path Parameters
gfe_id
required
string
Example: gfe_abc123xyz789

The unique identifier of the GFE visit

Responses

Response samples

Content type
application/json
Example
{
  • "success": true,
  • "data": {
    }
}

Create a new in-person visit

Creates a new in-person visit for a patient. If a matching patient is found by name and date of birth, their record is used; otherwise, a new patient record is created. Optionally, EMR systems can submit intake answers when creating the visit; these are pre-filled for the patient when they open the intake form.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
required
object
location_id
required
string

The ID of the location where the visit will take place.

requested_treatments
required
Array of strings non-empty

A non-empty list of treatment names requested for the visit.

Array of objects
optional: true

Submit intake question answers while creating the visit so the patient sees them pre-filled when they open the intake form.

Supported question codes:

  • pregnant-breastfeeding-ivf (pregnancy/breastfeeding/IVF status)
  • medications
  • allergies
  • medical-conditions

Responses

Request samples

Content type
application/json
Example
{
  • "patient_details": {
    },
  • "location_id": "loc_12345",
  • "requested_treatments": [
    ]
}

Response samples

Content type
application/json
{}

Subscriptions

Operations for managing location subscriptions

Subscribe to Location

Subscribes the authenticated EMR to a location. This adds the location to the EMR's subscribed locations list. This endpoint is required to receive webhook events for the location.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
location_id
required
string

The ID of the location to subscribe to

Responses

Request samples

Content type
application/json
{
  • "location_id": "loc_12345"
}

Response samples

Content type
application/json
Example
{
  • "success": true,
  • "message": "Successfully subscribed to location"
}

Webhooks

Register Webhook URL

Registers or updates the webhook URL for the authenticated EMR.

Note: To receive webhook events, a location must be subscribed to the EMR using the Location subscription endpoint (POST /subscriptions).

When a GFE is completed, Spakinect will send a POST request to the registered URL with the payload described in VisitCompletedWebhook.

  • Event: visit.completed
  • Headers: Content-Type: application/json, User-Agent: Spakinect-Webhook/1.0, and if configured X-Webhook-Secret: <secret>.
  • Schema: #/components/schemas/VisitCompletedWebhook
Authorizations:
ApiKeyAuth
Request Body schema: application/json
required
url
required
string <uri>

The webhook URL where events will be posted

Responses

Request samples

Content type
application/json

Response samples

Content type
application/json
{
  • "success": true,
  • "message": "Webhook URL updated successfully"
}