Custom Metrics by CUIT
API Reference
Custom Metrics by CUIT
Incremental CBU/CVU metrics over a custom calendar lookback (1–180 days) — billable per request when priced.
GET
Custom Metrics by CUIT
Overview
Returns custom incremental metrics for a calendar lookback ending on a reference date: deltas, % change, daily variance, and acceleration when enough history exists. One billable request per successful call when priced.Endpoint
Path parameters
Argentina CUIT/CUIL — 11 digits, no dashes.
Query parameters
Calendar days in the window (1–180, inclusive).
Optional. Inclusive window end (
YYYY-MM-DD). Defaults to latest corpus date when omitted.Success response (HTTP 200)
trueAlways
true on success.Echo of requested lookback.
Inclusive window end (
YYYY-MM-DD).Window start date (
YYYY-MM-DD).Window end date (
YYYY-MM-DD), same as reference date.cbuTotalStart,cbuTotalEnd,cvuTotalStart,cvuTotalEnd(numbers)cbuDelta,cvuDelta(numbers)cbuPctChange,cvuPctChange(number | null)daysWithChanges(number)cbuDailyDeltaVariance,cvuDailyDeltaVariance(number | null)cbuAcceleration,cvuAcceleration,totalAcceleration(number | null)accelerationAvailable(boolean) — whenfalse, acceleration fields arenull
Incomplete window (HTTP 422)
When incremental state cannot satisfy the lookback, the API returnssuccess: false with a partial data payload:
error.code | Meaning |
|---|---|
INCOMPLETE_WINDOW | Missing daily snapshots in the requested range (missingDates may be listed) |
NO_INCREMENTAL_STATE | No incremental history for this CUIT |
Other errors
| HTTP | error.code | When |
|---|---|---|
| 400 | INVALID_LOOKBACK | lookback missing or outside 1–180 |
| 400 | INVALID_DATE | Malformed date |
| 404 | CUIT_NOT_FOUND | CUIT not in corpus |
| 402 | INSUFFICIENT_BALANCE | Credits or pack exhausted |
| 503 | SERVICE_UNAVAILABLE | Holder backend unavailable |
| 500 | INTERNAL_ERROR | Unexpected error |
Example
Rules engine
Metrics conditions requireholderIntelligenceLookbackDays (1–180) on the rule condition.
| API / block field | Rule field (examples) |
|---|---|
metrics.cbuAcceleration | services.holder_intelligence.metrics.cbu_acceleration |
metrics.cbuPctChange | services.holder_intelligence.metrics.cbu_pct_change |
metrics.totalAcceleration | services.holder_intelligence.metrics.total_acceleration |
complete | services.holder_intelligence.metrics.complete |
transactedAt converted to Argentina calendar date unless you set holderIntelligenceReferenceDateField on the condition.
See Rules conditions.