Skip to main content

Overview

Cyberwave uses API tokens to authenticate requests. You’ll need a token to:
  • Connect the Python SDK
  • Make REST API calls
  • Establish MQTT connections
Each token is scoped to a specific workspace, giving you isolated access per workspace.

Creating an API Token

1

Sign in to Cyberwave

Go to cyberwave.com and sign in to your account.
2

Navigate to Profile

Click your profile icon and select Profile or go directly to cyberwave.com/profile.
3

Create a Token

In the API Tokens section, click Create Token. Select the workspace you want the token scoped to, then copy the token immediately — it won’t be shown again.
Keep your API token secure. Don’t commit it to version control or share it publicly.

Using Your API Token

Set your API token as an environment variable:
export CYBERWAVE_API_KEY="cw_your_token_here"
The SDK automatically reads this variable:
import cyberwave as cw

# Automatically uses CYBERWAVE_API_KEY
robot = cw.twin("the-robot-studio/so101")

Direct Configuration

Pass the API token directly when initializing the client:
from cyberwave import Cyberwave

client = Cyberwave(api_key="cw_your_token_here")

Environment Variables

The SDK supports these environment variables:
VariableDescription
CYBERWAVE_API_KEYYour API token for authentication
CYBERWAVE_BASE_URLAPI base URL (default: https://api.cyberwave.com)
CYBERWAVE_ENVIRONMENT_IDDefault environment UUID
CYBERWAVE_WORKSPACE_IDDefault workspace UUID
CYBERWAVE_MQTT_HOSTMQTT broker host (default: mqtt.cyberwave.com)
CYBERWAVE_MQTT_PORTMQTT broker port (default: 8883)

Example .env File

CYBERWAVE_API_KEY=cw_a1b2c3d4e5f6...
CYBERWAVE_ENVIRONMENT_ID=1e48b1a5-ff2b-45ba-a854-a2c2df561852
Load with python-dotenv:
from dotenv import load_dotenv
load_dotenv()

import cyberwave as cw
robot = cw.twin("the-robot-studio/so101")

MQTT Authentication

For real-time features (video streaming, teleoperation, live joint updates), the SDK connects to MQTT automatically using your API token. The MQTT connection is lazily initialized — it connects on the first call that requires it (e.g., subscribing to joint updates).
from cyberwave import Cyberwave

client = Cyberwave(api_key="cw_your_token_here")

robot = client.twin("the-robot-studio/so101")
# MQTT connects automatically on the first subscription
robot.subscribe_joints(lambda data: print(f"Joints: {data}"))
The default MQTT connection uses TLS on port 8883.

Custom MQTT Settings

Override MQTT connection settings if needed:
client = Cyberwave(
    api_key="cw_your_token_here",
    mqtt_host="mqtt.cyberwave.com",
    mqtt_port=8883
)

REST API Authentication

For direct REST API calls, include your API token in the Authorization header:
curl -X GET "https://api.cyberwave.com/api/v1/assets/" \
  -H "Authorization: Bearer cw_your_token_here"
Both Bearer and Token prefixes are accepted.

Troubleshooting

  • Verify your API token is correct and hasn’t been revoked
  • Check that the environment variable is set: echo $CYBERWAVE_API_KEY
  • Generate a new token from your profile page if needed
The SDK couldn’t find credentials. Either:
  • Set the CYBERWAVE_API_KEY environment variable
  • Pass api_key directly to Cyberwave()
  • Check your network allows outbound connections on port 8883 (TLS)
  • Verify your API token is valid and not revoked
  • The MQTT client connects lazily — call a subscription method to trigger the connection

Next Steps

Quick Start

Create your first digital twin

Python SDK

Full SDK documentation