Effortless 2FA Code Generation via API
Programmatically generate 2FA codes with the following APIs. This is ideal for development and testing workflows. Beeceptor stores your secrets and assigns a unique ID for 2FA code retrieval, valid for up to 90 days.
Setup the secret
You can generate time-based one-time passwords (TOTPs) for a given. Simply provide the issuer name and secret key in a JSON payload. On success, the API returns the generated OTP and a unique identifier.
POST https://tools.beeceptor.com/2FA/TOTP/ Content-Type: application/json Request Payload: { "issuer": "your-app.com", "secret": "2OLRLATN3OQZOCPA", "algorithm":"SHA256" } Response Payload: { "id": "e2cb7165-55a5-44ce-8f7d-c4ff093bcd39", "otp": "002881", "expiresAt": "2024-05-15T02:46:30.000Z" }
Retrieve 2FA code
Use the generated identifier with this API to generate future 2FA codes using the pre-stored secret. Please note that any unused codes will be automatically purged 90 days after their last usage.
GET https://tools.beeceptor.com/2FA/TOTP/{id} Content-Type: application/json Request Payload: {empty} Response Payload: { "id": "e2cb7165-55a5-44ce-8f7d-c4ff093bcd39", "otp": "002881", "expiresAt": "2024-05-15T02:46:30.000Z" } Example: GET https://tools.beeceptor.com/2FA/TOTP/e2cb7165-55a5-44ce-8f7d-c4ff093bcd39
Why Choose Beeceptor?
Experience the power of automated 2FA with Beeceptor's 2FA Code Generator.
Ease of Use
No user registration and no API keys required. These APIs are built for the community, making it easy to get started. Get started now with this Postman collection.
Comprehensive Coverage
Beeceptor supports JSON payloads and QR code uploads, providing comprehensive coverage for your integration needs. These APIs are CORS-enabled for any origin, ensuring smooth integration with your automation suite.
Secure
Beeceptor automatically purges any unused secrets after 90 days and uses HTTPs to keep your data secure during transmission.