NEAR AI Cloud
first_party
Getting credentials
api-key
api_key via header (header Authorization: Bearer)
Environment: NEAR_AI_API_KEY
Keys from cloud.near.ai Developer Dashboard; prepaid Usage Credits (or NEAR staking yield). The old api.near.ai went offline 2025-10-31.
Endpoints
| ID | URL | Protocol | Auth |
|---|---|---|---|
| chat | https://cloud-api.near.ai/v1/chat/completions | openai-chat | any |
| responses | https://cloud-api.near.ai/v1/responses | openai-responses | any |
API surfaces
textstreamingembeddingsimage_gen
Quirks
- Inference runs in hardware TEEs with attestation (/v1/attestation/report) and response signatures; direct per-model endpoints at {slug}.completions.near.ai terminate TLS inside the enclave. (docs)
- Per-model prices live in GET /v1/models (public, no auth); frontier OpenAI/Anthropic/Google models are resold through the gateway in OpenAI format. (docs)
- Reasoning params vary by model: reasoning_effort (gpt-oss, always-on), chat_template_kwargs.enable_thinking (GLM/Qwen), chat_template_kwargs.thinking (Kimi — not enable_thinking). (docs)
- The OpenAI Responses-compatible /v1/responses endpoint on the gateway is in beta. (docs)
Models offered
| Model | Wire ID | Endpoint | Status | Reasoning |
|---|---|---|---|---|
| alibaba/qwen3-7-max | qwen/qwen3.7-max | chat | ga | adaptive · default on · returns reasoning_content |
| alibaba/qwen3-8-27b | Qwen/Qwen3.8-27B | chat | ga | toggle · default on · returns reasoning_content |
| anthropic/claude-fable-5 | anthropic/claude-fable-5 | chat | ga | adaptive · default on · mandatory · returns reasoning_content |
| anthropic/claude-fable-5-1 | anthropic/claude-fable-5-1 | chat | ga | adaptive · default on · mandatory · returns reasoning_content |
| anthropic/claude-haiku-4-5 | anthropic/claude-haiku-4-5 | chat | ga | adaptive · default on · returns reasoning_content |
| anthropic/claude-opus-4-6 | anthropic/claude-opus-4-6 | chat | ga | adaptive · default on · returns reasoning_content |
| anthropic/claude-opus-4-7 | anthropic/claude-opus-4-7 | chat | ga | adaptive · default on · returns reasoning_content |
| anthropic/claude-opus-4-8 | anthropic/claude-opus-4-8 | chat | ga | adaptive · default on · returns reasoning_content |
| anthropic/claude-opus-5 | anthropic/claude-opus-5 | chat | ga | adaptive · default on · returns reasoning_content |
| anthropic/claude-sonnet-5 | anthropic/claude-sonnet-5 | chat | ga | adaptive · default on · returns reasoning_content |
| deepseek/deepseek-v4-flash | deepseek-ai/DeepSeek-V4-Flash | chat | ga | toggle · default on · returns reasoning_content |
| google/gemini-3-5-flash | google/gemini-3.5-flash | chat | ga | adaptive · default on · returns reasoning_content |
| google/gemini-3-8-flash | google/gemini-3.8-flash | chat | ga | effort · default on · returns reasoning_content |
| google/gemma-4 | google/gemma-4-31B-it | chat | retired | adaptive · default on · returns hidden |
| moonshot/kimi-k2-6 | moonshotai/kimi-k2.6 | chat | ga | toggle · default on · returns reasoning_content |
| moonshot/kimi-k3 | moonshotai/kimi-k3 | chat | ga | toggle · default on · returns reasoning_content |
| openai/gpt-5 | openai/gpt-5 | chat | ga | effort · default on · mandatory · returns reasoning_content |
| openai/gpt-5-1 | openai/gpt-5.1 | chat | ga | effort · default on · returns reasoning_content |
| openai/gpt-5-4 | openai/gpt-5.4 | chat | ga | effort · default off · returns reasoning_content |
| openai/gpt-5-4-mini | openai/gpt-5.4-mini | chat | ga | effort · default off · returns reasoning_content |
| openai/gpt-5-4-nano | openai/gpt-5.4-nano | chat | ga | effort · default off · returns reasoning_content |
| openai/gpt-5-5 | openai/gpt-5.5 | chat | ga | effort · default on · returns reasoning_content |
| openai/gpt-5-6 | openai/gpt-5.6-luna | chat | ga | effort · default on · returns reasoning_content |
| openai/gpt-5-6 | openai/gpt-5.6-sol | chat | ga | effort · default on · returns reasoning_content |
| openai/gpt-6 | openai/gpt-6-astra | chat | ga | effort · default on · mandatory · returns reasoning_content |
| openai/gpt-oss-120b | openai/gpt-oss-120b | chat | retired | effort · default on · mandatory · returns reasoning_content |
| openai/o3 | openai/o3 | chat | ga | effort · default on · mandatory · returns reasoning_content |
| zai/glm-5-2 | z-ai/glm-5.2 | chat | ga | toggle · default on · returns reasoning_content |
| zai/glm-5-3-flash | z-ai/glm-5.3-flash | chat | ga | always_on · default on · mandatory · returns reasoning_content |