Getlabs OAuth API

Exchange a signed JWT for the access token used to authenticate every other request, and refresh it once it expires. See [Authentication](#section/Authentication) for how to sign the JWT.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 1

POST /v2/oauth/token This endpoint is required to get an access token to access the external api as… #

Specifications

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/getlabs:getlabs-oauth-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

getlabs-oauth-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Getlabs OAuth API
  description: 'By integrating the Getlabs API, you can bridge the gap between virtual and in-person healthcare, connecting physician-led telemedicine with in-person care from medical professionals. This enables healthcare providers to extend care to the home unlocking high-quality healthcare for more patients at a fraction of the cost.


    With a single API call, we enable our partners to provide end-to-end care for their patients and extend their capabilities to treat new conditions & modalities. What if you could treat primary care remotely? Now you can.


    Pick and choose the types of diagnostics you need. Your patients select a convenient time and place. The Getlabs API takes care of everything else.


    **Maintenance Mode**: In the event that the Getlabs API is under maintenance a 503 Service Unavailable will be returned with a matching maintenance mode header (maintenance-mode) set to true. Under normal operation the header defaults false.


    # Authentication


    Most of the API endpoints are secured via Bearer Tokens. You must pass your token with any endpoint request. To do so

    include the following header in your request replacing the token with one that you''ve obtained from the /oauth/token endpoint.


    `Authorization: Bearer c2FkZnNld3J0Z2Zlcndnd2Z3ZXNndGVydGZ3ZXJmZXd0Z2V3Z3dlNGdmM3dmM3c=`

    ## Obtaining a Bearer token


    In order to make API requests you will need to obtain an access token. Token requests must send a signed JWT.

    The JWT must be signed (using HS512 algorithm) with the provided getlabs API token/secret. See OAuth section below for more details.


    _NOTE: the JWT provided with the token request is valid for a period of 24hrs after first use. The JWT will need to be regenerated after that time. It is recommended to regenerate a signed JWT for each token request._


    ## WAF and newlines in JSON


    GCP Cloud Armor (WAF) can reject token requests when JSON string values contain literal newline characters.


    If you get an HTTP 403 response, your request was likely blocked by Cloud Armor (WAF).


    Use a single-line JSON payload (no line breaks in the payload), or use this curl heredoc pattern (`--data @-` with `"}

    EOF

    ```


    # Rate Limiting


    The API has rate limits in place to ensure fair usage and to protect our services from misuse.


    The default rate limit is 600 requests per 5 minute interval. If you exceed this limit, you will receive a `429 Too Many Requests`.


    All API responses include the following headers to help you monitor your rate limit status:


    - `X-RateLimit-Period`: the interval period of the rate limit we have configured.

    - `X-RateLimit-Remaining`: how many requests remaining before hitting the rate limit.

    - `X-RateLimit-Next`: milliseconds to when the rate limit will be lifted.


    Use these headers to monitor your usage and adjust your request rate accordingly.


    To avoid hitting the rate limit, it is recommended to implement exponential backoff and retry logic in your application.


    _NOTE: Endpoints in this api might have higher rate limits than the default documented. Please trust the RateLimit header set and NOT this documentation._'
  version: v2
  contact: {}
servers:
- url: https://api.getlabs.com
  description: Production
- url: https://api.getlabs-sandbox.com
  description: Sandbox
tags:
- name: OAuth
  description: Exchange a signed JWT for the access token used to authenticate every other request, and refresh it once it expires. See Authentication for how to sign the JWT.
paths:
  /v2/oauth/token:
    post:
      description: 'Obtaining an access token: In order to make api requests you will need to get an access token. Token requests must send a JWT as an assertion parameter in the http request payload. The JWT must be signed (using HS512 algorithm) with the provided getlabs api token/secret.


        The token payload must contain:


        {

        aud: string; // getlabs oauth/token endpoint https://api.getlabs.com/v2/oauth/token

        sub: string; // your getlabs provided client id

        exp: number; // unix timestamp when this jwt bearer token expires

        iat: number; // unix timestamp when this jwt bearer token was issued at

        }


        More details can be found here: Using JWTs as Authorization Grants


        Refreshing an access token: Expired access_token(s) can also be refreshed by using this endpoint, resulting in a fresh access_token and refresh_token.


        An Authorization header with your expired access_token is required when refreshing a token. As well as the refresh_token and grant type in the http request payload.


        More details on the oauth refresh flow can be found here: Refreshing an access token'
      operationId: Oauth_Token
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              oneOf:
              - $ref: '#/components/schemas/OauthTokenDto'
              - $ref: '#/components/schemas/OauthTokenDto'
            examples:
              jwtGrant:
                summary: JWT-bearer grant
                value:
                  grant_type: urn:ietf:params:oauth:grant-type:jwt-bearer
                  assertion: eyJ...
              refreshGrant:
                summary: Refresh token grant
                value:
                  grant_type: refresh_token
                  refresh_token: ZYZY...
      responses:
        '201':
          description: Access and refresh token details.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OauthTokenDto'
      summary: This endpoint is required to get an access token to access the external api as…
      tags:
      - OAuth
components:
  schemas:
    OauthTokenDto:
      type: object
      properties:
        access_token:
          type: string
          description: Access token required for all api calls
          example: eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjE5Nzk2MjEwLTBmZDUtNDFhZi1iOGUzLWM1ODViYzFjN2ExMSIsInR5cGUiOiJQYXJ0bmVyRW50aXR5IiwiaWF0IjoxNjU4NDMzMjU3LCJleHAiOjE2NTg0MzM4NTd9.XQsq-opjVKVmVhvXzU_mGeCqOi3m96ZoHGnLQ90UnFXKQDTTMeTm7lOv9Qd8nNmDab9Ex7VmIKt3Ne8NDvIVWQ
        refresh_token:
          type: string
          description: Refresh token to be used to refresh your expired access_token
          example: 323abcbc59fd263986d4a2afd0f24385457dd5b6
        token_type:
          type: string
          description: Token type. At this point it will always be Bearer
          example: Bearer
        expires:
          type: number
          description: Expire timestamp of your access token
          example: '1658433841'
      required:
      - access_token
      - refresh_token
      - token_type
      - expires
  securitySchemes:
    jwt-bearer-flow:
      scheme: bearer
      bearerFormat: JWT
      description: Used on /oauth/token endpoint to request an access_token
      type: http
    bearer:
      scheme: bearer
      bearerFormat: JWT
      description: Once an access token is returned provide the access_token to this Authorization header.
      type: http