Invoke a Skill or Query (Simple)
GET /agent
**Invoke a Skill or Query (Simple): **
Parametersโ
| name | in | type | required | description |
|---|---|---|---|---|
| asset | query | string | false | The Target Asset of the Query (targets the complete dataspace if empty) |
| runMode | query | string | false | Determines the preferred execution location which may be "consumer" (in the computing environment of the endpoint agent), "provider" (in the computing environment of the remote agent providing the targetted asset) or "all" (the agent will choose the best computing environment based on contracts and policies, this is the default mode). |
| queryLn | query | string | false | Determines the query language. Currently only "SPARQL" is supported. |
| query | query | string | false | The SPARQL query |
| (vin | query | string | false | A sample bound parameter 'vin' which opens a new input tuple |
| troubleCode | query | array | false | A sample multi-bound parameter 'troubleCode' which closes the tuple |
Code Snippetsโ
Shell + Curl
curl --request GET \
--url 'https://knowledge.dev.demo.catena-x.net/consumer-edc-data/BPNL00000003CQI9/api/agent?asset=SOME_STRING_VALUE&runMode=SOME_STRING_VALUE&queryLn=SOME_STRING_VALUE&query=SOME_STRING_VALUE&(vin=SOME_STRING_VALUE&troubleCode=SOME_ARRAY_VALUE'
Responsesโ
200โ
The SparQL query has been processed successfully.
| Headers | |
|---|---|
| content-type | application/sparql-results+json |
Example response for application/sparql-results+json
{}
| Headers | |
|---|---|
| content-type | application/sparql-results+xml |
Example response for application/sparql-results+xml
<?xml version="1.0" encoding="utf-8"?>
<sparql>
<head>
<variable>
<name>string</name>
</variable>
</head>
<results>
<result>
<binding>
<name>string</name>
<literal>string</literal>
<uri>string</uri>
</binding>
</result>
</results>
</sparql>
| Headers | |
|---|---|
| content-type | text/csv |
Example response for text/csv
"\"subject\",\"predicate\",\"object\"\n\"foo\",\"meets\",\"bar\"\n\"one\",\"meets\",\"two\""
| Headers | |
|---|---|
| content-type | text/tab-separated-values |
Example response for text/tab-separated-values
"?subject ?predicate ?object"
| Headers | |
|---|---|
| content-type | application/x-binary-rdf-results-table |
Example response for application/x-binary-rdf-results-table
"string"
203โ
The SparQL query has been processed successfully but warnings did occur.
| Headers | |
|---|---|
| content-type | application/sparql-results+json |
Example response for application/sparql-results+json
{}
| Headers | |
|---|---|
| content-type | application/sparql-results+xml |
Example response for application/sparql-results+xml
<?xml version="1.0" encoding="utf-8"?>
<sparql>
<head>
<variable>
<name>string</name>
</variable>
</head>
<results>
<result>
<binding>
<name>string</name>
<literal>string</literal>
<uri>string</uri>
</binding>
</result>
</results>
</sparql>
| Headers | |
|---|---|
| content-type | text/csv |
Example response for text/csv
"\"subject\",\"predicate\",\"object\"\n\"foo\",\"meets\",\"bar\"\n\"one\",\"meets\",\"two\""
| Headers | |
|---|---|
| content-type | text/tab-separated-values |
Example response for text/tab-separated-values
"?subject ?predicate ?object"
| Headers | |
|---|---|
| content-type | application/x-binary-rdf-results-table |
Example response for application/x-binary-rdf-results-table
"string"
400โ
Bad request or malformed SPARQL
500โ
Fatal error
(C) 2021 Contributors to the Eclipse Foundation. SPDX-License-Identifier: CC-BY-4.0