POST
/
data
/
{username}
/
{namespace}
/
{datasetName}
HttpResponse<String> response = Unirest.post("https://api.datalinks.com/api/v1/data/{username}/{namespace}/{datasetName}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "text/plain")
.body("OntologyObject(\"movies\").filter(name==\"Braveheart\").searchAround().find(\"actors\").filter(name==\"Mel Gibson\")")
.asString();
[
  {}
]

For data querying, you can send expressive queries to the backend, enabling you to filter, perform searches, aggregations and more! Analyzing the code line-by-line:

Request body specifies the query you want to execute. Our query language continues to evolve. In the meantime, you can check all commands available to you in the Query Language Command List.

Some examples can be found below:

Getting all data:

OntologyObject("datasetName").get()

Filtering a column:

OntologyObject("datasetName").filter("columnName==Foo").get()

Filter with Logic expressions:

OntologyObject("datasetName").filter("columnName==Foo && column2 > 2").get()

Following links:

OntologyObject("datasetName").searchAround().find("otherObject").get()

Authorizations

Authorization
string
header
required

Use a Bearer token for authentication. Submit the token using the Authorization header: Authorization: Bearer <token>. The token can be generated in Settings

Path Parameters

namespace
string
required

The namespace is the name you want to group your datasets around.

datasetName
string
required

Name of the dataset. The same name may exist in different namespaces, for example companies exists in both sanctions and in the company registry.

owner
string
required

username of the owner of a namespace

Body

text/plain · string

for details check Querying data

Example:

"OntologyObject(\"datasetName\").get()"

Response

200
application/json

Successful response with the ontology data object.

The response is of type object[].