Support – API Documentation

Authentication

Every endpoint requires authentication. You must pass your API key via the API-KEY header along with your requests.

Example with curl:

:::bash
curl --header 'API-KEY: abcdefghijklmnopqrstuv' https://analyzer.cryptosense.com/api/projects

Projects

GET /projects
Response:

:::json
{
  "projects": [
    {
      "id": "",
      "name": ""
    }
  ]
}

Traces

POST /trace_s3_post
This returns a signed request that must be used to upload the trace to the Cryptosense S3 bucket.

Response:

:::json
{
  "fields": {
    "AWSAccessKeyId": "",
    "acl": "private",
    "key": "",
    "policy": "",
    "signature": "",
    "success_action_status": 201
  },
  "url": "https://cryptosense.s3.amazonaws.com/"
}

GET /project//traces

Response:

:::json
{
  "traces": [
    {
      "id": "",
      "name": "",
      "size": ""
    }
  ]
}

POST /projects//traces
This adds a trace to a project. The trace must already have been uploaded to the S3 URL returned by the /trace_s3_post endpoint.

Request parameters:

name: Name of the trace
key: Key of the trace as returned by /trace_s3_post
size: Size of the trace in octets

Response:

:::json
{
  "trace_id": ""
}

GET /traces/
Response:

:::json
{
  "trace": {
    "name": "",
    "state": "",
    "size": ""
  }
}

trace_state can be progress, done or failed depending on whether its examination is in progress, finished and successful, or finished and unsuccessful.

Analysis

POST /analyze
Launches an analysis.

Request parameters:

trace_id: ID of the trace in an accessible project
profile_id: ID of a profile in the same project
report_name: Name of the report
Response:

:::json
{
  "report_id": ""
}

Reports

GET /project//reports
Response:

:::json
{
  "reports": [
    {
      "id": "",
      "name": "",
      "state": ""
    }
  ]
}

report_state can be progress, done or failed depending on whether the analysis is in progress, finished and successful, or finished and unsuccessful.

GET /reports/
Response, if the report still being created:

:::json
{
  "report": {
     "state": "progress"
  }
}

Response, if the report is ready:

:::json
{
  "report": {
    "state": "done",
    "result": {

    }
}

Try a Free 14-day Trial

Cryptosense Analyzer audits your applications and infrastructure to find vulnerabilities and understand your crypto landscape. Use it to optimise bug-fix resources and demonstrate compliance.