np), Python SDK, or HTTP API requires a valid API key.
Generating an API Key
You generate API keys from the nodepick.ai dashboard. Follow these steps:- Register at nodepick.ai and log in.
- Set up your credit card in the dashboard.
- In the left-hand navigation, open Developer, then go to API Keys.
- Click Generate and give the key a descriptive name (for example,
devorci-pipeline). - Copy and save the key immediately — it will not be shown again after you leave the page.
Python CLI Authentication (np auth)
The np command-line tool provides built-in authentication commands to store, test, and clear your credentials securely in your operating system’s keyring.
Configure Credentials (np auth configure)
Run np auth configure to save your API key securely into your OS keyring. When prompted, paste your API key:
nodepick-cli service).
Custom API Base URL
If you need to target a custom API endpoint, pass the--base-url (-u) option:
Test API Access (np auth test)
Verify your stored credentials and display your user and organization information:
Example Output
Clear Credentials (np auth clear)
Remove the stored API key from your OS keyring:
Non-Interactive Authentication (Environment Variable)
For CI/CD workflows, automated scripts, or headless environments, set theNODEPICK_API_KEY environment variable:
NODEPICK_API_KEY if present, overriding any key stored in the OS keyring.
Python API / SDK Authentication
When using thenodepick Python SDK, pass your API key directly when initializing the client.
Initialize with Explicit API Key
client automatically includes your key in the request headers.
Initialize with Environment Variable (Recommended)
To avoid hardcoding secrets in your source code, load your API key from an environment variable:Using Context Manager
You can also use the client as a context manager (with block) to ensure connections close automatically:
HTTP API Bearer Token
If you are calling the REST API directly from tools likecurl, Postman, or other languages, include your API key as a Bearer token in the Authorization header:
Keeping Your API Key Secure
- Use
.envfiles: For local development, store secrets in a.envfile and load them withpython-dotenv. - Add to
.gitignore: Ensure.envis listed in your.gitignorefile. - Rotate Compromised Keys: If a key is compromised, generate a replacement in Developer Settings > API Keys, update your applications, and delete the old key.
Next Steps
Create a Node
Provision a new compute node using the Python CLI, SDK, or HTTP API.
Manage Nodes
List, inspect, control power, and delete compute nodes.