Back to products

Using methods

Codex API Key User Guide

Redeem your code, configure your app, then check quota and expiry. Works with Codex CLI, Cursor, VS Code, Claude Code, Openclaw, Hermes Agent and more.

  1. Before you start

    Your redeem code is NOT your API key

    Base URL

    https://api.miraiapi.com/v1

    Your API key will begin with sk-. This is only an example format, not a key to copy.

    Redeem code vs API key

    The redeem code comes from your order details and is used once, on the redeem page. The API key starts with sk- and is what you paste into your app. They are two different things — never swap them.

    Available models: gpt-6-astra, gpt-5.6-luna, gpt-5.6-terra, gpt-5.6-sol.

    Works with Codex CLI, Cursor, VS Code, Claude Code, Openclaw, Hermes Agent and other compatible apps.

  2. 1

    Redeem your code

    Enter the code from your order details

    Any browser

    Enter the purchased code from your order details, click “Check code,” and complete the redemption process. You will then receive your API key.

    Open the redeem page
    Where to enter and check your redeem code
  3. 2

    Configure your app

    Paste your API key, select your app and model, then copy the setup command.

    Codex CLI / VS Code / CursorWindows, macOS, Linux

    Paste the API key you received into CONFIG_KEY. Select the app and model, then copy the generated setup command for your operating system. Run it in the matching terminal: Windows PowerShell, Windows CMD, or the macOS / Linux terminal.

    Select the app and models, paste the API key into CONFIG_KEY, then copy the command for your operating system
    Open the configuration page
  4. 3

    Check usage & expiry

    See remaining quota and expiration date

    Check remaining quota and the expiration date of your key any time.

    Open the usage page