MENU navbar-image

Introduction

Authenticating requests

To authenticate requests, include an Authorization header with the value "Bearer {YOUR_AUTH_KEY}".

All authenticated endpoints are marked with a requires authentication badge in the documentation below.

You can retrieve your token by visiting your dashboard and clicking Generate API token.

Endpoints

获取认证详情

requires authentication

This endpoint allows users to fetch inquiry data from the Persona API by passing the inquiry ID as a URL parameter. It sends a GET request to the Persona API and returns the corresponding inquiry data.

Example request:
curl --request GET \
    --get "https://kyc.rockflow.ai/fetch-inquiry/inq_123456789" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://kyc.rockflow.ai/fetch-inquiry/inq_123456789"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):


{
 "success": true,
 "data": {
    // The actual response data from Persona API
 }
}
 

Example response (500):


{
    "error": "Unable to fetch data from Persona API",
    "message": "Request exception message"
}
 

Request      

GET fetch-inquiry/{inq_id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

inq_id   string   

The ID of the inquiry you want to fetch. Example: inq_123456789

下载认证报告

requires authentication

This endpoint allows authenticated users to download the inquiry report PDF for a given inquiry ID.

Example request:
curl --request GET \
    --get "https://kyc.rockflow.ai/report/inq_Ehc2VLuRXqLirNK8Y1eiQyWxe" \
    --header "Authorization: Bearer {YOUR_AUTH_KEY}" \
    --header "Content-Type: application/json" \
    --header "Accept: application/json"
const url = new URL(
    "https://kyc.rockflow.ai/report/inq_Ehc2VLuRXqLirNK8Y1eiQyWxe"
);

const headers = {
    "Authorization": "Bearer {YOUR_AUTH_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
};

fetch(url, {
    method: "GET",
    headers,
}).then(response => response.json());

Example response (200):


file The PDF file containing the inquiry report.
 

Example response (400):


{
    "error": "Invalid inquiry ID"
}
 

Example response (401):


{
  "error": "Unauthenticated."
 

Example response (500):


{
    "error": "Unable to download report"
}
 

Request      

GET report/{inquiry_id}

Headers

Authorization      

Example: Bearer {YOUR_AUTH_KEY}

Content-Type      

Example: application/json

Accept      

Example: application/json

URL Parameters

inquiry_id   string   

The ID of the inquiry. Example: inq_Ehc2VLuRXqLirNK8Y1eiQyWxe