{"uid":"cap_ib4hnxNm27p6MnCotAd2T","slug":"vextorium-regex-test-api-c79901d8","name":"Vextorium Regex Test API","description":"232 pay-per-call data APIs for AI agents: official statistics and economy (ECB, Fed, Eurostat, World Bank, SEC, BOE, INE), crypto prices and sentiment, Spanish public data, compliance (sanctions, VAT, IBAN, LEI), science, weather, web and developer tools and local AI text tools. Pay in USDC via x402.","url":"https://api.vextorium.com/v1/regex-test?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string"},"flags":{"type":"string"},"pattern":{"type":"string"},"max_matches":{"type":"integer"},"replacement":{"type":"string"}}},"responseSchema":{"type":"json","example":{"flags":null,"matches":[{"end":9,"text":"ana@x.com","start":0,"groups":["ana","x.com"],"named_groups":{"dom":"x.com","user":"ana"}},{"end":22,"text":"luis@y.org","start":12,"groups":["luis","y.org"],"named_groups":{"dom":"y.org","user":"luis"}}],"pattern":"(?P<user>\\w+)@(?P<dom>[\\w.]+)","is_match":true,"group_names":["user","dom"],"num_matches":2,"defined_groups":2,"substitution_result":null}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","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.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_MIeG77XnzWrG5kLyl9N-0","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Tests a regular expression against text, returning all matches with positions, capture groups, named groups, and optional substitution result","exampleAgentPrompt":"Test the regex pattern (?P<user>\\w+)@(?P<dom>[\\w.]+) against the text 'contact ana@x.com or luis@y.org for info' and show me all matches with their named groups and positions.","exampleUseCases":[{"title":"Email extraction from free text","prompt":"Run the pattern (?P<user>[\\w.+-]+)@(?P<domain>[\\w-]+\\.[\\w.]+) against this text: 'Reach out to sales@company.com or support@help.io' — I want every match with the user and domain named groups shown separately."},{"title":"Regex substitution preview","prompt":"Test the pattern (\\d{3})-(\\d{4}) on the string 'Call 555-1234 or 555-9876' with the replacement ***-\\2, and show me what the substituted string looks like along with all matches."},{"title":"Multiline pattern validation","prompt":"Check whether the pattern ^ERROR:\\s+(.+)$ with the m and i flags matches anything in this log: 'INFO: started\\nError: disk full\\nDEBUG: ok' and list every matched line with capture group text."}],"resultDescription":"A JSON object containing: whether any matches were found (matches bool), total match count (num_matches), list of match objects each with start/end character positions, matched text, ordered capture groups array, named capture groups object, plus the group_names list and substitution_result string if a replacement was provided.","failureModes":["Pattern causes catastrophic backtracking — endpoint enforces a time limit and returns a timeout/error","Invalid regex syntax in pattern field — returns an error describing the syntax problem","Missing required fields (pattern or text) — returns a validation error","Unsupported flag character supplied — returns an error listing valid flags (i, m, s, x)","Empty text or pattern — may return matches:false with num_matches:0"],"whenToPreferThis":"Choose this endpoint when you need server-side regex execution with guaranteed safety against ReDoS (catastrophic backtracking), especially when running untrusted or complex patterns. It is preferable over client-side regex when you need structured output (positions, named groups, substitution result) in a single API call, or when the agent environment does not support native regex execution.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-19T12:45:59.993Z","isFirstParty":false,"canonicalSlug":"vextorium-regex-test-api-c79901d8"}