# Strale Prompt Compress

> Strale Prompt Compress is a paid API for AI agents from api.strale.io, paid per call via x402, $0.0324/call, status unknown (last checked 2026-09-14).

Compresses a prompt text by a target percentage to reduce token usage while preserving meaning

## Facts

- Endpoint: GET https://api.strale.io/x402/v2/prompt-compress
- Price: $0.0324/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/strale-prompt-compress-9df7408b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ISxEhN-mwm8ESKviS-Jdn

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 strale-prompt-compress-9df7408b
```

Example prompt: Can you compress this prompt text by 30% to reduce my token usage: 'You are a helpful assistant. Your job is to answer questions accurately and concisely. When the user asks something, you should think carefully before responding and make sure your answer is well-reasoned and grounded in facts.'

## When to prefer this

Choose this endpoint when you need to reduce token consumption of LLM prompts at inference time, especially in high-volume or cost-sensitive pipelines. It is preferable to manual summarization when you want deterministic compression with a target percentage and an auditable, cryptographically-hashed record of the transformation. Particularly useful for agents that repeatedly send long system prompts or few-shot examples to expensive LLM APIs.

## Known failure modes

- Missing required prompt_text parameter returns a 400 validation error
- target_reduction_percent outside a valid range may return an error or be clamped to defaults
- Very short input prompts may not compress meaningfully or return unchanged text
- Prompt content that is already highly compressed may yield less than the target reduction
- Payment failure or insufficient USDC balance returns a 402 Payment Required response

## How this service works

The trust layer for AI agents — 250+ independently tested data capabilities across 27 countries. Execute capabilities via REST, MCP, A2A, or x402 micropayments. Every call returns an audit record with cryptographic chain hashing.

## Output

Returns a compressed version of the input prompt text with reduced character/token count at approximately the requested reduction percentage, preserving semantic meaning and key instructions. The response includes an audit record with cryptographic chain hashing per Strale's trust layer standard.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "prompt_text"
     ],
     "properties": {
      "prompt_text": {
       "type": "string"
      },
      "target_reduction_percent": {
       "type": "integer",
       "description": "Default 30"
      }
     }
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/strale-prompt-compress-9df7408b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.strale.io](https://www.zero.xyz/host/api.strale.io/llms.txt)
