Skip to main content
Try Cobo WaaS Skill in your AI coding assistant (Claude Code, Cursor, etc.). Describe your needs in natural language to auto-generate production-ready SDK code and debug faster 🚀
This guide explains how to generate and manage API key paris and app key pairs using Cobo CLI. All keys are used for authenticating with Cobo WaaS 2.0.

Generate keys

Use the keys generate command to generate a new API key pair (an API key and an API secret) or an app key pair (an app key and an app secret).

Usage

Options

  • --key-type <key_type>: Specify the type of key to generate (API or APP). Default is API.
  • --alg <algorithm>: Specify the key generation algorithm. Default is ed25519.
  • --force: Force replacement of existing keys.

Example

Generate a new API key pair:
Generate a new app key pair:
Force replacement of existing API key pair:

Key storage

Generated keys are securely stored in your configuration file (default: ~/.cobo/config.toml).
Never share your API secret or app secret. Keep it secure and use the API key only when registering it on Cobo Portal.

Best practices

  • Regularly rotate your API key pairs or app key pairs to maintain security.
  • Use different keys for the development and production environments.
  • Limit the permissions associated with each key to the minimum required for its intended use.
  • Monitor key usage and revoke any keys that may have been compromised.