# Truthy Count Utility

> Truthy Count Utility is a paid API for AI agents from creator-desk-x402-isolated.onrender.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-12).

Counts the number of truthy values in a given input value or collection, returning the total count and operation name.

## Facts

- Endpoint: POST https://creator-desk-x402-isolated.onrender.com/v1/utility/truthy-count?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/truthy-count-utility-6ed7bc24
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_mrDUEJSu1d72ST4O0ArsE

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability truthy-count-utility-6ed7bc24 -d '<json body>'
```

Example prompt: Count how many truthy values are in this array for me: [1, 0, null, 'hello', false, 42, '', undefined] — I need the total number of items that evaluate to true.

## When to prefer this

Use this endpoint when you need a lightweight, pay-per-call computation to count truthy values in arbitrary data structures without setting up your own evaluation logic. Best suited for autonomous agents needing on-demand boolean aggregation over small to medium collections at low cost ($0.01 USDC per call).

## Known failure modes

- Missing or malformed 'value' input may return an error or unexpected count
- Payment failure via x402 protocol results in 402 response blocking execution
- Deeply nested or very large inputs may produce unexpected results depending on traversal depth
- Options object misuse may alter counting behavior unpredictably

## How this service works

Machine-callable x402-paid utilities for autonomous agents.

## Output

Returns a JSON object with a 'result' field containing the count of truthy values found in the input, and an 'operation' field confirming this was a 'truthy_count' operation.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "value": {},
  "options": {
   "type": "object"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "result": "example",
  "operation": "truthy_count"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/truthy-count-utility-6ed7bc24/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from creator-desk-x402-isolated.onrender.com](https://www.zero.xyz/host/creator-desk-x402-isolated.onrender.com/llms.txt)
