InstaCLEAR API (2.0.7)

Download OpenAPI specification:

API for managing orders, organizations, and products in the InstaCLEAR system.

Authentication

InstaCLEAR API offers API Key authentication. To authenticate requests, include your API key in the X-API-KEY header.

ApiKeyAuth

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

Webhook post operations

Receive order updates via webhook Webhook

Endpoint to receive updates regarding order status.

Authorizations:
ApiKeyAuth
Request Body schema: application/json

Details of the order update.

id
string <uuid>
type
string
Enum: "ORDER_PLACED" "ORDER_SHIPPED" "ORDER_DELIVERED" "TEST_SCHEDULED" "LAB_REVIEW" "TEST_COMPLETE" "PROCESS_FAILURE" "NOTE"
description
string
createdAt
string <date-time>
order_id
string <uuid>
organization_id
string <uuid>
webhook_type
string
Value: "ORDER_HISTORY"

Responses

Request samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "type": "ORDER_PLACED",
  • "description": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "order_id": "93101167-9065-4b9c-b98b-5d789a3ed9fe",
  • "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6",
  • "webhook_type": "ORDER_HISTORY"
}

Receive order completion notification via webhook Webhook

Endpoint to receive notifications when an order is complete.

Authorizations:
ApiKeyAuth
Request Body schema: application/json

Details of the order completion.

order_id
string <uuid>

Unique identifier for the order.

organization_id
string <uuid>

Unique identifier for the order organization.

test_result
string
Value Description
allOf

[object Object]

The result of the test.

test_result_timestamp
string <date-time>

The date and time the test result was received.

webhook_type
string
Value: "TEST_COMPLETE"

Responses

Request samples

Content type
application/json
{
  • "order_id": "93101167-9065-4b9c-b98b-5d789a3ed9fe",
  • "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6",
  • "test_result": "string",
  • "test_result_timestamp": "2019-08-24T14:15:22Z",
  • "webhook_type": "TEST_COMPLETE"
}

Order

Place a new order

Create a new order with the given details.

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required

Order and product identification details.

object (Order)

Representation of an order within the InstaCLEAR system.

product_id
string <uuid>
organization_id
string <uuid>

Responses

Request samples

Content type
application/json
{
  • "order": {
    },
  • "product_id": "0d012afa-f885-4e65-aeca-37e27701e2d1",
  • "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6"
}

Response samples

Content type
application/json
{
  • "order_id": "93101167-9065-4b9c-b98b-5d789a3ed9fe"
}

Fetch orders

Retrieve a list of all orders.

Authorizations:
ApiKeyAuth

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Fetch order by ID

Retrieve details of an order by its ID.

Authorizations:
ApiKeyAuth
path Parameters
id
required
string <uuid>

Unique identifier for the order.

Responses

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "order_type": "SHIPPED",
  • "donor": {
    },
  • "ship_street1": "string",
  • "ship_street2": "string",
  • "ship_city": "string",
  • "ship_state": "string",
  • "ship_zip": "string",
  • "ship_country": "string",
  • "ship_tracking_number": "string",
  • "ship_carrier": "string",
  • "specimen_number": "string",
  • "product": {
    },
  • "product_serial_number": "string",
  • "test_scheduled": "2019-08-24T14:15:22Z",
  • "milestone": "ORDERED",
  • "milestoneDateTime": "2019-08-24T14:15:22Z",
  • "test_result": "string",
  • "test_reason": "BLIND_SAMPLE",
  • "notes": "string",
  • "placed_by": "user@example.com",
  • "history": [
    ],
  • "files": [
    ],
  • "createdAt": "2019-08-24T14:15:22Z",
  • "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6"
}

Fetch orders by organization ID

Retrieve a list of order associated with a given organization ID.

Authorizations:
ApiKeyAuth
path Parameters
orgId
required
string <uuid>

Unique identifier for the organization.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Organization

List all organizations

Retrieve a list of all registered organizations.

Authorizations:
ApiKeyAuth

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Fetch products by organization ID

Retrieve a list of products associated with a given organization ID.

Authorizations:
ApiKeyAuth
path Parameters
orgId
required
string <uuid>

Unique identifier for the organization.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Fetch orders by organization ID

Retrieve a list of order associated with a given organization ID.

Authorizations:
ApiKeyAuth
path Parameters
orgId
required
string <uuid>

Unique identifier for the organization.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Product

Fetch products by organization ID

Retrieve a list of products associated with a given organization ID.

Authorizations:
ApiKeyAuth
path Parameters
orgId
required
string <uuid>

Unique identifier for the organization.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

File

Generate a signed URL for a file url

Generate a signed URL for a file url

Authorizations:
ApiKeyAuth
Request Body schema: application/json
required

File url

file_url
required
string <url>
expires_in
integer [ 1 .. 3600 ]
Default: 120

Expiration time in seconds

Responses

Request samples

Content type
application/json
{
  • "file_url": "string",
  • "expires_in": 120
}

Response samples

Content type
application/json
{
  • "signed_file_url": "string",
  • "expiration": "2019-08-24T14:15:22Z"
}