curl --request POST \
--url https://api.example.com/api/v1/schema \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"version": "0.0.1",
"description": "Detector schema description example",
"schema": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": [
"name",
"version"
]
},
"title": "<string>",
"author": "<string>",
"icon": "<string>",
"tags": [
"<string>"
],
"networkTags": [
"<string>"
],
"faq": [
{
"name": "<string>",
"value": "<string>"
}
],
"uiSchema": {}
}
'import requests
url = "https://api.example.com/api/v1/schema"
payload = {
"name": "<string>",
"version": "0.0.1",
"description": "Detector schema description example",
"schema": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": ["name", "version"]
},
"title": "<string>",
"author": "<string>",
"icon": "<string>",
"tags": ["<string>"],
"networkTags": ["<string>"],
"faq": [
{
"name": "<string>",
"value": "<string>"
}
],
"uiSchema": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
version: '0.0.1',
description: 'Detector schema description example',
schema: {
$schema: 'https://json-schema.org/draft/2020-12/schema',
title: 'Product',
description: 'Json schema example',
type: 'object',
properties: {
name: {description: 'String property example', type: 'string'},
version: {description: 'Integer property example', type: 'integer', exclusiveMinimum: 0}
},
required: ['name', 'version']
},
title: '<string>',
author: '<string>',
icon: '<string>',
tags: ['<string>'],
networkTags: ['<string>'],
faq: [{name: '<string>', value: '<string>'}],
uiSchema: {}
})
};
fetch('https://api.example.com/api/v1/schema', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v1/schema",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'version' => '0.0.1',
'description' => 'Detector schema description example',
'schema' => [
'$schema' => 'https://json-schema.org/draft/2020-12/schema',
'title' => 'Product',
'description' => 'Json schema example',
'type' => 'object',
'properties' => [
'name' => [
'description' => 'String property example',
'type' => 'string'
],
'version' => [
'description' => 'Integer property example',
'type' => 'integer',
'exclusiveMinimum' => 0
]
],
'required' => [
'name',
'version'
]
],
'title' => '<string>',
'author' => '<string>',
'icon' => '<string>',
'tags' => [
'<string>'
],
'networkTags' => [
'<string>'
],
'faq' => [
[
'name' => '<string>',
'value' => '<string>'
]
],
'uiSchema' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v1/schema"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"version\": \"0.0.1\",\n \"description\": \"Detector schema description example\",\n \"schema\": {\n \"$schema\": \"https://json-schema.org/draft/2020-12/schema\",\n \"title\": \"Product\",\n \"description\": \"Json schema example\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"description\": \"String property example\",\n \"type\": \"string\"\n },\n \"version\": {\n \"description\": \"Integer property example\",\n \"type\": \"integer\",\n \"exclusiveMinimum\": 0\n }\n },\n \"required\": [\n \"name\",\n \"version\"\n ]\n },\n \"title\": \"<string>\",\n \"author\": \"<string>\",\n \"icon\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"networkTags\": [\n \"<string>\"\n ],\n \"faq\": [\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"uiSchema\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/v1/schema")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"version\": \"0.0.1\",\n \"description\": \"Detector schema description example\",\n \"schema\": {\n \"$schema\": \"https://json-schema.org/draft/2020-12/schema\",\n \"title\": \"Product\",\n \"description\": \"Json schema example\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"description\": \"String property example\",\n \"type\": \"string\"\n },\n \"version\": {\n \"description\": \"Integer property example\",\n \"type\": \"integer\",\n \"exclusiveMinimum\": 0\n }\n },\n \"required\": [\n \"name\",\n \"version\"\n ]\n },\n \"title\": \"<string>\",\n \"author\": \"<string>\",\n \"icon\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"networkTags\": [\n \"<string>\"\n ],\n \"faq\": [\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"uiSchema\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/schema")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"version\": \"0.0.1\",\n \"description\": \"Detector schema description example\",\n \"schema\": {\n \"$schema\": \"https://json-schema.org/draft/2020-12/schema\",\n \"title\": \"Product\",\n \"description\": \"Json schema example\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"description\": \"String property example\",\n \"type\": \"string\"\n },\n \"version\": {\n \"description\": \"Integer property example\",\n \"type\": \"integer\",\n \"exclusiveMinimum\": 0\n }\n },\n \"required\": [\n \"name\",\n \"version\"\n ]\n },\n \"title\": \"<string>\",\n \"author\": \"<string>\",\n \"icon\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"networkTags\": [\n \"<string>\"\n ],\n \"faq\": [\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"uiSchema\": {}\n}"
response = http.request(request)
puts response.read_body{
"id": 1,
"createdAt": 123,
"updatedAt": 123,
"title": "<string>",
"name": "<string>",
"version": "0.0.1",
"description": "Detector schema description example",
"author": "<string>",
"icon": "<string>",
"tags": [
"<string>"
],
"networkTags": [
"<string>"
],
"faq": [
{
"name": "<string>",
"value": "<string>"
}
],
"schema": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": [
"name",
"version"
]
},
"uiSchema": {}
}create entity
curl --request POST \
--url https://api.example.com/api/v1/schema \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"version": "0.0.1",
"description": "Detector schema description example",
"schema": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": [
"name",
"version"
]
},
"title": "<string>",
"author": "<string>",
"icon": "<string>",
"tags": [
"<string>"
],
"networkTags": [
"<string>"
],
"faq": [
{
"name": "<string>",
"value": "<string>"
}
],
"uiSchema": {}
}
'import requests
url = "https://api.example.com/api/v1/schema"
payload = {
"name": "<string>",
"version": "0.0.1",
"description": "Detector schema description example",
"schema": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": ["name", "version"]
},
"title": "<string>",
"author": "<string>",
"icon": "<string>",
"tags": ["<string>"],
"networkTags": ["<string>"],
"faq": [
{
"name": "<string>",
"value": "<string>"
}
],
"uiSchema": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
version: '0.0.1',
description: 'Detector schema description example',
schema: {
$schema: 'https://json-schema.org/draft/2020-12/schema',
title: 'Product',
description: 'Json schema example',
type: 'object',
properties: {
name: {description: 'String property example', type: 'string'},
version: {description: 'Integer property example', type: 'integer', exclusiveMinimum: 0}
},
required: ['name', 'version']
},
title: '<string>',
author: '<string>',
icon: '<string>',
tags: ['<string>'],
networkTags: ['<string>'],
faq: [{name: '<string>', value: '<string>'}],
uiSchema: {}
})
};
fetch('https://api.example.com/api/v1/schema', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/v1/schema",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'version' => '0.0.1',
'description' => 'Detector schema description example',
'schema' => [
'$schema' => 'https://json-schema.org/draft/2020-12/schema',
'title' => 'Product',
'description' => 'Json schema example',
'type' => 'object',
'properties' => [
'name' => [
'description' => 'String property example',
'type' => 'string'
],
'version' => [
'description' => 'Integer property example',
'type' => 'integer',
'exclusiveMinimum' => 0
]
],
'required' => [
'name',
'version'
]
],
'title' => '<string>',
'author' => '<string>',
'icon' => '<string>',
'tags' => [
'<string>'
],
'networkTags' => [
'<string>'
],
'faq' => [
[
'name' => '<string>',
'value' => '<string>'
]
],
'uiSchema' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/api/v1/schema"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"version\": \"0.0.1\",\n \"description\": \"Detector schema description example\",\n \"schema\": {\n \"$schema\": \"https://json-schema.org/draft/2020-12/schema\",\n \"title\": \"Product\",\n \"description\": \"Json schema example\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"description\": \"String property example\",\n \"type\": \"string\"\n },\n \"version\": {\n \"description\": \"Integer property example\",\n \"type\": \"integer\",\n \"exclusiveMinimum\": 0\n }\n },\n \"required\": [\n \"name\",\n \"version\"\n ]\n },\n \"title\": \"<string>\",\n \"author\": \"<string>\",\n \"icon\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"networkTags\": [\n \"<string>\"\n ],\n \"faq\": [\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"uiSchema\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/api/v1/schema")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"version\": \"0.0.1\",\n \"description\": \"Detector schema description example\",\n \"schema\": {\n \"$schema\": \"https://json-schema.org/draft/2020-12/schema\",\n \"title\": \"Product\",\n \"description\": \"Json schema example\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"description\": \"String property example\",\n \"type\": \"string\"\n },\n \"version\": {\n \"description\": \"Integer property example\",\n \"type\": \"integer\",\n \"exclusiveMinimum\": 0\n }\n },\n \"required\": [\n \"name\",\n \"version\"\n ]\n },\n \"title\": \"<string>\",\n \"author\": \"<string>\",\n \"icon\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"networkTags\": [\n \"<string>\"\n ],\n \"faq\": [\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"uiSchema\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/v1/schema")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"version\": \"0.0.1\",\n \"description\": \"Detector schema description example\",\n \"schema\": {\n \"$schema\": \"https://json-schema.org/draft/2020-12/schema\",\n \"title\": \"Product\",\n \"description\": \"Json schema example\",\n \"type\": \"object\",\n \"properties\": {\n \"name\": {\n \"description\": \"String property example\",\n \"type\": \"string\"\n },\n \"version\": {\n \"description\": \"Integer property example\",\n \"type\": \"integer\",\n \"exclusiveMinimum\": 0\n }\n },\n \"required\": [\n \"name\",\n \"version\"\n ]\n },\n \"title\": \"<string>\",\n \"author\": \"<string>\",\n \"icon\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"networkTags\": [\n \"<string>\"\n ],\n \"faq\": [\n {\n \"name\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"uiSchema\": {}\n}"
response = http.request(request)
puts response.read_body{
"id": 1,
"createdAt": 123,
"updatedAt": 123,
"title": "<string>",
"name": "<string>",
"version": "0.0.1",
"description": "Detector schema description example",
"author": "<string>",
"icon": "<string>",
"tags": [
"<string>"
],
"networkTags": [
"<string>"
],
"faq": [
{
"name": "<string>",
"value": "<string>"
}
],
"schema": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": [
"name",
"version"
]
},
"uiSchema": {}
}Authorizations
Authentication
Body
Name of the detector schema
1Version of the detector schema
1"0.0.1"
Description of the detector schema
1"Detector schema description example"
Json Schema value of the detector schema
Show child attributes
Show child attributes
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": ["name", "version"]
}
Status of the entity. Default: 'ACTIVE'
ACTIVE, DISABLED, DELETED Title of the detector schema, shown to UI user
Author for the detector schema
Icon for the detector schema
Detector schema tags. Example SECURITY, COMPLIANCE
Detector schema tags, list of groups or networks that are allowed for this schema. Can include ChainGroup (network group, eg: 'evm') or ChainUid (network eg: 'ethereum'). Empty = any network
FAQ of the detector schema
Show child attributes
Show child attributes
UI Schema value of the detector schema
Show child attributes
Show child attributes
{}
Response
OK
Unique identifier of the entity
1
Time when entity was created
Time when entity was updated
Status of the entity. Default: 'ACTIVE'
ACTIVE, DISABLED, DELETED Title of the detector schema, shown to UI user
Name of the detector schema
Version of the detector schema
"0.0.1"
Description of the detector schema
"Detector schema description example"
Author for the detector schema
Icon for the detector schema
Detector schema tags. Example SECURITY, COMPLIANCE
Detector schema tags, list of groups or networks that are allowed for this schema. Can include ChainGroup (network group, eg: 'evm') or ChainUid (network eg: 'ethereum'). Empty = any network
FAQ of the detector schema
Show child attributes
Show child attributes
Json Schema value of the detector schema
Show child attributes
Show child attributes
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Product",
"description": "Json schema example",
"type": "object",
"properties": {
"name": {
"description": "String property example",
"type": "string"
},
"version": {
"description": "Integer property example",
"type": "integer",
"exclusiveMinimum": 0
}
},
"required": ["name", "version"]
}
UI Schema value of the detector schema
Show child attributes
Show child attributes
{}