Skip to main content

PromTime API (1.0.0)

Download OpenAPI specification:Download

This is the Specification for the PromTime external API which allow partner to call some PromTime endpoints

Environment

Staging: https://api.promtime.dev

Production:https://api.promtime.org

OpenAPI Specification

This API is documented in OpenAPI format

Authentication

PromTime provide an authentication with API Key. Request a key from [tech@promtime.org].

apiKeyId

Security Scheme Type: API Key
Header parameter name: X-API-KEY-ID

apiKeySecret

Security Scheme Type: API Key
Header parameter name: X-API-KEY-SECRET

Patients

Endpoints used for Patients informations

Create or update patient

Create or update a patient in promtime

Authorizations:
(apiKeyIdapiKeySecret)
path Parameters
moduleId
required
string <uuid>

PromTime module ID given to you on configuration

emrId
required
string

emrId of a patient for the facility linked to the API Key

Request Body schema: application/json
required
Any of
firstname
required
string
lastname
required
string
email
required
string <email>
tel
string
fixedTel
string
contactMode
string
Enum: "EMAIL" "TEL"
practitionerIds
Array of strings <uuid> [ items <uuid > ]
mainPractitionerId
string <uuid>
language
string
Enum: "en" "fr"

Responses

Request samples

Content type
application/json
Example
{
  • "firstname": "string",
  • "lastname": "string",
  • "email": "user@example.com",
  • "tel": "string",
  • "fixedTel": "string",
  • "contactMode": "EMAIL",
  • "practitionerIds": [
    ],
  • "mainPractitionerId": "6d7d7cd1-5b36-4499-a050-e21b1e9bef4f",
  • "language": "en"
}

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "yearOfBirth": "string",
  • "sex": 1,
  • "isExonerated": true,
  • "isExcluded": true,
  • "exclusionReason": "CANNOT_PARTICIPATE",
  • "exclusionComment": "string",
  • "exclusionDate": "2019-08-24T14:15:22Z",
  • "hasConsented": true,
  • "createdAt": "2019-08-24T14:15:22Z",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "notifiedAt": "2019-08-24T14:15:22Z",
  • "createdWithApiKeyId": "f004f62f-9d20-4d46-977d-caf285226fa3",
  • "createdByUserId": "4d2aef9a-17b0-44e6-902e-616812033620",
  • "createdFrom": "API",
  • "metadata": { },
  • "userId": "2c4a230c-5085-4924-a3e1-25fb4fc5965b",
  • "hospitalId": "3d2ecc11-3f47-468d-aa4f-f66dc740e722"
}

Update patient EmrId

create a new patient EmrId for a given current EmrId

Authorizations:
(apiKeyIdapiKeySecret)
path Parameters
moduleId
required
string <uuid>

PromTime module ID given to you on configuration

oldEmrId
required
string

current valid emrId of a patient for the facility linked to the API Key

Responses

Response samples

Content type
application/json
{
  • "patientId": "460a6d87-689c-4661-a526-a52450bbe2d7",
  • "hospitalId": "3d2ecc11-3f47-468d-aa4f-f66dc740e722",
  • "emrId": "string",
  • "createdAt": "2019-08-24T14:15:22Z"
}

Croms

Endpoints used for Croms informations

CromPromCat

YOB
integer [ 1880 .. 2015 ]

Patient year of birth between 1880 and 2015

SEX
integer
Enum: 1 2 3 999

Gender must be one of [1, 2, 3, 999] with 1 = male | 2 = female | 3 = other and 999 = Undisclosed

VISACUUNI_PRE
integer
Enum: 1 2 3

Visual acuity unit must be one of [1, 2, 3] with 1 = Snellen | 2 = Decimal | 3 = LogMAR

VISACUUNI_POST
integer
Enum: 1 2 3

Visual acuity unit must be one of [1, 2, 3] with 1 = Snellen | 2 = Decimal | 3 = LogMAR

