{"uid":"cap_3I_6c5txcy8avrll8rdJl","slug":"number-theory-gcd-7f4cf1be","name":"Number Theory GCD","description":"Greatest common divisor of two or more non-negative integers (arbitrary precision).","url":"https://numtheory.openverbs.com/v1/gcd","method":"POST","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method","bodyType","body"],"properties":{"body":{"type":"object","required":["values"],"properties":{"values":{"type":"array","items":{"type":"string","pattern":"^\\d+$"},"maxItems":256,"minItems":2,"description":"Two or more non-negative integers as decimal strings."}},"additionalProperties":false},"type":{"type":"string","const":"http"},"method":{"enum":["POST"],"type":"string"},"bodyType":{"enum":["json","form-data","text"],"type":"string"}},"additionalProperties":false}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.004","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.004/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_9FfIgITVjLHIYtF9yXKhx","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.004","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Computes the Greatest Common Divisor (GCD) of two or more non-negative integers supplied as decimal strings.","exampleAgentPrompt":"Can you find the greatest common divisor of 252, 180, and 48?","exampleUseCases":[{"title":"Simplify a fraction automatically","prompt":"I have the fraction 144 over 960 — what's the GCD of 144 and 960 so I can reduce it to lowest terms?"},{"title":"Find shared divisor for scheduling","prompt":"Tasks repeat every 120 minutes, 90 minutes, and 75 minutes — what's the GCD of those three numbers so I can find the shortest common cycle?"},{"title":"Cryptography key size validation","prompt":"I'm working on an RSA implementation and need to verify that the GCD of 17 and 3120 is 1 to confirm they're coprime — can you check that?"}],"resultDescription":"Returns the computed GCD as a single non-negative integer — the largest integer that divides all provided input values without remainder. Accepts between 2 and 256 integers passed as decimal strings.","failureModes":["Fewer than 2 values provided — validation error","Non-numeric or non-decimal-string values — schema validation failure","Values exceeding 256 items in the array — rejected by maxItems constraint","Negative integers or non-integer strings — pattern mismatch rejection","Network or payment authorization failure via x402 protocol"],"whenToPreferThis":"Choose this endpoint when you need a reliable, hosted computation of the GCD for 2–256 non-negative integers, especially in agent workflows requiring number-theory operations without spinning up local math libraries. Useful for fraction simplification, scheduling period calculations, and coprimality checks in cryptographic contexts.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T12:34:22.265Z","isFirstParty":false}