RedEye DMS API v3.0.0
Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.
The RedEye DMS API is a set of HTTP endpoints that help you integrate with RedEye DMS and allow you to work with data in your bucket, including artefacts and metadata keys.
Code samples are provided in this documentation to help you get started faster.
Base URLs:
-
-
port - Default: 8080
- 8080
-
-
-
port - Default: 443
- 443
-
Authentication
- HTTP Authentication, scheme: bearer
Artefacts
getArtefacts
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts \
--header 'Accept: application/json'
GET /api/v1/artefacts HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts
Returns the list of artefacts in the bucket
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| page | query | integer | false | Denotes the page number. Typically used in conjunction with ‘limit’ to perform pagination of results. |
| limit | query | integer | false | Limits the number of results returned in the search. |
Example responses
200 Response
{
"limit": 0,
"offset": 0,
"results": [
{
"id": 0,
"name": "string",
"number": "string",
"score": "string",
"type": "string"
}
],
"total": 0
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactListResponse | ArtefactListResponse |
| 400 | Bad Request | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
getDeletedArtefacts
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts/deleted \
--header 'Accept: application/json'
GET /api/v1/artefacts/deleted HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts/deleted");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/deleted")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts/deleted", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/deleted",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts/deleted")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/deleted"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts/deleted
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| page | query | integer | false | Page number to fetch |
| limit | query | integer | false | Limit to fetch |
| deletedAfter | query | string | false | Limit artefacts to deleted after value given |
| deletedBefore | query | string | false | Limit artefacts to deleted before value given |
Example responses
200 Response
{
"deletedArtefacts": [
"string"
],
"limit": 0,
"offset": 0,
"total": 0
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Deleted artefacts | DeletedArtefacts |
| 400 | Bad Request | Error response | ResponseError |
artefact
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts/0 \
--header 'Accept: application/json'
GET /api/v1/artefacts/0 HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts/0");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/0")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts/0", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/0",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts/0")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/0"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts/{Id}
Returns information for an artefact for the latest approved revision
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Id | path | integer | true | none |
Example responses
200 Response
{
"created": "string",
"groups": [
{
"id": 0,
"name": "string"
}
],
"id": 0,
"locations": {
"lat": "string",
"lon": "string"
},
"metadata": [
{
"id": 0,
"key_id": 0,
"key_name": "string",
"value": "string"
}
],
"modified": "string",
"number": "string",
"revisions": [
{
"comment": "string",
"id": 0,
"preview": "string",
"status": "string",
"thumbnail": "string",
"timestamp": "string",
"version": 0
}
],
"state": {
"is_destructible": true,
"is_modifiable": true,
"is_viewable": true,
"name": "string"
},
"title": "string",
"type": "string",
"workflow": {
"id": 0,
"name": "string",
"step": {
"id": 0,
"name": "string",
"type": {
"id": 0,
"name": "string"
}
}
},
"geometry": "Feature"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactResponse | Artefact |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
updateArtefact
Code samples
curl --request POST \
--url http://localhost/api/v1/artefacts/0 \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"title":"string","number":"string","metadata":[{"name":"string","value":["string"]}],"geometry":"Feature"}'
POST /api/v1/artefacts/0 HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: localhost
Content-Length: 107
{"title":"string","number":"string","metadata":[{"name":"string","value":["string"]}],"geometry":"Feature"}
const data = JSON.stringify({
"title": "string",
"number": "string",
"metadata": [
{
"name": "string",
"value": [
"string"
]
}
],
"geometry": "Feature"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v1/artefacts/0");
xhr.setRequestHeader("Content-Type", "application/json");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/0")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request["Accept"] = 'application/json'
request.body = "{\"title\":\"string\",\"number\":\"string\",\"metadata\":[{\"name\":\"string\",\"value\":[\"string\"]}],\"geometry\":\"Feature\"}"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "{\"title\":\"string\",\"number\":\"string\",\"metadata\":[{\"name\":\"string\",\"value\":[\"string\"]}],\"geometry\":\"Feature\"}"
headers = {
'Content-Type': "application/json",
'Accept': "application/json"
}
conn.request("POST", "/api/v1/artefacts/0", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/0",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\"title\":\"string\",\"number\":\"string\",\"metadata\":[{\"name\":\"string\",\"value\":[\"string\"]}],\"geometry\":\"Feature\"}",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v1/artefacts/0")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.body("{\"title\":\"string\",\"number\":\"string\",\"metadata\":[{\"name\":\"string\",\"value\":[\"string\"]}],\"geometry\":\"Feature\"}")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/0"
payload := strings.NewReader("{\"title\":\"string\",\"number\":\"string\",\"metadata\":[{\"name\":\"string\",\"value\":[\"string\"]}],\"geometry\":\"Feature\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v1/artefacts/{Id}
Updates an Artefact and/or the metadata on the current revision.
Body parameter
{
"title": "string",
"number": "string",
"metadata": [
{
"name": "string",
"value": [
"string"
]
}
],
"geometry": "Feature"
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Id | path | integer | true | none |
| body | body | UpdateRequest | false | none |
Example responses
400 Response
{
"code": 0,
"error": "string",
"title": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | OK | None |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
getLinkedArtefacts
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts/linked/string \
--header 'Accept: application/json'
GET /api/v1/artefacts/linked/string HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts/linked/string");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/linked/string")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts/linked/string", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/linked/string",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts/linked/string")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/linked/string"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts/linked/{entityName}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| entityName | path | string | true | Entity name (currently only ‘assets’ supported) |
| page | query | integer | false | Page number to fetch |
| limit | query | integer | false | Limit to fetch |
| modifiedAfter | query | string | false | Limit to artefacts modified after value given |
| modifiedBefore | query | string | false | Limit artefacts modified before value given |
Example responses
200 Response
{
"artefacts": [
{
"uuid": "string",
"artefactNumber": "string",
"artefactTitle": "string",
"artefactVersion": "string",
"revisionStatusUUID": "string",
"assets": [
"string"
]
}
],
"limit": 0,
"offset": 0,
"total": 0
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Artefacts by parameters | LinkedArtefacts |
| 400 | Bad Request | Error response | ResponseError |
downloadNativeFile
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts/0/download \
--header 'Accept: application/json'
GET /api/v1/artefacts/0/download HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts/0/download");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/0/download")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts/0/download", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/0/download",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts/0/download")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/0/download"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts/{Id}/download
Returns the native file download link of the latest approved revision of an artefact
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Id | path | integer | true | none |
Example responses
200 Response
{
"id": 0,
"url": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactLink | ArtefactLink |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
downloadPreview
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts/0/preview \
--header 'Accept: application/json'
GET /api/v1/artefacts/0/preview HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts/0/preview");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/0/preview")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts/0/preview", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/0/preview",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts/0/preview")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/0/preview"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts/{Id}/preview
Returns the preview download link of the latest approved revision of an artefact
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Id | path | integer | true | none |
Example responses
200 Response
{
"id": 0,
"url": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactLink | ArtefactLink |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
downloadThumbnail
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts/0/thumbnail \
--header 'Accept: application/json'
GET /api/v1/artefacts/0/thumbnail HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts/0/thumbnail");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/0/thumbnail")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts/0/thumbnail", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/0/thumbnail",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts/0/thumbnail")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/0/thumbnail"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts/{Id}/thumbnail
Returns the thumbnail download link of the latest approved revision of an artefact
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Id | path | integer | true | none |
Example responses
200 Response
{
"id": 0,
"url": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactLink | ArtefactLink |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
getVersionHistory
Code samples
curl --request GET \
--url http://localhost/api/v1/artefacts/0/versionhistory \
--header 'Accept: application/json'
GET /api/v1/artefacts/0/versionhistory HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/artefacts/0/versionhistory");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/0/versionhistory")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/artefacts/0/versionhistory", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/0/versionhistory",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/artefacts/0/versionhistory")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/0/versionhistory"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/artefacts/{Id}/versionhistory
Returns the version history of an artefact
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Id | path | integer | true | none |
Example responses
200 Response
{
"revision": {
"comment": "string",
"id": 0,
"preview": "string",
"status": "string",
"thumbnail": "string",
"timestamp": "string",
"version": 0
}
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactRevisionInfo | ArtefactRevisionInfo |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
getArtefactsModifiedSince
Code samples
curl --request POST \
--url http://localhost/api/v1/artefacts/changed \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"timestamp":"string"}'
POST /api/v1/artefacts/changed HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: localhost
Content-Length: 22
{"timestamp":"string"}
const data = JSON.stringify({
"timestamp": "string"
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v1/artefacts/changed");
xhr.setRequestHeader("Content-Type", "application/json");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/changed")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request["Accept"] = 'application/json'
request.body = "{\"timestamp\":\"string\"}"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "{\"timestamp\":\"string\"}"
headers = {
'Content-Type': "application/json",
'Accept': "application/json"
}
conn.request("POST", "/api/v1/artefacts/changed", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/changed",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\"timestamp\":\"string\"}",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v1/artefacts/changed")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.body("{\"timestamp\":\"string\"}")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/changed"
payload := strings.NewReader("{\"timestamp\":\"string\"}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v1/artefacts/changed
Returns the list of artefact ID’s that have been modified since a given time
Body parameter
{
"timestamp": "string"
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| body | body | ModifiedQuery | false | none |
Example responses
200 Response
{
"id": 0
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactIds | ArtefactIds |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
deleteGeometry
Code samples
curl --request DELETE \
--url http://localhost/api/v1/artefacts/0/geometry \
--header 'Accept: application/json'
DELETE /api/v1/artefacts/0/geometry HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("DELETE", "http://localhost/api/v1/artefacts/0/geometry");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/0/geometry")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Delete.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("DELETE", "/api/v1/artefacts/0/geometry", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/0/geometry",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.delete("http://localhost/api/v1/artefacts/0/geometry")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/0/geometry"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
DELETE /api/v1/artefacts/{Id}/geometry
Clears out Geometry for Existing Artefact
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| Id | path | integer | true | none |
Example responses
400 Response
{
"code": 0,
"error": "string",
"title": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | OK | None |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
addGroupsToArtefacts
Code samples
curl --request POST \
--url http://localhost/api/v1/artefact-groups \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"artefactIds":[0],"groupIds":[0]}'
POST /api/v1/artefact-groups HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: localhost
Content-Length: 34
{"artefactIds":[0],"groupIds":[0]}
const data = JSON.stringify({
"artefactIds": [
0
],
"groupIds": [
0
]
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v1/artefact-groups");
xhr.setRequestHeader("Content-Type", "application/json");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefact-groups")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request["Accept"] = 'application/json'
request.body = "{\"artefactIds\":[0],\"groupIds\":[0]}"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "{\"artefactIds\":[0],\"groupIds\":[0]}"
headers = {
'Content-Type': "application/json",
'Accept': "application/json"
}
conn.request("POST", "/api/v1/artefact-groups", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefact-groups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\"artefactIds\":[0],\"groupIds\":[0]}",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v1/artefact-groups")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.body("{\"artefactIds\":[0],\"groupIds\":[0]}")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefact-groups"
payload := strings.NewReader("{\"artefactIds\":[0],\"groupIds\":[0]}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v1/artefact-groups
Add groups to artefacts
Body parameter
{
"artefactIds": [
0
],
"groupIds": [
0
]
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| body | body | ArtefactGroupAssociationRequest | false | none |
Example responses
200 Response
{
"success": true,
"message": "string",
"errors": [
"string"
],
"updatedArtefacts": [
{
"artefactId": 0,
"artefactTitle": "string",
"artefactCode": "string",
"groups": [
{
"groupId": 0,
"groupName": "string",
"expired": true
}
]
}
],
"stats": {
"artefactsProcessed": 0,
"groupsProcessed": 0,
"associationsCreated": 0,
"associationsRemoved": 0,
"associationsSkipped": 0,
"artefactsNotFound": 0,
"groupsNotFound": 0,
"groupsExpired": 0
}
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactGroupAssociationResponse | ArtefactGroupAssociationResponse |
| 400 | Bad Request | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
removeGroupsFromArtefacts
Code samples
curl --request POST \
--url http://localhost/api/v1/artefact-groups/removals \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"artefactIds":[0],"groupIds":[0]}'
POST /api/v1/artefact-groups/removals HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: localhost
Content-Length: 34
{"artefactIds":[0],"groupIds":[0]}
const data = JSON.stringify({
"artefactIds": [
0
],
"groupIds": [
0
]
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v1/artefact-groups/removals");
xhr.setRequestHeader("Content-Type", "application/json");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefact-groups/removals")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request["Accept"] = 'application/json'
request.body = "{\"artefactIds\":[0],\"groupIds\":[0]}"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "{\"artefactIds\":[0],\"groupIds\":[0]}"
headers = {
'Content-Type': "application/json",
'Accept': "application/json"
}
conn.request("POST", "/api/v1/artefact-groups/removals", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefact-groups/removals",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\"artefactIds\":[0],\"groupIds\":[0]}",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v1/artefact-groups/removals")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.body("{\"artefactIds\":[0],\"groupIds\":[0]}")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefact-groups/removals"
payload := strings.NewReader("{\"artefactIds\":[0],\"groupIds\":[0]}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v1/artefact-groups/removals
Remove groups from artefacts
Body parameter
{
"artefactIds": [
0
],
"groupIds": [
0
]
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| body | body | ArtefactGroupAssociationRequest | false | none |
Example responses
200 Response
{
"success": true,
"message": "string",
"errors": [
"string"
],
"updatedArtefacts": [
{
"artefactId": 0,
"artefactTitle": "string",
"artefactCode": "string",
"groups": [
{
"groupId": 0,
"groupName": "string",
"expired": true
}
]
}
],
"stats": {
"artefactsProcessed": 0,
"groupsProcessed": 0,
"associationsCreated": 0,
"associationsRemoved": 0,
"associationsSkipped": 0,
"artefactsNotFound": 0,
"groupsNotFound": 0,
"groupsExpired": 0
}
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | ArtefactGroupAssociationResponse | ArtefactGroupAssociationResponse |
| 400 | Bad Request | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
deleteArtefacts
Code samples
curl --request POST \
--url http://localhost/api/v1/artefacts/batch/delete \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"artefactIds":[0]}'
POST /api/v1/artefacts/batch/delete HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: localhost
Content-Length: 19
{"artefactIds":[0]}
const data = JSON.stringify({
"artefactIds": [
0
]
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v1/artefacts/batch/delete");
xhr.setRequestHeader("Content-Type", "application/json");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/artefacts/batch/delete")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request["Accept"] = 'application/json'
request.body = "{\"artefactIds\":[0]}"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "{\"artefactIds\":[0]}"
headers = {
'Content-Type': "application/json",
'Accept': "application/json"
}
conn.request("POST", "/api/v1/artefacts/batch/delete", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/artefacts/batch/delete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\"artefactIds\":[0]}",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v1/artefacts/batch/delete")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.body("{\"artefactIds\":[0]}")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/artefacts/batch/delete"
payload := strings.NewReader("{\"artefactIds\":[0]}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v1/artefacts/batch/delete
Delete artefacts
Body parameter
{
"artefactIds": [
0
]
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| body | body | DeleteArtefactRequest | false | none |
Example responses
200 Response
{
"success": true,
"messages": [
"string"
]
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | OK | DeleteArtefactResult |
| 400 | Bad Request | Artefact ID set must be provided | DeleteArtefactResult |
| 403 | Forbidden | User does not have permission to delete artefacts | DeleteArtefactResult |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
Groups
getGroups
Code samples
curl --request GET \
--url http://localhost/api/v1/groups \
--header 'Accept: application/json'
GET /api/v1/groups HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/groups");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/groups")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/groups", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/groups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/groups")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/groups"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/groups
Returns the list of groups in the bucket
Example responses
200 Response
{
"items": [
{
"id": 0,
"name": "string"
}
]
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Groups | Groups |
| 400 | Bad Request | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
Metadata
getMetadata
Code samples
curl --request GET \
--url http://localhost/api/v1/metadata \
--header 'Accept: application/json'
GET /api/v1/metadata HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/metadata");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/metadata")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/metadata", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/metadata",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/metadata")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/metadata"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/metadata
This path is deprecated and will be removed in v.3.0.0 Returns the list of metadata keys in the bucket.
Example responses
200 Response
{
"items": [
{
"description": "string",
"id": 0,
"name": "string"
}
]
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | MetadataKeys | MetadataKeys |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
getMetadataKeys
Code samples
curl --request GET \
--url http://localhost/api/v1/metadata-keys \
--header 'Accept: application/json'
GET /api/v1/metadata-keys HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/metadata-keys");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/metadata-keys")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/metadata-keys", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/metadata-keys",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/metadata-keys")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/metadata-keys"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/metadata-keys
Returns the list of metadata keys in the bucket
Example responses
200 Response
{
"items": [
{
"description": "string",
"id": 0,
"name": "string"
}
]
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | MetadataKeys | MetadataKeys |
| 400 | Bad Request | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
getMetadataValues
Code samples
curl --request GET \
--url http://localhost/api/v1/metadata-key/values/0 \
--header 'Accept: application/json'
GET /api/v1/metadata-key/values/0 HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/metadata-key/values/0");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/metadata-key/values/0")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/metadata-key/values/0", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/metadata-key/values/0",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/metadata-key/values/0")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/metadata-key/values/0"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/metadata-key/values/{metadata_key_id}
Returns metadata values for the given metadata key.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| metadata_key_id | path | integer | true | Metadata key ID |
Example responses
200 Response
{
"items": [
{
"id": 0,
"value": "string",
"description": "string",
"uuid": "string"
}
]
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Metadata values | MetadataValues |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
Users
getUsers
Code samples
curl --request GET \
--url http://localhost/api/v1/users \
--header 'Accept: application/json'
GET /api/v1/users HTTP/1.1
Accept: application/json
Host: localhost
const data = null;
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("GET", "http://localhost/api/v1/users");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/users")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Accept"] = 'application/json'
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
headers = { 'Accept': "application/json" }
conn.request("GET", "/api/v1/users", headers=headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/users",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Accept: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.get("http://localhost/api/v1/users")
.header("Accept", "application/json")
.asString();
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/users"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
GET /api/v1/users
Search users in the bucket
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| page | query | integer | false | Denotes the page number. Typically used in conjunction with ‘limit’ to perform pagination of results. |
| limit | query | integer | false | Limits the number of results returned in the search. |
Example responses
200 Response
{
"data": {
"items": [
{
"bucketRoles": [
{
"ID": 0,
"Name": "string"
}
],
"department": "string",
"email": "string",
"enabled": true,
"firstName": "string",
"groups": [
{
"ID": 0,
"Name": "string",
"Roles": [
{
"ID": 0,
"Name": "string"
}
]
}
],
"id": 0,
"jobTitle": "string",
"lastName": "string",
"organisation": "string",
"phoneNumber": "string"
}
]
},
"length": 0,
"totalPages": 0,
"page": 0,
"total": 0
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | UsersResponse | UsersResponse |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
Search
search
Code samples
curl --request POST \
--url http://localhost/api/v1/search \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"advanced":{"and":[{"exact":true,"key_id":"string","property":"group","value":"string","relation":"intersects"}],"not":[{"exact":true,"key_id":"string","property":"group","value":"string","relation":"intersects"}],"or":[{"exact":true,"key_id":"string","property":"group","value":"string","relation":"intersects"}]},"query":"string","type":["string"]}'
POST /api/v1/search HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: localhost
Content-Length: 351
{"advanced":{"and":[{"exact":true,"key_id":"string","property":"group","value":"string","relation":"intersects"}],"not":[{"exact":true,"key_id":"string","property":"group","value":"string","relation":"intersects"}],"or":[{"exact":true,"key_id":"string","property":"group","value":"string","relation":"intersects"}]},"query":"string","type":["string"]}
const data = JSON.stringify({
"advanced": {
"and": [
{
"exact": true,
"key_id": "string",
"property": "group",
"value": "string",
"relation": "intersects"
}
],
"not": [
{
"exact": true,
"key_id": "string",
"property": "group",
"value": "string",
"relation": "intersects"
}
],
"or": [
{
"exact": true,
"key_id": "string",
"property": "group",
"value": "string",
"relation": "intersects"
}
]
},
"query": "string",
"type": [
"string"
]
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v1/search");
xhr.setRequestHeader("Content-Type", "application/json");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v1/search")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request["Accept"] = 'application/json'
request.body = "{\"advanced\":{\"and\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"not\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"or\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}]},\"query\":\"string\",\"type\":[\"string\"]}"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "{\"advanced\":{\"and\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"not\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"or\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}]},\"query\":\"string\",\"type\":[\"string\"]}"
headers = {
'Content-Type': "application/json",
'Accept': "application/json"
}
conn.request("POST", "/api/v1/search", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v1/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\"advanced\":{\"and\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"not\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"or\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}]},\"query\":\"string\",\"type\":[\"string\"]}",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v1/search")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.body("{\"advanced\":{\"and\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"not\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"or\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}]},\"query\":\"string\",\"type\":[\"string\"]}")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v1/search"
payload := strings.NewReader("{\"advanced\":{\"and\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"not\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}],\"or\":[{\"exact\":true,\"key_id\":\"string\",\"property\":\"group\",\"value\":\"string\",\"relation\":\"intersects\"}]},\"query\":\"string\",\"type\":[\"string\"]}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v1/search
Search Artefacts in the bucket
Body parameter
{
"advanced": {
"and": [
{
"exact": true,
"key_id": "string",
"property": "group",
"value": "string",
"relation": "intersects"
}
],
"not": [
{
"exact": true,
"key_id": "string",
"property": "group",
"value": "string",
"relation": "intersects"
}
],
"or": [
{
"exact": true,
"key_id": "string",
"property": "group",
"value": "string",
"relation": "intersects"
}
]
},
"query": "string",
"type": [
"string"
]
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| page | query | integer | false | Denotes the page number. Typically used in conjunction with ‘limit’ to perform pagination of results. |
| limit | query | integer | false | Limits the number of results returned in the search. |
| sort_by | query | string | false | Sort results by the specified field key. |
| direction | query | string | false | Sort direction for results. Values are ‘desc’ for descending, ‘asc’ for ascending values. Default ascending. |
| createdSince | query | string | false | Search artefacts that have been created on or after the specified date. |
| createdUntil | query | string | false | Search artefacts that have been created on or before the specified date. |
| modifiedSince | query | string | false | Search artefacts that have been modified on or after the specified date. |
| modifiedUntil | query | string | false | Search artefacts that have been modified on or before the specified date. |
| body | body | SearchQuery | false | none |
Example responses
200 Response
{
"items": [
{
"created": "string",
"groups": [
{
"id": 0,
"name": "string"
}
],
"id": 0,
"locations": {
"lat": "string",
"lon": "string"
},
"metadata": [
{
"id": 0,
"key_id": 0,
"key_name": "string",
"value": "string"
}
],
"modified": "string",
"number": "string",
"revisions": [
{
"comment": "string",
"id": 0,
"preview": "string",
"status": "string",
"thumbnail": "string",
"timestamp": "string",
"version": 0
}
],
"state": {
"is_destructible": true,
"is_modifiable": true,
"is_viewable": true,
"name": "string"
},
"title": "string",
"type": "string",
"workflow": {
"id": 0,
"name": "string",
"step": {
"id": 0,
"name": "string",
"type": {
"id": 0,
"name": "string"
}
}
},
"geometry": "Feature"
}
]
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | Artefacts | Artefacts |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
Upload
checkFilesExist
Code samples
curl --request POST \
--url http://localhost/api/v2/files/exist \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{"hashes":["string"]}'
POST /api/v2/files/exist HTTP/1.1
Content-Type: application/json
Accept: application/json
Host: localhost
Content-Length: 21
{"hashes":["string"]}
const data = JSON.stringify({
"hashes": [
"string"
]
});
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v2/files/exist");
xhr.setRequestHeader("Content-Type", "application/json");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v2/files/exist")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request["Accept"] = 'application/json'
request.body = "{\"hashes\":[\"string\"]}"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "{\"hashes\":[\"string\"]}"
headers = {
'Content-Type': "application/json",
'Accept': "application/json"
}
conn.request("POST", "/api/v2/files/exist", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v2/files/exist",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\"hashes\":[\"string\"]}",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v2/files/exist")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.body("{\"hashes\":[\"string\"]}")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v2/files/exist"
payload := strings.NewReader("{\"hashes\":[\"string\"]}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v2/files/exist
Returns the list of file hashes that already exist in the bucket
Body parameter
{
"hashes": [
"string"
]
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| body | body | FileHashes | false | none |
Example responses
200 Response
{
"items": [
"string"
]
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | File-hashes Response | FileHashesResp |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
upload
Code samples
curl --request POST \
--url http://localhost/api/v2/upload \
--header 'Accept: application/json' \
--header 'Content-Type: multipart/form-data; boundary=---011000010111000001101001' \
--form file=string \
--form data=string
POST /api/v2/upload HTTP/1.1
Content-Type: multipart/form-data; boundary=---011000010111000001101001
Accept: application/json
Host: localhost
Content-Length: 205
-----011000010111000001101001
Content-Disposition: form-data; name="file"
string
-----011000010111000001101001
Content-Disposition: form-data; name="data"
string
-----011000010111000001101001--
const data = new FormData();
data.append("file", "string");
data.append("data", "string");
const xhr = new XMLHttpRequest();
xhr.withCredentials = true;
xhr.addEventListener("readystatechange", function () {
if (this.readyState === this.DONE) {
console.log(this.responseText);
}
});
xhr.open("POST", "http://localhost/api/v2/upload");
xhr.setRequestHeader("Accept", "application/json");
xhr.send(data);
require 'uri'
require 'net/http'
url = URI("http://localhost/api/v2/upload")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'multipart/form-data; boundary=---011000010111000001101001'
request["Accept"] = 'application/json'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"\r\n\r\nstring\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"data\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n"
response = http.request(request)
puts response.read_body
import http.client
conn = http.client.HTTPConnection("localhost")
payload = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"\r\n\r\nstring\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"data\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n"
headers = {
'Content-Type': "multipart/form-data; boundary=---011000010111000001101001",
'Accept': "application/json"
}
conn.request("POST", "/api/v2/upload", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://localhost/api/v2/upload",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"\r\n\r\nstring\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"data\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n",
CURLOPT_HTTPHEADER => [
"Accept: application/json",
"Content-Type: multipart/form-data; boundary=---011000010111000001101001"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
HttpResponse<String> response = Unirest.post("http://localhost/api/v2/upload")
.header("Content-Type", "multipart/form-data; boundary=---011000010111000001101001")
.header("Accept", "application/json")
.body("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"\r\n\r\nstring\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"data\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n")
.asString();
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost/api/v2/upload"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"\r\n\r\nstring\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"data\"\r\n\r\nstring\r\n-----011000010111000001101001--\r\n")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "multipart/form-data; boundary=---011000010111000001101001")
req.Header.Add("Accept", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
POST /api/v2/upload
Upload a new Artefact to the bucket
This path is a multipart/form-data that takes 2 parameters
file: (file) The file to upload. If mime-type is set to 'text/uri-list', a signed S3/Azure/GCP storage URL can be provided to pulldata: (json) The data used as part of your bucket upload rules to populate metadata and move the artefact to the right workflow and group. Schema: InputUploadRequest
Body parameter
file: string
data: string
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| async | query | boolean | false | Process upload in the background and do not wait until processing is complete before returning. |
| body | body | UploadBody | false | none |
Example responses
200 Response
{
"artefact": {
"created": "string",
"groups": [
{
"id": 0,
"name": "string"
}
],
"id": 0,
"locations": {
"lat": "string",
"lon": "string"
},
"metadata": [
{
"id": 0,
"key_id": 0,
"key_name": "string",
"value": "string"
}
],
"modified": "string",
"number": "string",
"revisions": [
{
"comment": "string",
"id": 0,
"preview": "string",
"status": "string",
"thumbnail": "string",
"timestamp": "string",
"version": 0
}
],
"state": {
"is_destructible": true,
"is_modifiable": true,
"is_viewable": true,
"name": "string"
},
"title": "string",
"type": "string",
"workflow": {
"id": 0,
"name": "string",
"step": {
"id": 0,
"name": "string",
"type": {
"id": 0,
"name": "string"
}
}
},
"geometry": "Feature"
},
"artefact_id": 0,
"message": "string",
"post_upload_actions": [
"string"
],
"revision_action": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 200 | OK | UploadResponseView | UploadResponseView |
| 400 | Bad Request | ResponseError | ResponseError |
| 404 | Not Found | ResponseError | ResponseError |
| 500 | Internal Server Error | Internal Server Error | None |
Response Schema
Schemas
MultipartFile
file: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| file | string(binary) | true | none | none |
RolePerms
ID: 0
Name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| ID | integer | false | none | none |
| Name | string | false | none | none |
ResponseError
code: 0
error: string
title: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| code | integer | false | none | Response error code eg 404 |
| error | string | false | none | Error message |
| title | string | false | none | Error type title eg BadRequest |
Group
id: 0
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
| name | string | false | none | none |
Metadata
id: 0
key_id: 0
key_name: string
value: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
| key_id | integer | false | none | none |
| key_name | string | false | none | none |
| value | string | false | none | none |
State
is_destructible: true
is_modifiable: true
is_viewable: true
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| is_destructible | boolean | false | none | none |
| is_modifiable | boolean | false | none | none |
| is_viewable | boolean | false | none | none |
| name | string | false | none | none |
StepType
id: 0
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
| name | string | false | none | none |
WorkflowStep
id: 0
name: string
type:
id: 0
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
| name | string | false | none | none |
| type | StepType | false | none | none |
Workflow
id: 0
name: string
step:
id: 0
name: string
type:
id: 0
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
| name | string | false | none | none |
| step | WorkflowStep | false | none | none |
Revision
comment: string
id: 0
preview: string
status: string
thumbnail: string
timestamp: string
version: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| comment | string | false | none | none |
| id | integer | false | none | none |
| preview | string | false | none | none |
| status | string | false | none | none |
| thumbnail | string | false | none | none |
| timestamp | string | false | none | none |
| version | integer | false | none | none |
Artefact
created: string
groups:
- id: 0
name: string
id: 0
locations:
lat: string
lon: string
metadata:
- id: 0
key_id: 0
key_name: string
value: string
modified: string
number: string
revisions:
- comment: string
id: 0
preview: string
status: string
thumbnail: string
timestamp: string
version: 0
state:
is_destructible: true
is_modifiable: true
is_viewable: true
name: string
title: string
type: string
workflow:
id: 0
name: string
step:
id: 0
name: string
type:
id: 0
name: string
geometry: Feature
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| created | string | false | none | none |
| groups | [Group] | false | none | none |
| id | integer | false | none | none |
| locations | ElasticLocation | false | none | none |
| metadata | [Metadata] | false | none | none |
| modified | string | false | none | none |
| number | string | false | none | none |
| revisions | [Revision] | false | none | none |
| state | State | false | none | none |
| title | string | false | none | none |
| type | string | false | none | none |
| workflow | Workflow | false | none | none |
| geometry | string | false | none | none |
Enumerated Values
| Property | Value |
|---|---|
| geometry | Feature |
| geometry | FeatureCollection |
| geometry | Point |
| geometry | MultiPoint |
| geometry | LineString |
| geometry | MultiLineString |
| geometry | Polygon |
| geometry | MultiPolygon |
| geometry | GeometryCollection |
ElasticLocation
lat: string
lon: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| lat | string | false | none | none |
| lon | string | false | none | none |
UpdateMetadata
name: string
value:
- string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| name | string | false | none | MetadataKey name |
| value | [string] | false | none | Metadata values |
UpdateRequest
title: string
number: string
metadata:
- name: string
value:
- string
geometry: Feature
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| title | string | false | none | Title of the artefact |
| number | string | false | none | Code of the artefact |
| metadata | [UpdateMetadata] | false | none | Metadata of the artefact |
| geometry | string | false | none | none |
Enumerated Values
| Property | Value |
|---|---|
| geometry | Feature |
| geometry | FeatureCollection |
| geometry | Point |
| geometry | MultiPoint |
| geometry | LineString |
| geometry | MultiLineString |
| geometry | Polygon |
| geometry | MultiPolygon |
| geometry | GeometryCollection |
ArtefactIds
id: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
ArtefactLink
id: 0
url: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
| url | string | false | none | none |
ArtefactListResponse
limit: 0
offset: 0
results:
- id: 0
name: string
number: string
score: string
type: string
total: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| limit | integer | false | none | none |
| offset | integer | false | none | none |
| results | [SimpleArtefact] | false | none | none |
| total | integer | false | none | none |
SimpleArtefact
id: 0
name: string
number: string
score: string
type: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | false | none | none |
| name | string | false | none | none |
| number | string | false | none | none |
| score | string | false | none | none |
| type | string | false | none | none |
ArtefactRevisionInfo
revision:
comment: string
id: 0
preview: string
status: string
thumbnail: string
timestamp: string
version: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| revision | Revision | false | none | none |
LinkedArtefact
uuid: string
artefactNumber: string
artefactTitle: string
artefactVersion: string
revisionStatusUUID: string
assets:
- string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| uuid | string | true | none | Artefact UUID |
| artefactNumber | string | false | none | Artefact Number |
| artefactTitle | string | false | none | Artefact Title |
| artefactVersion | string | true | none | Revision Metadata on Artefact |
| revisionStatusUUID | string | true | none | RevisionStatus UUID |
| assets | [string] | true | none | UUIDs of asset metadata values |
LinkedArtefacts
artefacts:
- uuid: string
artefactNumber: string
artefactTitle: string
artefactVersion: string
revisionStatusUUID: string
assets:
- string
limit: 0
offset: 0
total: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| artefacts | [LinkedArtefact] | true | none | none |
| limit | integer | true | none | none |
| offset | integer | true | none | none |
| total | integer | true | none | none |
DeletedArtefacts
deletedArtefacts:
- string
limit: 0
offset: 0
total: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| deletedArtefacts | [string] | true | none | Array of deleted artefact UUIDs |
| limit | integer | true | none | none |
| offset | integer | true | none | none |
| total | integer | true | none | none |
ArtefactGroupAssociationRequest
artefactIds:
- 0
groupIds:
- 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| artefactIds | [integer] | true | none | List of artefact IDs to associate with or disassociate from groups |
| groupIds | [integer] | true | none | List of group (Project) IDs to add to or remove from artefacts |
GroupInfo
groupId: 0
groupName: string
expired: true
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| groupId | integer | false | none | none |
| groupName | string | false | none | none |
| expired | boolean | false | none | none |
ArtefactGroupInfo
artefactId: 0
artefactTitle: string
artefactCode: string
groups:
- groupId: 0
groupName: string
expired: true
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| artefactId | integer | false | none | none |
| artefactTitle | string | false | none | none |
| artefactCode | string | false | none | none |
| groups | [GroupInfo] | false | none | none |
OperationStats
artefactsProcessed: 0
groupsProcessed: 0
associationsCreated: 0
associationsRemoved: 0
associationsSkipped: 0
artefactsNotFound: 0
groupsNotFound: 0
groupsExpired: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| artefactsProcessed | integer | false | none | none |
| groupsProcessed | integer | false | none | none |
| associationsCreated | integer | false | none | none |
| associationsRemoved | integer | false | none | none |
| associationsSkipped | integer | false | none | none |
| artefactsNotFound | integer | false | none | none |
| groupsNotFound | integer | false | none | none |
| groupsExpired | integer | false | none | none |
ArtefactGroupAssociationResponse
success: true
message: string
errors:
- string
updatedArtefacts:
- artefactId: 0
artefactTitle: string
artefactCode: string
groups:
- groupId: 0
groupName: string
expired: true
stats:
artefactsProcessed: 0
groupsProcessed: 0
associationsCreated: 0
associationsRemoved: 0
associationsSkipped: 0
artefactsNotFound: 0
groupsNotFound: 0
groupsExpired: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| success | boolean | false | none | Overall operation success status |
| message | string | false | none | Human-readable message describing the operation result |
| errors | [string] | false | none | List of error messages encountered during the operation |
| updatedArtefacts | [ArtefactGroupInfo] | false | none | List of updated artefacts with their associated groups |
| stats | OperationStats | false | none | Operation statistics |
DeleteArtefactRequest
artefactIds:
- 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| artefactIds | [integer] | true | none | Set of artefact IDs to delete |
DeleteArtefactResult
success: true
messages:
- string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| success | boolean | true | none | Outcome of delete operation for an artefact |
| messages | [string] | true | none | List of messages describing the result status of the delete operation of the artefact |
ModifiedQuery
timestamp: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| timestamp | string | false | none | none |
Groups
items:
- id: 0
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| items | [Group] | false | none | none |
MetadataKey
description: string
id: 0
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| description | string | true | none | user friendly description of the metadata key |
| id | integer | true | none | ID of the metadata key to use in the search path |
| name | string | true | none | user friendly name of the metadata key |
MetadataKeys
items:
- description: string
id: 0
name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| items | [MetadataKey] | false | none | none |
MetadataValue
id: 0
value: string
description: string
uuid: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| id | integer | true | none | MetadataValue ID |
| value | string | true | none | MetadataValue value |
| description | string | false | none | MetadataValue description if available |
| uuid | string | false | none | MetadataValue UUID as string |
MetadataValues
items:
- id: 0
value: string
description: string
uuid: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| items | [MetadataValue] | false | none | none |
GroupRoles
ID: 0
Name: string
Roles:
- ID: 0
Name: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| ID | integer | false | none | none |
| Name | string | false | none | none |
| Roles | [RolePerms] | false | none | none |
UserRoles
bucketRoles:
- ID: 0
Name: string
department: string
email: string
enabled: true
firstName: string
groups:
- ID: 0
Name: string
Roles:
- ID: 0
Name: string
id: 0
jobTitle: string
lastName: string
organisation: string
phoneNumber: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| bucketRoles | [RolePerms] | false | none | none |
| department | string | false | none | none |
| string | false | none | none | |
| enabled | boolean | false | none | none |
| firstName | string | false | none | none |
| groups | [GroupRoles] | false | none | none |
| id | integer | false | none | none |
| jobTitle | string | false | none | none |
| lastName | string | false | none | none |
| organisation | string | false | none | none |
| phoneNumber | string | false | none | none |
UserRolesList
items:
- bucketRoles:
- ID: 0
Name: string
department: string
email: string
enabled: true
firstName: string
groups:
- ID: 0
Name: string
Roles:
- ID: 0
Name: string
id: 0
jobTitle: string
lastName: string
organisation: string
phoneNumber: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| items | [UserRoles] | false | none | none |
UsersResponse
data:
items:
- bucketRoles:
- ID: 0
Name: string
department: string
email: string
enabled: true
firstName: string
groups:
- ID: 0
Name: string
Roles:
- ID: 0
Name: string
id: 0
jobTitle: string
lastName: string
organisation: string
phoneNumber: string
length: 0
totalPages: 0
page: 0
total: 0
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| data | UserRolesList | false | none | none |
| length | integer | false | none | none |
| totalPages | integer | false | none | none |
| page | integer | false | none | none |
| total | integer | false | none | none |
SearchProperty
exact: true
key_id: string
property: group
value: string
relation: intersects
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| exact | boolean | false | none | When true, it will filter the exact value without wildcards. Default |
| key_id | string | false | none | The key_id is the metadata key ID |
| property | string | true | none | The property to filter against. |
| value | string | true | none | The value to filter against. Where the ‘property’ is set to ‘geometry’, The value is expected to be a GeoJSON object or a WKT string input. |
| relation | string | false | none | Spatial searching filter * intersects - (default) Return all artefacts whose geometry property intersects the query geometry * disjoint - Return all artefacts whose geometry property has nothing in common with the query geometry * within - Return all artefats whose geometry property is within the query geometry. Line geometries are not supported. * contains - Return all artefacts whose geometry property contains the query geometry. |
Enumerated Values
| Property | Value |
|---|---|
| property | group |
| property | metadata |
| property | title |
| property | number |
| property | geometry |
| relation | intersects |
| relation | disjoint |
| relation | within |
| relation | contains |
AdvanceSearchQuery
and:
- exact: true
key_id: string
property: group
value: string
relation: intersects
not:
- exact: true
key_id: string
property: group
value: string
relation: intersects
or:
- exact: true
key_id: string
property: group
value: string
relation: intersects
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| and | [SearchProperty] | false | none | none |
| not | [SearchProperty] | false | none | none |
| or | [SearchProperty] | false | none | none |
SearchQuery
advanced:
and:
- exact: true
key_id: string
property: group
value: string
relation: intersects
not:
- exact: true
key_id: string
property: group
value: string
relation: intersects
or:
- exact: true
key_id: string
property: group
value: string
relation: intersects
query: string
type:
- string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| advanced | AdvanceSearchQuery | false | none | none |
| query | string | false | none | Query string to search across all title, number, and metadata values |
| type | [string] | false | none | List of artefact types to filter against |
Artefacts
items:
- created: string
groups:
- id: 0
name: string
id: 0
locations:
lat: string
lon: string
metadata:
- id: 0
key_id: 0
key_name: string
value: string
modified: string
number: string
revisions:
- comment: string
id: 0
preview: string
status: string
thumbnail: string
timestamp: string
version: 0
state:
is_destructible: true
is_modifiable: true
is_viewable: true
name: string
title: string
type: string
workflow:
id: 0
name: string
step:
id: 0
name: string
type:
id: 0
name: string
geometry: Feature
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| items | [Artefact] | false | none | none |
UploadResponseView
artefact:
created: string
groups:
- id: 0
name: string
id: 0
locations:
lat: string
lon: string
metadata:
- id: 0
key_id: 0
key_name: string
value: string
modified: string
number: string
revisions:
- comment: string
id: 0
preview: string
status: string
thumbnail: string
timestamp: string
version: 0
state:
is_destructible: true
is_modifiable: true
is_viewable: true
name: string
title: string
type: string
workflow:
id: 0
name: string
step:
id: 0
name: string
type:
id: 0
name: string
geometry: Feature
artefact_id: 0
message: string
post_upload_actions:
- string
revision_action: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| artefact | Artefact | false | none | none |
| artefact_id | integer | false | none | none |
| message | string | false | none | none |
| post_upload_actions | [string] | false | none | none |
| revision_action | string | false | none | none |
Hash
md5: string
sha256: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| md5 | string | false | none | none |
| sha256 | string | false | none | none |
FileHashes
hashes:
- string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| hashes | [string] | false | none | none |
FileHashesResp
items:
- string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| items | [string] | false | none | none |
InputMetadataKeyValuePair
name: string
value:
- string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| name | string | true | none | The name of the metadata key or arbitrary key |
| value | [string] | false | none | The values to use with the key |
InputUploadRequest
artefactHash:
md5: string
sha256: string
fileHash: string
metadata:
- name: string
value:
- string
noFile: true
type: drawing
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| artefactHash | Hash | false | none | none |
| fileHash | string | false | none | none |
| metadata | [InputMetadataKeyValuePair] | false | none | List of keys and their values. Keys can either be the name of your bucket metadata keys, or arbitrary keys required by your bucket upload rules |
| noFile | boolean | false | none | When true, creates a placeholder |
| type | string | true | none | The Artefact type |
Enumerated Values
| Property | Value |
|---|---|
| type | drawing |
| type | document |
| type | media |
UploadBody
file: string
data: string
Properties
| Name | Type | Required | Restrictions | Description |
|---|---|---|---|---|
| file | string | false | none | none |
| data | string | false | none | none |