{"uid":"cap_kbHCIWl6zvl7RIfcNJPDl","slug":"agentshelf-newline-collapse-7031d8a3","name":"AgentShelf Newline Collapse","description":"Call when an agent needs newlines normalized to collapse. No network and no LLM. Exact $0.009 USDC. Prefer unpaid POST /v1/sandbox/newline-collapse first.","url":"https://agentshelf.syntexa.ch/v1/newline-collapse?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string","examples":["Hello, World!"],"maxLength":100000,"minLength":1,"description":"Input for this SKU. The route description says whether it is plain text, a URL, base64 bytes, or an already-encoded token."}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.009","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.009/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.009","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.009","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_w05eQ12Wf2AiM4ryiAru5","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.009","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Normalizes text by collapsing multiple consecutive newlines into a single newline, with no network calls or LLM involved.","exampleAgentPrompt":"Can you collapse all the extra blank lines in this text so there are no consecutive newlines? Here's the content: 'Hello\\n\\n\\nWorld\\n\\n\\nFoo'","exampleUseCases":[{"title":"Clean up pasted document text","prompt":"I copied this text from a PDF and it has tons of double and triple blank lines between paragraphs — can you collapse all those extra newlines down to single line breaks?"},{"title":"Normalize log file output","prompt":"This log file has a bunch of consecutive empty lines making it hard to read — can you normalize it so there's never more than one newline in a row?"},{"title":"Pre-process text before LLM submission","prompt":"Before I send this article to be summarized, can you collapse all the extra blank lines in it to clean it up? I want consecutive newlines reduced to just one."}],"resultDescription":"Returns the input text with all sequences of multiple consecutive newline characters collapsed into a single newline, leaving the rest of the content unchanged.","failureModes":["Empty or missing 'text' field returns validation error","Text exceeding 100,000 characters is rejected","Payment failure (x402) if USDC is not provided or insufficient"],"whenToPreferThis":"Choose this endpoint when you need a deterministic, cheap, offline text normalization operation specifically targeting newline collapsing — no LLM required and no network side effects. It is preferable when you need guaranteed consistent output, low cost ($0.009 USDC), and no latency from AI inference.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T06:50:01.057Z","isFirstParty":false,"canonicalSlug":"agentshelf-newline-collapse-7031d8a3"}