{"uid":"cap_Z8ohgv4qo2wgnVvSz1dWg","slug":"2s-regex-test-311dc26a","name":"2s Regex Test","description":"The (most) everything API: 575+ pay-per-call endpoints for AI agents — ground-truth data, a full AI gateway, and agent infrastructure (storage, queues, watchers). USDC via x402, no signup, no API keys, and upto billing: pay actual usage, not the quote.","url":"https://2s.io/api/dev/regex-test?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"flags":{"type":"string","maxLength":8},"input":{"type":"string","maxLength":50000},"pattern":{"type":"string","maxLength":1000,"minLength":1}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.0025","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.0025/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0025","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0025","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_eZQoqbmcwB6_V7Lrp3UYx","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0025","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Tests whether a regular expression pattern matches against an input string, with optional regex flags","exampleAgentPrompt":"Test whether the regex pattern ^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\\.[a-zA-Z]{2,}$ matches the string 'user@example.com', using case-insensitive flag 'i'.","exampleUseCases":[{"title":"Email format validation","prompt":"Check if the regex ^[\\w.+-]+@[\\w-]+\\.[a-zA-Z]{2,}$ matches the string 'john.doe@gmail.com' — I want to know if it's a valid email format."},{"title":"URL pattern debugging","prompt":"Test whether my regex pattern ^https?:\\/\\/([\\w-]+\\.)+[\\w-]+(\\/[^\\s]*)?$ matches the string 'https://www.example.com/path/to/page' so I can verify my URL validator is working."},{"title":"Case-insensitive keyword detection","prompt":"Does the regex pattern \\berror\\b match the log line 'ERROR: Connection timeout on port 443' when using the case-insensitive flag 'i'?"}],"resultDescription":"Returns whether the pattern matched the input string, along with any captured groups, the index of the match, and the full matched substring if a match was found.","failureModes":["Invalid regex pattern syntax returns an error","Pattern or input exceeding character limits rejected","Unsupported flag characters cause validation error","Empty pattern rejected due to minLength constraint"],"whenToPreferThis":"Use this endpoint when you need a quick, pay-per-call regex test without setting up a runtime environment — ideal for agents validating user input formats, debugging regex patterns on the fly, or extracting capture groups from strings without executing code locally.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-12-03T12:53:00.385Z","isFirstParty":false,"canonicalSlug":"2s-regex-test-311dc26a"}