{"uid":"cap_p3NVweEzIzDYPqR-usADK","slug":"one-engine-text-trim-e844c874","name":"ONE Engine Text Trim","description":"Low-cost pay-per-call utility APIs for autonomous agents using x402 on Base.","url":"https://one-search.one-engine.workers.dev/v1/text/trim?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string"}}},"responseSchema":{"type":"json","example":{"text":"hello"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.0009","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.0009/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0009","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0009","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_t3pp-EdBKWO_8mCk-MH6b","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0009","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Removes leading and trailing whitespace from a text string for clean downstream agent processing.","exampleAgentPrompt":"Can you trim the whitespace off the edges of this text for me: '   Hello, world!   '?","exampleUseCases":[{"title":"Cleaning scraped web content","prompt":"I just scraped some text from a webpage and it has a bunch of extra spaces and newlines at the start and end — can you trim it so it's clean before I pass it to the next step?"},{"title":"Normalizing user input before storage","prompt":"Before saving this user-submitted note to the database, trim any leading or trailing whitespace: '   Meeting scheduled for Monday.   '"},{"title":"Preprocessing text for LLM prompt","prompt":"I'm building a prompt from user input but the text has extra spaces around it — trim it so it doesn't mess up the formatting before I send it to the language model."}],"resultDescription":"A JSON object containing a single 'text' field with the trimmed version of the input string, with all leading and trailing whitespace removed.","failureModes":["Missing 'text' field in request body returns an error","Non-string value for 'text' may cause processing failure","Payment failure (402) if USDC balance is insufficient for the $0.0009 per-call fee","Empty string input returns an empty string with no error"],"whenToPreferThis":"Choose this endpoint when you need a simple, reliable, pay-per-call text trimming operation within an autonomous agent pipeline running on Base via x402, especially when you want minimal overhead and no authentication setup beyond micropayment.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T12:44:14.224Z","isFirstParty":false,"canonicalSlug":"one-engine-text-trim-3b82473d"}