The Ntense AI API exposes OpenAI-compatible endpoints for text, images, audio, and embeddings. Use one base URL, https://ntense.ai/ai/v1, and select the model and endpoint for the task. A separate Anthropic Messages-compatible base URL is available for text clients.
In a Ntense Cloud Workspace, the connection variables and a Workspace API key are already set. Outside the Workspace, create a personal key in your Ntense account and keep it on the server side.
Configure your environment
For an app outside the Cloud Workspace, put these values in a private .env file or your deployment's secret store. Replace the API key placeholder with your own key.
# OpenAI-compatible API: use this URL for all seven examples below.
NTENSE_BASE_URL=https://ntense.ai/ai/v1
NTENSE_MODEL=ntense-expert
# Anthropic Messages-compatible text clients use this separate URL.
NTENSE_CLAUDE_BASE_URL=https://ntense.ai/ai
NTENSE_CLAUDE_MODEL=ntense-expert
# Create a personal key in Account → API Keys; never commit a real key.
NTENSE_API_KEY=replace-with-your-own-keyNTENSE_BASE_URL is for OpenAI-compatible clients. NTENSE_CLAUDE_BASE_URL is for Anthropic Messages-compatible text clients, whose SDK adds /v1/messages. The two model variables set default text models for those clients. Change the model in a request when the task needs another capability.
A .env file does not automatically configure a terminal session. To run the curl examples locally, load a .env file that you created and trust:
set -a
. ./.env
set +aUsing a Ntense Cloud Workspace
Open a terminal in your Workspace. All five environment variables are already set, and the Workspace has its own API key, so you do not need to create a personal key or load a .env file there. Your Workspace may set a different default model. Check NTENSE_MODEL and change the model in your request if the task needs one.
Your app can read these values from its environment. Keep the key on the server side. Do not put it in browser code, commit it to a repository, or print it in logs.
Using the API outside a Ntense Cloud Workspace
Sign in to Ntense, open Account → API Keys, and select Create API key. Copy the key straight away, because it is shown only once. Set the five environment variables above in a private .env file or your app's secret store, with NTENSE_API_KEY set to the key you created.
The same page lets you Recreate a Workspace key, which replaces its secret, or Remove a personal key you no longer need. Workspace keys are labelled Managed by workspace. For work outside the Workspace, create your own key instead of copying the Workspace key out of its environment.
This also works in a Google Colab or Kaggle notebook with internet access. Keep your key in the notebook provider's secret storage, not in a notebook cell, and call the same base URL from notebook code. You only need Ntense Tunnel if you want Ntense itself to run commands in that notebook, and only where the provider allows it. See the Google Colab FAQ[1] and Kaggle Notebooks documentation[2].
OpenAI-compatible endpoints and models
All seven examples use NTENSE_BASE_URL and NTENSE_API_KEY. The base URL stays the same; the endpoint, model, and request body change with the task. These are non-streaming curl examples.
- Text chat and reasoning:
ntense-expert, with/chat/completionsor/responses - Faster, lower-cost text:
ntense-mini, with/chat/completionsor/responses - Image generation:
ntense-image, with/images/generations - Audio conversation:
ntense-audio, with/chat/completionsand audio input or output - Text to speech:
ntense-tts, with/audio/speech - Speech transcription:
ntense-transcribe, with/audio/transcriptions - Text embeddings:
ntense-text-embedding, with/embeddings
Endpoints in the list are relative to NTENSE_BASE_URL.
Changing only the model name in a chat request does not turn it into an image, speech, transcription, or embedding request. Use the matching endpoint and payload.
Text chat and reasoning: ntense-expert
Send a chat message to /chat/completions. The answer is in choices[0].message.content.
curl -sS "$NTENSE_BASE_URL/chat/completions" \
-H "Authorization: Bearer $NTENSE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"model":"ntense-expert","messages":[{"role":"user","content":"Explain one way to verify an AI answer."}]}'Check the answer against your task before you use it in a project. If the request is rejected, confirm that your key is active, the base URL matches your client format, and the model supports this endpoint.
Faster text: ntense-mini
Use /responses when your client uses the Responses format. Its output structure differs from Chat Completions. Both text models can use either text endpoint.
curl -sS "$NTENSE_BASE_URL/responses" \
-H "Authorization: Bearer $NTENSE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"model":"ntense-mini","input":"Summarise this idea in one sentence: test a small prototype with a real user."}'Image generation: ntense-image
Send a prompt to /images/generations. The response contains generated image data, commonly data[0].b64_json or an image URL. Handle the response form your client receives. The request shape follows the OpenAI image generation guide[3].
curl -sS "$NTENSE_BASE_URL/images/generations" \
-H "Authorization: Bearer $NTENSE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"model":"ntense-image","prompt":"A simple blue paper airplane on a clean white background"}'Audio conversation: ntense-audio
This request asks for text and audio output. The audio bytes are base64 encoded in choices[0].message.audio.data; decode them to save or play the result. For audio input, send an input_audio content part with base64 encoded audio and its format. This follows the OpenAI audio in Chat Completions guide[4].
curl -sS "$NTENSE_BASE_URL/chat/completions" \
-H "Authorization: Bearer $NTENSE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"model":"ntense-audio","modalities":["text","audio"],"audio":{"voice":"alloy","format":"wav"},"messages":[{"role":"user","content":"Say hello and explain what you can help with."}]}'Text to speech: ntense-tts
Send text to /audio/speech and save the binary response. This example writes an MP3 file. The request shape follows the OpenAI text-to-speech guide[5].
curl -sS "$NTENSE_BASE_URL/audio/speech" \
-H "Authorization: Bearer $NTENSE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"model":"ntense-tts","input":"Welcome to Ntense.","voice":"alloy","response_format":"mp3"}' \
--output speech.mp3Speech transcription: ntense-transcribe
Replace sample.wav with an audio file on your computer. curl -F sets the multipart content type and uploads the file. The request shape follows the OpenAI transcription guide[6].
curl -sS "$NTENSE_BASE_URL/audio/transcriptions" \
-H "Authorization: Bearer $NTENSE_API_KEY" \
-F 'model=ntense-transcribe' \
-F 'file=@sample.wav'Text embeddings: ntense-text-embedding
Send text to /embeddings. The returned vector is in data[0].embedding. The request shape follows the OpenAI embeddings guide[7].
curl -sS "$NTENSE_BASE_URL/embeddings" \
-H "Authorization: Bearer $NTENSE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"model":"ntense-text-embedding","input":"A short document to index for search."}'Using an Anthropic-compatible text client
Set NTENSE_CLAUDE_BASE_URL to https://ntense.ai/ai, NTENSE_CLAUDE_MODEL to ntense-expert, and use the same NTENSE_API_KEY. An Anthropic-compatible SDK appends /v1/messages to the base URL. The image, audio, transcription, and embeddings examples above use the OpenAI-compatible URL.
What are the usage limits?
The API is meant for study and experimentation, so usage is limited by your plan. It is a place to learn how to build and evaluate an AI-powered feature. You remain responsible for testing the results and protecting your key.
Account → Usage shows two limits as percentages: Weekly usage and a 5-hour limit, each with the time until it resets. These limits apply to requests made with Ntense API keys, not to your Development or Production runtime. If you reach a limit, wait for it to reset or make smaller requests.
We plan to offer a pay-as-you-go option for people who need more capacity, and to add video models in the future. Video models are not in the current model list.
If you would rather describe an idea and try a working app first, follow the Ntense app tutorial. To work with your own browser, development tools, or a notebook runtime, read how Ntense Tunnel connects your own tools.
Sources and further reading
- Google Colab FAQ[1]
- Kaggle Notebooks Documentation[2]
- OpenAI API: Image generation[3]
- OpenAI API: Audio in Chat Completions[4]
- OpenAI API: Text to speech[5]
- OpenAI API: File transcription[6]
- OpenAI API: Vector embeddings[7]
Sources
- Google Colab FAQ — Google Colab Accessed Wed Sep 23 2026 00:00:00 GMT+0000 (Coordinated Universal Time). Explains Colab notebook operation, runtime availability, and the need to follow Colab usage rules when working in its managed environments.
- Kaggle Notebooks Documentation — Kaggle Accessed Wed Sep 23 2026 00:00:00 GMT+0000 (Coordinated Universal Time). Documents Kaggle Notebooks as a hosted notebook environment for running code with available compute resources.
- Image generation — OpenAI Accessed Sat Sep 26 2026 00:00:00 GMT+0000 (Coordinated Universal Time). Documents the OpenAI-compatible image generation request and image response data.
- Audio in Chat Completions — OpenAI Accessed Sat Sep 26 2026 00:00:00 GMT+0000 (Coordinated Universal Time). Documents audio output using modalities, audio voice and format, and base64 audio data.
- Text to speech — OpenAI Accessed Sat Sep 26 2026 00:00:00 GMT+0000 (Coordinated Universal Time). Documents the audio/speech request body and binary output.
- File transcription — OpenAI Accessed Sat Sep 26 2026 00:00:00 GMT+0000 (Coordinated Universal Time). Documents multipart audio/transcriptions uploads.
- Vector embeddings — OpenAI Accessed Sat Sep 26 2026 00:00:00 GMT+0000 (Coordinated Universal Time). Documents the embeddings request and returned vector.