PRACTITIONER_PRE
string <uuid>

Preoperative consultation practictioner UUID provided by PromTime

PRACTITIONER_POST
string <uuid>

Postoperative consultation practictioner UUID provided by PromTime

EYE_OP
integer
Enum: 1 2 3

The operated eye must be one of [1, 2, 3] with 1 = right eye | 2 = left eye | 3 = both eye

SURGEXP
integer
Enum: 1 2

The surgeon's experience must be one of [1, 2] with 1 = independent surgeon | 2 = intern

object
object
{
  • "YOB": 1880,
  • "SEX": 1,
  • "VISACUUNI_PRE": 1,
  • "VISACUUNI_POST": 1,
  • "PRACTITIONER_PRE": "15c2aeea-0ca4-4f9f-a037-139231bc8778",
  • "PRACTITIONER_POST": "e9207893-feb2-49c4-abb4-358a05792c38",
  • "EYE_OP": 1,
  • "SURGEXP": 1,
  • "LEFT_EYE": {
    },
  • "RIGHT_EYE": {
    }
}

Crom

id
string <uuid>
createdAt
string <date-time>
updatedAt
string <date-time>
object (CromPromCat)
originalData
object
episode
number
moduleId
string <uuid>
resultId
string <uuid>
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "data": {
    },
  • "originalData": { },
  • "episode": 0,
  • "moduleId": "eb49de5a-d93f-4a73-a032-bfeee6879098",
  • "resultId": "bfb2617a-91d0-4d69-bd0f-b3c7d35c900b"
}

Edit a patient croms

Edit a patient croms for a given emrId and module

Authorizations:
(apiKeyIdapiKeySecret)
path Parameters
moduleId
required
string <uuid>

PromTime module ID given to you on configuration

emrId
required
string

emrId of a patient for the facility linked to the API Key

Request Body schema: application/json
required
YOB
integer [ 1880 .. 2015 ]

Patient year of birth between 1880 and 2015

SEX
integer
Enum: 1 2 3 999

Gender must be one of [1, 2, 3, 999] with 1 = male | 2 = female | 3 = other and 999 = Undisclosed

VISACUUNI_PRE
integer
Enum: 1 2 3

Visual acuity unit must be one of [1, 2, 3] with 1 = Snellen | 2 = Decimal | 3 = LogMAR

VISACUUNI_POST
integer
Enum: 1 2 3

Visual acuity unit must be one of [1, 2, 3] with 1 = Snellen | 2 = Decimal | 3 = LogMAR

PRACTITIONER_PRE
string <uuid>

Preoperative consultation practictioner UUID provided by PromTime

PRACTITIONER_POST
string <uuid>

Postoperative consultation practictioner UUID provided by PromTime

EYE_OP
integer
Enum: 1 2 3

The operated eye must be one of [1, 2, 3] with 1 = right eye | 2 = left eye | 3 = both eye

SURGEXP
integer
Enum: 1 2

The surgeon's experience must be one of [1, 2] with 1 = independent surgeon | 2 = intern

object
object

Responses

Request samples

Content type
application/json
{
  • "YOB": 1880,
  • "SEX": 1,
  • "VISACUUNI_PRE": 1,
  • "VISACUUNI_POST": 1,
  • "PRACTITIONER_PRE": "15c2aeea-0ca4-4f9f-a037-139231bc8778",
  • "PRACTITIONER_POST": "e9207893-feb2-49c4-abb4-358a05792c38",
  • "EYE_OP": 1,
  • "SURGEXP": 1,
  • "LEFT_EYE": {
    },
  • "RIGHT_EYE": {
    }
}

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "data": {
    },
  • "originalData": { },
  • "episode": 0,
  • "moduleId": "eb49de5a-d93f-4a73-a032-bfeee6879098",
  • "resultId": "bfb2617a-91d0-4d69-bd0f-b3c7d35c900b"
}