mediQuo

mediQuo

›API Reference

Overview

  • Getting Started

API Reference

  • Overview
  • Activation Codes
  • Patients
  • Prescriptions
  • Professionals
  • Messages
  • Troubleshooting

Android SDK

  • Installation
  • Professional List
  • Medical history
  • Customization
  • Other funcionalities
  • Changelog

iOS SDK

  • Installation
  • Professional List
  • Medical history
  • Customization
  • Other funcionalities
  • Changelog

Widget

  • Introduction
  • Permament session

    • Integration
    • Authentication

    Temporal session

    • Integration
  • Methods
  • Customization
  • Events

Activation Codes

Contains the information about Activation Codes in the mediQuo ecosystem.

Authentication and rate limits

AuthenticationRate limits
HTTP Headers600 requests per minute

Learn more about rate limits.

Attributes

NameTypeDescription
codestringThe activation code
plan_namestring (optional)The plan name of your activation code
tagstring (optional)The value that identifies your activation code in your system
activebooleanIf the activation code is active or not
durationstring (optional)The type of duration. forever it last forever (default value). limited last the number of months set in the duration_in_months parameter.
duration_in_monthsint (optional)The number of months that the subscription will last (with duration = limited)
expires_atstring (optional)The date when the activation code will be unavailable (Y-m-d)
max_redemptionsint (optional)The number of times an activation code can be used (1 time by default)

Create Activation Code

POST /v1/activation-codes

Endpoint URL

https://sdk.mediquo.com/v1/activation-codes

Request parameters

NameTypeDescription
codestringThe code that the user will introduce
plan_namestring (optional)The plan name of your activation code
tagstring (optional)The value that identifies your activation code in your system
durationstring (optional)The type of duration. forever it last forever (default value). limited last the number of months set in the duration_in_months parameter.
duration_in_monthsint (optional)The number of months that the subscription will last (with duration = limited)
expires_atstring (optional)The date when the activation code will be unavailable (Y-m-d)
max_redemptionsint (optional)The number of times an activation code can be used (1 time by default)

Example request

{
  "code": "MYTESTCODE123",
  "tag": "2020123ABC",
  "duration": "limited",
  "duration_in_months": 3
}

Response fields

NameTypeDescription
messagestringResponse message

Default response

Status: 200 OK
{
  "message": "Success"
}

Get Activation Codes

GET /v1/activation-codes

Use this endpoint to retrieve activation codes. Can be filtered with query params for the given tag.

Endpoint URL

https://sdk.mediquo.com/v1/activation-codes

Query parameters

NameTypeDescription
codestringThe activation code
tagstringThe value that identifies your activation code in your system
pageintegerPagination page

Response fields

NameTypeDescription
codestringThe activation code
plan_namestringThe activation code plan name
tagstringThe value that identifies your activation code in your system
activebooleanIf the activation code is active or not
created_atstringThe creation date of the activation code

Default response

Status: 200 OK
{
  "code": "MYTESTCODE123",
  "tag": "2020123ABC",
  "active": true
}

Activate Activation Code

PUT /v1/activation-codes/<code>/activate

Use this endpoint to reactivate an activation code

Endpoint URL

https://sdk.mediquo.com/v1/activation-codes/<code>/activate

Request parameters

NameTypeDescription
codestringActivation code

Response fields

NameTypeDescription
messagestringResponse message

Default response

Status: 200 OK
{
  "message": "Success"
}

Deactivate Activation Code

PUT /v1/activation-codes/<code>/deactivate

Use this endpoint to deactivate an activation code.

Endpoint URL

https://sdk.mediquo.com/v1/activation-codes/<code>/deactivate

Request parameters

NameTypeDescription
codestringActivation code

Response fields

NameTypeDescription
messagestringResponse message

Default response

Status: 200 OK
{
  "message": "Success"
}

Send Activation Code

PUT /v1/activation-codes/<code>/send

Use this endpoint to send a notification to the user with the generated activation code. This will send an email and/or an SMS depending of the information you provided in the request.

This endpoint by default is disabled. To be able to use it, you should request access to your mediQuo account manager

The endpoint will succeed if any of the provided channels for communication delivers the message, it will fail with error messages if both channels are unavailable and the message could not be sent.

Endpoint URL

https://sdk.mediquo.com/v1/activation-codes/<code>/send

Request parameters

NameTypeDescription
namestringPatient name
prefixstring (required if phone is set)Patient prefix (+34)
phonestring (required if prefix is set)Patient phone
emailstring (optional)Patient email
languagestring (optional)Language of message (only for email). Accepted languages 'es', 'en', 'pt , 'de'. Default: 'es'

Response fields

NameTypeDescription
messagestringResponse message

Default response

Status: 200 OK
{
  "data": {
    "sms": "delivered",
    "email": "delivered",
  }
}
← OverviewPatients →
  • Create Activation Code
    • Endpoint URL
    • Request parameters
    • Response fields
    • Default response
  • Get Activation Codes
    • Endpoint URL
    • Query parameters
    • Response fields
    • Default response
  • Activate Activation Code
    • Endpoint URL
    • Request parameters
    • Response fields
    • Default response
  • Deactivate Activation Code
    • Endpoint URL
    • Request parameters
    • Response fields
    • Default response
  • Send Activation Code
    • Endpoint URL
    • Request parameters
    • Response fields
    • Default response
MediQuo PRO Logo
Copyright © 2023 mediQuo