Quickstart Guide
This guide will get you up and running with Sastra API in less than 5 minutes.
1. Get your API Key
You'll need an API key to authenticate your requests. Go to the API Keys Dashboard and click "Create new key".
Important: Your API key is secret. Do not share it or commit it to client-side code.
2. Make a Request
Paste your API key into the command below to test the API.
curl https://amplify.aisastra.com/api/sastra-api/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $SASTRA_API_KEY" \
-d '{
"model": "sastra-v1",
"messages": [
{
"role": "system",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": "Hello!"
}
]
}'3. Next Steps
Now that you have made your first request, explore the API Reference to see all available parameters.