Cerus Markets – API Documentation

Welcome to the official Cerus Markets API documentation page.
Below you’ll find how to obtain an authorization token and use the available endpoints.

Getting an Authorization Token (GET /v2/auth/user/create)

You can obtain an Authorization Token by sending a GET request with your username, email, and password as query parameters. (Note: This still points to the api.cerusmarket.com endpoint.)
For token creation using command prompt (CMD) is recommended, as third-party programs may cause errors due to incompatibility.

Example:

curl "https://api.cerusmarkets.com/v2/auth/create?username=johndoe&email=user@example.com&password=mySecurePassword&leads=true&v=54"

Example JSON Response:

{
  "status": "success",
  "token": "YOUR_API_TOKEN"
}

Use this returned token in all subsequent requests as a Bearer Token in the Authorization header.

Authorization Header

Include the token in every request header:

Authorization: Bearer YOUR_API_TOKEN

1. Submit a Lead (POST /api/affiliates/v2/leads)

This endpoint allows you to send a lead to the system. If your token is valid, the lead will be registered successfully.

POST Request: POST /api/affiliates/v2/leads

Required JSON Body Fields:

  • phone (string)
  • firstName (string)
  • lastName (string)
  • email (string)
  • deposit (number)
  • depositDate (string in YYYY-MM-DD format)

Example cURL Request:

curl -X POST "https://api.cerusmarket.com/api/affiliates/v2/leads" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d "{ \"phone\": \"+123456789\", \"firstName\": \"John\", \"lastName\": \"Doe\", \"email\": \"john@example.com\", \"deposit\": 2500, \"depositDate\": \"2025-03-01\" }"

Example JSON Response (on success):

{
  "status": "success",
  "message": "Lead accepted"
}

If the token is missing or invalid, a 401 status with an error message will be returned.

2. Get Goal Types (GET /api/affiliates/v2/goal-types)

This endpoint returns the goal types available in the system.

GET Request: GET /api/affiliates/v2/goal-types

Example cURL Request:

curl -X GET "https://api.cerusmarket.com/api/affiliates/v2/goal-types" \
  -H "Authorization: Bearer YOUR_API_TOKEN"

Example JSON Response:

{
  "status": "success",
  "data": [
    {
      "uuid": "78c6ff24-4373-4164-af9f-7e0207fec1d6",
      "name": "Pushed Lead"
    },
    {
      "uuid": "9890dd68-6776-46d5-a845-603d7c8f8fbe",
      "name": "FTD"
    }
  ]
}

HTTP Status Codes

All requests return standard HTTP status codes:

  • 200 OK – The request was successful.
  • 400 Bad Request – Missing or invalid parameters.
  • 401 Unauthorized – Missing or incorrect token.
  • 500 Internal Server Error – A server error occurred.