Api Endpoint

HALOWERK Agent Tools

Builds the cohort table from the events you pass: users grouped by the period of their first event, counted again in each following period. Returns the table per cohort, a retention curve across all cohorts, and, where events carry a value, cumulative value and value per user. The curve counts only cohorts old enough for a given period, so a young cohort is not scored as churn. Day, week and month are real calendar periods. Nothing is fetched, nothing is stored.

Open interactive test console

Offering

Provider
tools.halowerk.com
Method
POST
Offering type
Api Endpoint
Transport type
http
Category
Data
Delivery
Not provided
Pricing model
Not provided
x402 version
2

Endpoint context

URL
https://tools.halowerk.com/v1/cohort/retention
MIME type
application/json
First seen
2026-10-16T01:50:10.647Z
Last seen
Tags
X402, agent-tools, Analysis, cohort_retention

Payment pricing

x402 payment terms are the authoritative price for calling this endpoint.

Payment option 1
0.002 USDC
Atomic price: 2000 · Network: eip155:8453 · Asset: USDC · Scheme: exact
Raw x402 terms
[
  {
    "scheme": "exact",
    "network": "eip155:8453",
    "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "amount": "2000",
    "payTo": "0x2880EdfFF13100677Bf97A3CBdF3Bc34771C4E5E"
  }
]

Observed health

Status
Healthy
Latest latency
316 ms
Average latency
692 ms
HTTP status
204
Last checked
Reachability
100% over 9 checks

Latency is measured to the first response headers. A reachable result does not verify response accuracy or merchant identity.

Input schema

{
  "type": "object",
  "properties": {
    "type": {
      "type": "string",
      "const": "http"
    },
    "method": {
      "type": "string",
      "enum": [
        "POST"
      ]
    },
    "bodyType": {
      "type": "string",
      "enum": [
        "json",
        "form-data",
        "text"
      ]
    },
    "body": {
      "type": "object",
      "required": [
        "events"
      ],
      "properties": {
        "events": {
          "type": "array",
          "minItems": 1,
          "maxItems": 4000,
          "description": "Each event needs user_id and a timestamp (time_unix_s in seconds since 1970, or time as ISO 8601). Optional: type and value. Any other field name is rejected rather than guessed. The service caps the whole request body at 256 KB, so long records reach that limit before maxItems."
        },
        "period": {
          "type": "string",
          "enum": [
            "day",
            "week",
            "month"
          ],
          "default": "week"
        },
        "periods": {
          "type": "integer",
          "minimum": 1,
          "maximum": 52,
          "default": 12,
          "description": "How many periods the table runs, period 0 being the entry period."
        },
        "week_start": {
          "type": "string",
          "enum": [
            "monday",
            "sunday"
          ],
          "default": "monday"
        },
        "timezone_offset_s": {
          "type": "integer",
          "minimum": -50400,
          "maximum": 50400,
          "default": 0,
          "description": "Offset from UTC in seconds used to place period boundaries."
        },
        "activation_type": {
          "type": "string",
          "maxLength": 120,
          "description": "If set, only events of this type put a user into a cohort. Without it the first event of any type counts."
        },
        "retention_types": {
          "type": "array",
          "maxItems": 50,
          "items": {
            "type": "string"
          },
          "description": "If set, only events of these types count as being active. Without it every event counts."
        }
      }
    }
  },
  "required": [
    "type",
    "method",
    "bodyType",
    "body"
  ],
  "additionalProperties": false
}

Output schema

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "input": {
      "additionalProperties": false,
      "properties": {
        "body": {
          "properties": {
            "activation_type": {
              "description": "If set, only events of this type put a user into a cohort. Without it the first event of any type counts.",
              "maxLength": 120,
              "type": "string"
            },
            "events": {
              "description": "Each event needs user_id and a timestamp (time_unix_s in seconds since 1970, or time as ISO 8601). Optional: type and value. Any other field name is rejected rather than guessed. The service caps the whole request body at 256 KB, so long records reach that limit before maxItems.",
              "maxItems": 4000,
              "minItems": 1,
              "type": "array"
            },
            "period": {
              "default": "week",
              "enum": [
                "day",
                "week",
                "month"
              ],
              "type": "string"
            },
            "periods": {
              "default": 12,
              "description": "How many periods the table runs, period 0 being the entry period.",
              "maximum": 52,
              "minimum": 1,
              "type": "integer"
            },
            "retention_types": {
              "description": "If set, only events of these types count as being active. Without it every event counts.",
              "items": {
                "type": "string"
              },
              "maxItems": 50,
              "type": "array"
            },
            "timezone_offset_s": {
              "default": 0,
              "description": "Offset from UTC in seconds used to place period boundaries.",
              "maximum": 50400,
              "minimum": -50400,
              "type": "integer"
            },
            "week_start": {
              "default": "monday",
              "enum": [
                "monday",
                "sunday"
              ],
              "type": "string"
            }
          },
          "required": [
            "events"
          ],
          "type": "object"
        },
        "bodyType": {
          "enum": [
            "json",
            "form-data",
            "text"
          ],
          "type": "string"
        },
        "method": {
          "enum": [
            "POST"
          ],
          "type": "string"
        },
        "type": {
          "const": "http",
          "type": "string"
        }
      },
      "required": [
        "type",
        "method",
        "bodyType",
        "body"
      ],
      "type": "object"
    },
    "output": {
      "properties": {
        "example": {
          "type": "object"
        },
        "type": {
          "type": "string"
        }
      },
      "required": [
        "type"
      ],
      "type": "object"
    }
  },
  "required": [
    "input"
  ],
  "type": "object"
}