Using API Keys
What are API Keys?
API keys allow you to access http://boisestate.ai programmatically through code—instead of using the web interface. This enables you to:
Automate workflows: Process multiple requests without manual interaction
Build custom applications: Create software that uses http://boisestate.ai as an AI backbone
Integrate AI into existing tools: Connect http://boisestate.ai to your applications, scripts, or platforms
Batch process requests: Send many requests at once rather than one at a time
Enable real-time interactions: Use streaming responses for live, word-by-word feedback
Common use cases:
Who should use API keys?
Important note: This guide assumes basic familiarity with HTTP requests, programming, or API concepts. If you're new to these, consider starting with the web interface or asking IT support for help.
Quick Reference: Prompt Templates vs. System Instructions vs. Assistants
Key Characteristics & Limitations
Understanding these important characteristics will help you plan your API usage:
Characteristic | What It Means | Implication |
|---|---|---|
One active key per user | You can have only one API key at a time (can regenerate to get a new one) | Plan your API key distribution and rotation carefully |
Keys expire after 90 days | API keys automatically stop working after 90 days | Set a calendar reminder to regenerate keys before they expire |
Usage counts against monthly quota | Every API call uses part of your Boise State monthly token allocation | Monitor your usage; batch requests thoughtfully to avoid running out of quota |
API conversations not saved | Requests via API are NOT logged to your web interface chat history | Keep your own logs if you need to maintain records |
No default behavior | Unlike the web interface, API requests have no default system instructions | You must explicitly provide |
No conversation memory | Each API request is independent; context is not maintained between requests | Include previous messages in the |
Important security notes:
✅ API keys should be treated like passwords
✅ Store keys in environment variables, not in code
✅ Never commit API keys to version control (git, GitHub, etc.)
✅ Rotate keys periodically for security
Pro tip: Use AI to help you troubleshoot your code! This can be useful if you come across “invalid key” or 401 errors during the process. You can paste your code into the prompt window without the API key to get feedback on your code.
Getting Your API Key
Understanding the Two Endpoints
boisestate.ai offers two different endpoints for different use cases. Choose based on your needs:
Choosing an AI Model
Quick Start Examples
Choose the example that matches your use case. All examples use curl, Python, and JavaScript.
Before you start:
Replace
YOUR_API_KEYwith your actual API keyChoose the appropriate
modelId(see "Choosing an AI Model" above)Test examples with simple messages first before scaling up