Getting started with the OCB - CLI Framework (v1/v2)

How to Obtain Required API Keys and Configuration

To utilize the OCB Framework, you will need to acquire the following API keys and blockchain details from the respective services. Below is a step-by-step guide on how to obtain them:


1. OPENAI_API_KEY (Mandatory)

  • Purpose: Access OpenAI's GPT models for natural language understanding and text generation.

  • How to Get It:

    1. Create or log in to your account.

    2. Go to the API Keys section in the dashboard.

    3. Generate a new API key and copy it to your .env file:

      OPENAI_API_KEY=your_openai_api_key

2. META_AI_API_KEY (Required for v2 Framework)

  • Purpose: Integrate with Meta's advanced AI models for multimodal and NLP capabilities.

  • How to Get It:

    1. Log in or create an account.

    2. Register an application to obtain an API key under the Tools & Support section.

    3. Add the key to your .env file:

      META_AI_API_KEY=your_meta_ai_api_key

3. LUMA_AI_API_KEY (Required for v2 Framework)

  • Purpose: Use Luma AI for visual intelligence and multimodal AI tasks.

  • How to Get It:

    1. Sign up at Luma AI.

    2. Log in to your account and navigate to the API Access section.

    3. Generate an API key and add it to your .env file:

      LUMA_AI_API_KEY=your_luma_ai_api_key

4. DEEPSEEK_API_KEY (Required for v2 API)

  • Purpose: Integrate with DeepSeek for data analysis, innovative AI models, and text generation.

  • How to Get It:

    1. Visit DeepSeek AI and sign up.

    2. After logging in, locate the API Key section in the dashboard.

    3. Generate and copy the API key:

      DEEPSEEK_API_KEY=your_deepseek_api_key

5. GROK_API_KEY (Early Development Stage)

  • Purpose: Use Grok's API for cutting-edge AI functionalities.

  • How to Get It:

    1. Currently in early development; request access by visiting their platform (if available).

    2. Reach out via their contact page or community forums for early developer access.

    3. Once access is granted, add the key:

      envCopyEditGROK_API_KEY=your_grok_api_key

6. BLOCKCHAIN_RPC_URL (Mandatory)

  • Purpose: Connect to the Solana mainnet for blockchain interactions.

  • How to Get It:

    1. Use the default Solana mainnet RPC URL:BLOCKCHAIN_RPC_URL=https://api.mainnet-beta.solana.com

    2. For better performance or custom setups, consider private RPC services such as Alchemy or QuickNode.


7. BITQUERY_API_KEY (Mandatory)

  • Purpose: Access detailed blockchain analytics through the BitQuery API.

  • How to Get It:

    1. Sign up at BitQuery.

    2. Once registered, log in to your account and navigate to the API Keys section.

    3. Generate an API key and include it in your .env file:

      BITQUERY_API_KEY=your_bitquery_api_key

8. PRIVATE_KEY (Mandatory)

  • Purpose: The private key for the Solana wallet that the agent will utilize for blockchain transactions.

  • How to Get It:

    1. If you already have a wallet, export the private key from your wallet (e.g., Phantom, Sollet, or CLI).

    2. To generate a new wallet:

      solana-keygen new --outfile my-wallet.json
    3. Copy the private key from the JSON file into your .env file:

      RIVATE_KEY=your_wallet_private_key
    4. Warning: Never expose your private key publicly to avoid compromising your wallet.


General Tips for API Key Management

  • Security: Use a secure method (e.g., .env file) to store your API keys and avoid hardcoding them in your codebase.

  • Rate Limits: Be aware of usage limits associated with the keys and upgrade your plans as needed.

  • Rotation: Rotate API keys periodically to maintain security.

By following this guide, you'll have all the required keys to unlock the full capabilities of the OCB

Last updated