Skip to main content

REST API

The HTTP connector sends queries to POST /api/. Use the HTTPS endpoint of your deployment. The connector handles authentication, protocol headers and multipart framing. Supply credentials through your deployment’s secret configuration.

import os
from aperturedb.ConnectorRest import ConnectorRest

client = ConnectorRest(host=os.environ["ADB_HOST"], port=443,
user=os.environ["ADB_USER"], password=os.environ["ADB_PASSWORD"])
response, blobs = client.query([{"GetSchema": {}}])
print(response[0]["GetSchema"])

The request body contains a JSON command array in the query form part and ordered binary inputs in blobs parts. The response uses multipart/mixed with JSON first and one raw binary part per output blob. Use query_stream() to consume large blobs incrementally. Query protocol