{"uid":"cap_H1EXjSuW0kFweRU3mYBfZ","slug":"after-6-labo-x402-text-stats-4b12734f","name":"After 6 Labo x402 Text Stats","description":"Deterministic Japanese text utilities for AI agents, paid per call with x402 (USDC on Base): Unicode/Japanese script text statistics, and a Japanese bank-transfer name (Zengin halfwidth kana) format check with reviewable correction candidates.","url":"https://after6labo-x402.silly-detective.workers.dev/paid/text-stats?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"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"],"type":"string"},"queryParams":{"type":"object","required":["text"],"properties":{"text":{"type":"string","maxLength":2048,"minLength":1,"description":"Text to analyze. UTF-8 URL-encode it as the text query parameter."}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","properties":{"lines":{"type":"integer"},"utf8Bytes":{"type":"integer"},"hanCodePoints":{"type":"integer"},"utf16CodeUnits":{"type":"integer"},"asciiCodePoints":{"type":"integer"},"unicodeCodePoints":{"type":"integer"},"hiraganaCodePoints":{"type":"integer"},"katakanaCodePoints":{"type":"integer"}}}}}}},"responseSchema":{"type":"json","example":{"ok":true,"paid":true,"lines":1,"utf8Bytes":23,"hanCodePoints":3,"utf16CodeUnits":11,"asciiCodePoints":5,"unicodeCodePoints":11,"hiraganaCodePoints":3,"katakanaCodePoints":0}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_UBlsUHzK-q8C3bVvNHX4H","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns deterministic Unicode text statistics (byte counts, code point counts by script, line counts) for a given UTF-8 string, billed via x402 micropayment.","exampleAgentPrompt":"Can you get me the full Unicode stats for the text 'Hello, 世界! こんにちは' — I need byte counts, code point counts, and how many Han, hiragana, and katakana characters it contains?","exampleUseCases":[{"title":"Validate multilingual user input size","prompt":"I need to check how many UTF-8 bytes and Unicode code points are in this user-submitted string before I store it in the database: 'Привет мир, こんにちは世界, Hello!'"},{"title":"Audit CJK character distribution","prompt":"Can you analyze this mixed Japanese text and tell me exactly how many Han characters, hiragana, and katakana code points it contains: '東京都はきれいな街です。アニメが好き。'"},{"title":"Check ASCII-only content ratio","prompt":"I have this string and want to know how many of its characters are plain ASCII versus full Unicode code points: 'Café au lait costs $3.50 — très bien!'"}],"resultDescription":"A JSON object with integer counts for: utf8Bytes, unicodeCodePoints, utf16CodeUnits, asciiCodePoints, hanCodePoints, hiraganaCodePoints, katakanaCodePoints, and lines. All values are deterministic for a given input string.","failureModes":["Missing 'text' query parameter returns an error","Text exceeding 2048 characters (maxLength) is rejected","Non-UTF-8 encoded text may produce unexpected counts","x402 payment failure blocks the request before processing","Empty string (minLength 1) is rejected"],"whenToPreferThis":"Choose this endpoint when you need fast, deterministic, script-aware Unicode statistics — especially for CJK (Han, hiragana, katakana) character counting — and want to pay per-call via x402 micropayment without API key setup. Prefer it over rolling your own Unicode parser when you need authoritative byte and code-unit counts across encodings (UTF-8, UTF-16) in a single call.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-13T00:35:28.412Z","isFirstParty":false,"canonicalSlug":"after-6-labo-x402-text-stats-4b12734f"}