Authors: Jubin Jose
Some API requests are marked to be cryptographically signed before making into Aquila Hub. Below are the generic steps for making API requests.
- Prepare a JSON message as it is specified under each API below.
- If required, sign the JSON message as specified in asymmetric key signing section.
- Wrap JSON message and signature in the following request format:
data = {
"data": <JSON message>,
"signature": signature
}
- Make API request with header
headers["Content-Type"] = "application/json"
.
1. Get Aquila Hub node status:
[GET] /
request:
{}
response:
{
"success": <Boolean>,
"message": <String>
}
1. Prepare a model:
[POST] /prepare [Sign message]
request:
{
"databaseName": <String>,
"schema": <JSON schema definition>
}
response:
{
"success": <Boolean>,
"databaseName": <String>
}
2. Compress data:
[POST] /compress
request:
{
"databaseName": <String>,
"text": <String array>
}
response:
{
"success": <Boolean>,
"vectors": <2D Floating point array>
}