CyberHoot API

Overview

The CyberHoot API is available to our partners. It is organized around REST. It uses standard HTTP response codes, accepts form-encoded request bodies, and returns JSON-encoded responses.

Authentication

All API requests require a valid API Key. The Items API uses HTTP Basic Auth. Provide your API Key as the basic auth username value in the request Authentication header (You don’t need to provide a password). Your API Key can be found under MSP Settings in your CyberHoot deployment. You can also generate a new API Key here (Note this will make your current API Key invalid).

To authenticate to the Items API you must provide your API Key in the Basic Authorization header of your HTTP request. All API requests must be made over HTTPS. Calls made over HTTP will fail and API requests without authentication will also fail.

curl https://<DEPLOYMENT_SUBDOMAIN>.cyberhoot.com/api/customers/ \
  -u <API_KEY>:
# The colon prevents curl from asking for a password.
# Replace <DEPLOYMENT_SUBDOMAIN> with your deployment subdomain
# Replace <API_KEY> with your API Key

Status Codes

The CyberHoot API utilizes the following HTTP Status Codes in its responses.

Status Code

Description

200

OK

400

Bad Request

401

Unauthorized

404

Not Found

500

Internal Server Error

Errors

The CyberHoot API returns errors in this format along with the corresponding HTTP Status Code.

{
  "error" : string,
  "error_description" : string
}
# error = short code of error(s) that occurred
# error description = details of error(s) that occurred

API Endpoints

Get Customers

Returns a list of customers.

Request Method

Endpoint

GET

https://<DEPLOYMENT_SUBDOMAIN>.cyberhoot.com/api/customers/

Parameter

Required

Data Type

Details

limit

Optional

Integer

Limit number of customers returned. Max of 1,000, default is 100.

starting_after

Optional

Integer

Id of customer to start pulling customers after. Used for pagination.

Example:

curl https://<DEPLOYMENT_SUBDOMAIN>.cyberhoot.com/api/customers/ \
  -u <API_KEY>: \
  -d limit=10 \
  -G

Get Customer

Returns a specific customer.

Request Method

Endpoint

GET

https://<DEPLOYMENT_SUBDOMAIN>.cyberhoot.com/api/customers/?id=:id

Parameter

Required

Data Type

Details

id

Required

Integer

Id of the customer to return.

Example:

curl https://<DEPLOYMENT_SUBDOMAIN>.cyberhoot.com/api/customers/ \
  -u <API_KEY>: \
  -d id=1000 \
  -G

Find out how CyberHoot can secure your business.