{"uid":"cap_cYXEDYBPODltpBs5b4Wbv","slug":"energybilltoolkit-co-uk-62484e2f","name":"energybilltoolkit.co.uk Text Metrics Count","description":"Return deterministic structural counts: characters, words, sentences, paragraphs, headings, bullets, and averages.","url":"https://energybilltoolkit.co.uk/text-metrics/api/tools/count-text","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string","description":"Text to measure."}}},"responseSchema":null,"example":{"request":{"text":"Energy bills have risen sharply this year. Households face record costs. Below are the main causes: • Wholesale gas prices • Supply chain disruption. What can you do? Consider switching tariffs or insulating your home."},"response":{"counts":{"lines":1,"words":33,"headings":0,"sentences":5,"characters":218,"paragraphs":1,"bullet_items":0,"unique_words":33,"non_empty_lines":1,"characters_no_spaces":184,"average_words_per_sentence":6.6,"average_words_per_paragraph":33},"metric":"counts","warnings":[{"code":"short_text","message":"Readability and frequency metrics are unstable below about 100 words.","severity":"caution"}]}},"exampleRequest":{"text":"Energy bills have risen sharply this year. Households face record costs. Below are the main causes: • Wholesale gas prices • Supply chain disruption. What can you do? Consider switching tariffs or insulating your home."},"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","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.01/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_uvesOhcJafpNeNuFfNJ5p","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 structural counts for a given text: characters, words, sentences, paragraphs, headings, bullets, and computed averages.","exampleAgentPrompt":"Can you count the words, sentences, paragraphs, headings, and bullets in this text for me: 'Energy bills have risen sharply this year. Households face record costs. Below are the main causes: • Wholesale gas prices • Supply chain disruption. What can you do? Consider switching tariffs or insulating your home.'","exampleUseCases":null,"resultDescription":"A JSON object containing deterministic structural counts including total characters, words, sentences, paragraphs, headings, and bullets, along with computed averages such as average words per sentence and average sentence length.","failureModes":["Empty or missing text body returns an error or zero counts","Extremely large text payloads may time out or be rejected","Malformed request body (not valid JSON) returns a 400 error","Non-text binary content may return unexpected zero counts"],"whenToPreferThis":"Use this endpoint when you need fast, deterministic, rule-based structural counts of text — not probabilistic NLP analysis. Prefer this over AI-based text analysis when you need reproducible, exact counts of document structure elements like headings, bullets, sentences, and paragraphs.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T06:30:32.101Z","isFirstParty":false}