{"uid":"cap_lJjMrFDEkNxhPKEcSaFl6","slug":"otp-provisioning-uri-builder-ea807bce","name":"OTP Provisioning URI Builder","description":"Build an otpauth:// provisioning URI (the string encoded in authenticator QR codes) for a totp or hotp secret. Includes label, issuer, algorithm, digits and period (totp) or counter (hotp). The secret must be valid base32.","url":"https://otp.openverbs.com/v1/uri","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":["label","secret"],"properties":{"type":{"enum":["totp","hotp"],"type":"string","description":"OTP type. Default totp."},"label":{"type":"string","maxLength":128,"minLength":1,"description":"Account label, e.g. 'Example:alice@example.com'."},"digits":{"type":"integer","maximum":10,"minimum":6,"description":"Number of code digits. Default 6."},"issuer":{"type":"string","maxLength":128,"minLength":1,"description":"Issuer/provider name."},"period":{"type":"integer","maximum":86400,"minimum":1,"description":"Time step (totp only). Default 30."},"secret":{"type":"string","maxLength":1024,"minLength":1,"description":"Base32-encoded shared secret."},"counter":{"type":"integer","minimum":0,"description":"Initial counter (required for hotp)."},"algorithm":{"enum":["SHA1","SHA256","SHA512"],"type":"string","description":"HMAC algorithm. Default SHA1."}},"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_vwVQ3-UYzhFtVTrEvwL3T","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":"Builds an otpauth:// URI (used in authenticator QR codes) for a given TOTP or HOTP secret, with label, issuer, algorithm, digits, and period/counter.","exampleAgentPrompt":"Build an otpauth:// provisioning URI for a TOTP secret — the label is 'Acme:alice@acme.com', the issuer is 'Acme', the base32 secret is 'JBSWY3DPEHPK3PXP', use SHA1, 6 digits, and a 30-second period.","exampleUseCases":[{"title":"2FA QR code for new user signup","prompt":"Generate an otpauth:// TOTP URI so I can show a QR code during onboarding — label it 'MyApp:bob@example.com', issuer is 'MyApp', the base32 secret is 'KRUGKIDROVUWG2ZAMJZG653OEBTG66BANJ2W24DTEBXXMZLSEB2GQZJANRQXU6JAMRXWO', use SHA1, 6 digits, and 30-second period."},{"title":"HOTP setup for hardware token","prompt":"I need an otpauth:// HOTP URI for a hardware token — label it 'CorpVPN:charlie@corp.com', issuer 'CorpVPN', base32 secret is 'MFRA', starting counter is 0, SHA1 algorithm, and 6 digits."},{"title":"Custom authenticator with SHA256 and 8 digits","prompt":"Build an otpauth TOTP URI for my authenticator setup with label 'SecureBank:dave@bank.com', issuer 'SecureBank', base32 secret 'JBSWY3DPEHPK3PXP', SHA256 algorithm, 8 digits, and a 60-second time step."}],"resultDescription":"Returns an otpauth:// URI string (e.g. otpauth://totp/Example%3Aalice%40example.com?secret=JBSWY3D...&issuer=Example&algorithm=SHA1&digits=6&period=30) ready to be encoded into a QR code or used by an authenticator app.","failureModes":["Invalid base32 secret returns a 400 error","Missing required fields (label or secret) returns validation error","Counter missing for HOTP type returns error","Algorithm value outside SHA1/SHA256/SHA512 enum rejected","Digits outside 6-10 range rejected","Period outside 1-86400 range rejected","Payment not completed returns 402 Payment Required"],"whenToPreferThis":"Use this endpoint when you need to construct a standards-compliant otpauth:// URI for display as a QR code or deep link during 2FA/MFA enrollment. It is the right choice when you already have a base32 secret and need to format it correctly for authenticator apps (Google Authenticator, Authy, etc.) without implementing the URI formatting logic yourself. Prefer it over sibling endpoints when you need the URI string specifically, not a generated code or verification result.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T00:31:38.433Z","isFirstParty":false}