Claude-code-plugins-plus-skills cohere-install-auth
install
source · Clone the upstream repo
git clone https://github.com/jeremylongshore/claude-code-plugins-plus-skills
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/jeremylongshore/claude-code-plugins-plus-skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/plugins/saas-packs/cohere-pack/skills/cohere-install-auth" ~/.claude/skills/jeremylongshore-claude-code-plugins-plus-skills-cohere-install-auth && rm -rf "$T"
manifest:
plugins/saas-packs/cohere-pack/skills/cohere-install-auth/SKILL.mdsource content
Cohere Install & Auth
Overview
Set up the Cohere SDK (v2) and configure authentication for Chat, Embed, Rerank, and Classify endpoints.
Prerequisites
- Node.js 18+ or Python 3.10+
- Package manager (npm, pnpm, or pip)
- Cohere account at dashboard.cohere.com
- API key from Cohere dashboard (trial keys are free, production keys require billing)
Instructions
Step 1: Install SDK
# Node.js / TypeScript npm install cohere-ai # Python pip install cohere
Step 2: Configure API Key
# Set environment variable export CO_API_KEY="your-api-key-here" # Or create .env file (add .env to .gitignore!) echo 'CO_API_KEY=your-api-key-here' >> .env
Key types:
- Trial key — free, rate-limited (5-20 calls/min per endpoint, 1000/month others)
- Production key — metered billing, 1000 calls/min all endpoints, unlimited monthly
Step 3: Verify Connection (TypeScript)
import { CohereClientV2 } from 'cohere-ai'; const cohere = new CohereClientV2({ token: process.env.CO_API_KEY, }); async function verify() { const response = await cohere.chat({ model: 'command-a-03-2025', messages: [ { role: 'user', content: 'Say "connection verified" and nothing else.' }, ], }); console.log('Status:', response.message?.content?.[0]?.text); } verify().catch(console.error);
Step 4: Verify Connection (Python)
import cohere import os co = cohere.ClientV2(api_key=os.environ.get("CO_API_KEY")) response = co.chat( model="command-a-03-2025", messages=[ {"role": "user", "content": "Say 'connection verified' and nothing else."} ], ) print("Status:", response.message.content[0].text)
Available Models
| Model | ID | Context | Best For |
|---|---|---|---|
| Command A | | 256K | Latest, most capable |
| Command R+ | | 128K | Complex RAG, agents |
| Command R | | 128K | RAG, cost-effective |
| Command R7B | | 128K | Fast, lightweight |
| Embed English v4 | | 128K | Embeddings (EN) |
| Embed Multilingual v3 | | 512 | Embeddings (100+ langs) |
| Rerank v3.5 | | 4K | Search reranking |
Output
- Installed
(TS) orcohere-ai
(Python) packagecohere - Environment variable
configuredCO_API_KEY - Verified API connectivity with a chat completion
Error Handling
| Error | Cause | Solution |
|---|---|---|
| Wrong or expired key | Regenerate at dashboard.cohere.com |
| Network blocked | Ensure HTTPS to allowed |
| Trial rate limit hit | Wait 60s or upgrade to production key |
| Package not installed | Run |
SDK Auto-Detection
The SDK reads
CO_API_KEY automatically if set. You can skip the token param:
// Auto-reads CO_API_KEY from environment const cohere = new CohereClientV2();
Resources
Next Steps
After successful auth, proceed to
cohere-hello-world for your first real API call.