Adds a new supplier.
The added supplier is a REST API supplier and can be managed with REST API methods. The new supplier is enabled by default.
Path
/api/%API_VERSION%/suppliers
Method
POST
Request headers
This request has the following headers.
Request headers
Name |
Value |
Description |
---|---|---|
|
|
|
|
|
Response content type. |
|
|
Request content type. You can also specify the |
|
|
Request body size, in bytes. The maximum body size for this request is 128 MB ( |
Request body
This request body contains a JSON array with a supplier object. Only one supplier object must be specified.
[
{
"name":"%SUPPLIER_NAME%",
"confidence": %SUPPLIER_CONFIDENCE%,
"retention": %SUPPLIER_RETENTION%,
"vendor": "%SUPPLIER_VENDOR%"
}
]
Supplier object properties are described in the following table.
Supplier object properties
Property |
Value |
Mandatory |
Description |
---|---|---|---|
|
|
Yes |
Name of the supplier. The name of the supplier must contain only Latin letters, digits, hyphens ( Do not use FalsePositive or InternalTI as the supplier name, since they are reserved for the built-in supplier names of Kaspersky CyberTrace. |
|
|
Yes |
Confidence level for indicators from this supplier. The range of values for this parameter is from |
|
|
Yes |
Retention period for indicators, in minutes. This parameter determines the timeout after which indicators from this supplier are not used in matching. The timeout is calculated from the last update of the indicator. |
|
|
No |
Supplier vendor name. |
Request example
The following is an example of a POST suppliers request.
POST https://192.0.2.57/api/1.1/
Accept: application/json Content-Type: application/json Authorization: Basic Content-Length: 91 [ {"name":"ExampleSupplier", "confidence": 90, "retention": 5000, "vendor": "ExampleVendor"} ] |
Response headers
The response has the following headers.
Response headers
Name |
Value |
Description |
---|---|---|
Content-Type |
|
Response content type. |
Content-Length |
|
Response body size, in bytes. |
Response body
The response body contains a JSON object with a status of the operation.
[
{
"status": "Supplier successfully created"
}
]
Status object properties are described in the following table.
Status object properties
Property |
Value |
Description |
---|---|---|
|
|
Status of the operation. |
Response example
The following is an example of a POST suppliers request response.
НТТР/1.1 201 ОК Date:Mon, 23 Dec 2019 09:56:10 UTC Content-Type: application/json Content-Length: 41
[{"status": "Supplier successfully created"}] |
Error responses
For more information about possible response statuses, see section "Response statuses".
An error response contains a JSON object with the error description.
[
{
"status": "An error occurred while creating some suppliers",
"reason": "%REASON%"
}
]
Error object properties are described in the following table.
Error object properties
Property |
Value |
Description |
---|---|---|
|
|
Error description. |
|
|
Cause of the error. |
Error response example
The following is an example of a POST suppliers error response.
ННТТР/1.1 400 Bad Request Date:Mon, 23 Dec 2019 09:56:10 UTC Content-Type: application/json Content-Length: 92
[{"status": "An error occurred while creating some suppliers", "reason": "Incorrect supplier name"}] |