API Reference

Introduction

This guide will help you get started with the Crux Dataset Health API by Dataset ID. This API allows you to retrieve information about the dataset health of a specific dataset ID, including details about the latest delivery and historical records.

In this quick start guide, you’ll learn:

  • How to call Crux Dataset Health delivery records for a given Dataset ID

Prerequisites

Before you begin, ensure you have the following:

  1. API Key: You need an API key to authenticate your requests. Log into the Crux App, and go to ⚙ Settings > API Keys menu to copy your API key. Note: you may regenerate a new API key, if needed, on the same page.
  2. Dataset ID: You need a datasetId as part of the API endpoint path. You may pick one from the dataset health list API response.
  3. Base URL: The base URL for the API https://api.cruxinformatics.com/v2/ops/health/datasets/{datasetId}/deliveries

Step 1: Authenticate Your Requests

To authenticate your requests, you need to include your API key in the request headers.

Request: GET /v2/ops/health/datasets/deliveries
Host: api.cruxinformatics.com
Authorization: Bearer YOUR_API_KEY

Step 2: Make a Request

Use the following endpoint to retrieve the dataset health list.

Endpoint

GET https://api.cruxinformatics.com/v2/ops/health/datasets/{datasetId}/deliveries

Path Parameters

You need to input a datasetId of interest as part of the API endpoint path. The API response attributes will be based on the datasetId that you provide. You may pick a datasetId from the dataset health list API response.

Query Parameters

You can use the following query parameters to paginate the results.

  • latestDeliveriesCount: Optionally, you may input a number that provides the number of deliveries to provide in the response for the dataset. The default number will be 10.

Example Request

Below is an example of a request to retrieve the dataset health list with filters and pagination.

GET
/v2/ops/health/datasets/{datasetId}/deliveries?latestDeliveriesCount=2'
Host: api.cruxinformatics.com
Authorization: Bearer YOUR_API_KEY

Step 3: Handle the Response

The response contains the dataset health information, including the legacy dataset ID, dataset name, delivery events, and delivery ID and statuses for delivery records.

Example Response

{
  "legacyDatasetId": "string",
  "datasetId": "string",
  "datasetName": "string",
  "cduId": "string",
  "cduName": "string",
  "dataProductId": "string",
  "dataProductName": "string",
  "ownerOrgId": "string",
  "supplier": {
    "id": "string",
    "name": "string"
  },
  "currentProcessingDeadlineConfig": {
    "minute": "30",
    "hour": "1",
    "dayOfTheMonth": "*",
    "month": "*",
    "dayOfWeek": "*",
    "year": "*",
    "timezone": "",
    "cronExpression": "30 1 * * *"
  },
  "deliveryId": "string",
  "deliveryEventList": [
    {
      "status": "string",
      "deliveryDeadline": "datetime",
      "deliveredAt": "datetime",
      "processingDeadlineConfig": {
        "minute": "30",
        "hour": "1",
        "dayOfTheMonth": "*",
        "month": "*",
        "dayOfWeek": "*",
        "year": "*",
        "timezone": "",
        "cronExpression": "30 1 * * *"
      },
      "deliveryId": "string"
    },
    {
      "status": "string",
      "deliveryDeadline": "datetime",
      "deliveredAt": "datetime",
      "processingDeadlineConfig": {
        "minute": "30",
        "hour": "1",
        "dayOfTheMonth": "*",
        "month": "*",
        "dayOfWeek": "*",
        "year": "*",
        "timezone": "",
        "cronExpression": "30 1 * * *"
      },
      "deliveryId": "string"
    }
  ],
  "latestDeliveryStatus": "string",
  "latestDeliveryTimestamp": "datetime",
  "nextExpectedDeliveryTimestamp": "datetime"
}

Conclusion


You are now ready to use the Crux Dataset Health API to retrieve and manage dataset health information by Dataset ID. If you have any questions or need further assistance, please refer to the official API documentation or contact Crux Support.

Happy coding!


Language
Authorization
Bearer
Click Try It! to start a request and see the response here!