Introduction

We offer a HTTP based API to generate codes for our video call system. The service to generate video appointment codes can be requested with REST and JSON.

You are reading the documentation of the API Version v2.1.

The active version of our api is a RESTful service interface, available via following url:

https://video.redmedical.de/api/codes

API v2.1

Please be aware that access codes to video appointments are not reusable anymore. You will have to create access codes for every single participant. Also please remove unused participant codes to enhance your clients data privacy.

Authorization

Every request needs an Authorization-Header with your API token to authenticate yourself to the service.

In general you have to pass at least the following HTTP-Headers:

Field

Value

Description

Authorization

<your token>

supply your api token with <your token>

Content-Type

application/json


Response Codes

HTTP Status Code: 201: The action was successful and the entities have successfully been persisted.

HTTP Status Code: 200: The action was successful. The response body contains the result.

HTTP Status Code: 401: If you get the HTTP status code 401, the given token is invalid. Please check your token and request header definitions.

HTTP Status Code: 400: Your request failed due to some validation error. Please have a look at the response for further details.

Create a new session

You may create a session with one organizer and zero or more participants. In the result you will get on hostCode and zero or more clientCodes, depending on the patientAmount query parameter you passed.

Request

Request Method: HTTP POST

Path: /api/codes

Body parameter

Field

Type

Description

validTo

string, required

format: "YYYY-MM-DD" or long version as ISO string "YYYY-MM-DDTHH:mm:ss.SSSZ"

date until entry code is valid

tenantId

number, optional

additional information about specific tenant, usually not necessary

patientAmount

number, optional

Amount of participants, default: 1

Example body:

{

“validTo”: “2022-01-31”,

“patientAmount”: 1

}

Response

Success:

HTTP Status Code: 201

Field

Type

Description

hostCode

string

the code for the video appointment host - former “codeArzt”

clientCodes

Array<string>

the codes for the video appointment participants

created

date

timestamp of creation

Example:

HTTP/1.1 201 OK

{

“hostCode”: “21h-hEY-DMe”,

“clientCodes”: [“J2M-KRv-Dkb”],

“created”: “2020-08-27T05:38:11.564Z”

}



The video appointment can be accessed by all participants via the following URL:

https://video.redmedical.de/#/login?name=[name]&code=[code] 

In protection of privacy do not use any patient clear text names. Please be aware that you should only share the client codes with the respective participant. If multiple participants try to login with the same access code, at least one of them will get blocked.

Errors

HTTP Status Code: 401
If you get the HTTP status code 401, the given token is invalid. Please check your token and request header definitions.

Add a participant to a session

If some clients need to add more participants to the session after creating a session, you may want to update the session. This is possible by updating the session over the hostCode.

Request

Request Method: HTTP POST

Path: /api/codes/{hostCode}

Body parameter

Field

Type

Description

validTo

string, optional

format: "YYYY-MM-DD" or long version as ISO string "YYYY-MM-DDTHH:mm:ss.SSSZ"

date until entry code is valid

tenantId

number, optional

additional information about specific tenant, usually not necessary

patientAmount

number, optional

Amount of participants, default: 1

Example body:

{

“validTo”: “2022-01-31”,

“patientAmount”: 1

}

Response

Success:

HTTP Status Code: 201

Field

Type

Description

clientCodes

Array<string>

the codes for the video appointment participants

created

date

timestamp of creation

Example:

HTTP/1.1 201 OK

{

“clientCodes”: [“J2M-KRv-Dkb”],

“created”: “2020-08-27T05:38:11.564Z”

}

Errors

HTTP Status Code: 401
If you get the HTTP status code 401, the given token is invalid. Please check your token and request header definitions.

HTTP Status Code: 404
If you get the HTTP status code 404, one of the codes you provided is not available.

Remove a participant from a session

If some clients need to add more participants to the session after creating a session, you may want to update the session. This is possible by updating the session over the hostCode.

Request

Request Method: HTTP POST

Path: /api/codes/removeParticipants/{accessCode}

Body parameter

Field

Type

Description

tenantId

number, optional

additional information about specific tenant, usually not necessary

participants

string array

Array of accesscodes of participants to remove

Response

Success:

HTTP Status Code: 200

Example:

HTTP/1.1 200 OK

The video appointment can be accessed by all participants via the following URL:

https://video.redmedical.de/#/login?name=[name]&code=[code] 

In protection of privacy do not use any patient clear text names. Please be aware that you should only share the client codes with the respective participant. If multiple participants try to login with the same access code, at least one of them will get blocked.

Errors

HTTP Status Code: 401
If you get the HTTP status code 401, the given token is invalid. Please check your token and request header definitions.

HTTP Status Code: 404
If you get the HTTP status code 404, one of the codes you provided is not available.

  • No labels