# flatkey.ai flatkey.ai is a unified AI API gateway, model routing, billing, and operations platform. ## API Protocols - Router base URL: https://router.flatkey.ai - OpenAI-compatible Chat Completions: POST https://router.flatkey.ai/v1/chat/completions - OpenAI-compatible Responses: POST https://router.flatkey.ai/v1/responses - Anthropic Messages: POST https://router.flatkey.ai/v1/messages - Gemini native generateContent: POST https://router.flatkey.ai/v1beta/models/{model}:generateContent - Asynchronous video generation: POST https://router.flatkey.ai/v1/videos ## Gemini Image Models - nano-banana-pro-preview supports both Gemini native generateContent and OpenAI-compatible Chat Completions. - With Gemini native generateContent, generated images are returned in candidates[].content.parts[].inlineData. - With Chat Completions, generated images are returned in choices[0].message.content as Markdown data URIs. - These Gemini image-model paths currently do not use /v1/images/generations; do not infer lack of Gemini support from that endpoint. ## Seedance Video Models - Seedance models use the official multimodal content[] request format. - Create a video task with POST https://router.flatkey.ai/v1/videos. - Poll task status with GET https://router.flatkey.ai/v1/videos/{task_id}. - Download completed video content with GET https://router.flatkey.ai/v1/videos/{task_id}/content. - Use GET /v1/models to discover the Seedance model IDs currently available to your account. - Documentation: https://docs.flatkey.ai/api-reference/seedance-video-generation - Chinese documentation: https://docs.flatkey.ai/zh/api-reference/seedance-video-generation ## Core Pages - Home: https://flatkey.ai/ - Flatkey Tools: https://flatkey.ai/tools - Flatkey as an Apify alternative: https://flatkey.ai/apify-alternative - Flatkey CLI: https://flatkey.ai/cli - Flatkey vs Higgsfield: https://flatkey.ai/higgsfield-alternative - Model pricing: https://flatkey.ai/pricing - Rankings: https://flatkey.ai/rankings - Blog: https://flatkey.ai/blog - Sitemap: https://flatkey.ai/sitemap.xml ## Blog Categories - AI Gateway Architecture: https://flatkey.ai/blog/category/ai-gateway-architecture - Base URL and SDK Migration: https://flatkey.ai/blog/category/base-url-and-sdk-migration - Cost, Billing, and Ops: https://flatkey.ai/blog/category/cost-billing-and-ops - Enterprise Controls and Trust: https://flatkey.ai/blog/category/enterprise-controls-and-trust - Gateway Comparisons: https://flatkey.ai/blog/category/gateway-comparisons - Model and Modality Playbooks: https://flatkey.ai/blog/category/model-and-modality-playbooks - Reliability and Routing: https://flatkey.ai/blog/category/reliability-and-routing - Tool Integrations: https://flatkey.ai/blog/category/tool-integrations ## Blog Articles - LLM API Observability: Metrics, Traces, Logs, and Cost: https://flatkey.ai/blog/llm-api-observability-metrics-traces-cost - A production guide to monitoring LLM APIs with validated success metrics, distributed traces, safe structured logs, SLOs, alerts, and cost per accepted task. - Secure API Key Management for AI Products: https://flatkey.ai/blog/secure-api-key-management-ai-products - A production playbook for AI API key custody, scoped identities, prompt-safe logging, zero-downtime rotation, leak response, and multi-provider governance. - AI Model Evaluation Before Switching API Providers: A Workflow Checklist: https://flatkey.ai/blog/ai-model-evaluation-before-switching-api-providers - Use a decision-grade AI model evaluation workflow to compare providers on task success, compatibility, reliability, latency, effective cost, and rollout risk. - LLM Rate Limits Explained: RPM, TPM, and Retries: https://flatkey.ai/blog/llm-rate-limits-explained-rpm-tpm-retries - Understand RPM, TPM, 429 errors, capacity planning, queues, exponential backoff, retry budgets, and fallback routing for production LLM APIs. - LLM API Fallback Routing: A Production Failover Playbook: https://flatkey.ai/blog/llm-api-fallback-routing-production-playbook - A production playbook for deciding when LLM requests should retry, fail over, switch models, or stop—without breaking streams, tools, schemas, or latency budgets. - AI API Pricing Comparison: OpenAI vs Claude vs Gemini vs Qwen (2026): https://flatkey.ai/blog/ai-api-pricing-comparison-openai-claude-gemini-qwen - Compare current OpenAI, Claude, Gemini, and Qwen API prices using normalized production workloads and cost per accepted result. - AI API Gateway Architecture: One Key, Model Routing, and Failover: https://flatkey.ai/blog/ai-api-gateway-architecture-model-routing - A production architecture guide to one-key model access, explicit routing policy, health checks, retries, contract-safe failover, streaming, telemetry, and migration. - Seedance API Evaluation Framework for Text-to-Video Product Teams: https://flatkey.ai/blog/seedance-api-evaluation-framework-product-teams - A repeatable framework for evaluating Seedance API quality, reliability, user experience, safety, and cost before a text-to-video product rollout. - DeepSeek API vs Qwen API for Cost-Sensitive Workflows: 2026 Cost Guide: https://flatkey.ai/blog/deepseek-api-vs-qwen-api-cost-sensitive-workflows - Compare DeepSeek and Qwen API pricing with July 28, 2026 list prices, cache break-even math, batch costs, lifecycle risks, and workload-specific guidance. - Gemini API Production Readiness Checklist for Backend Teams: https://flatkey.ai/blog/gemini-api-production-readiness-checklist-backend-teams - A production-readiness checklist for backend teams integrating Gemini API, covering credentials, response contracts, retries, observability, cost, rollout, and incidents. - Claude API Access Outside One-Region Setups: A Compliance-First Guide: https://flatkey.ai/blog/claude-api-access-outside-one-region-setups - A compliance-first guide to Claude API access across regions, covering direct Anthropic, Bedrock, Vertex AI, gateways, testing, observability, and approved failover. - OpenAI API Access for Multi-Model Products: A Production Setup Guide: https://flatkey.ai/blog/openai-api-access-production-multi-model-products - Set up OpenAI API access for a production multi-model product with project-scoped credentials, endpoint checks, rate-limit handling, canaries, and fallback readiness. - Flatkey Integration Starter: From One Key to Multi-Model Testing: https://flatkey.ai/blog/flatkey-integration-starter - Connect Flatkey to the quickest useful workflow: make a first API call, add Cherry Studio or CC Switch, compare models, and plan the team handoff. - AI API Spend Management for Operations and Finance Teams: https://flatkey.ai/blog/ai-api-spend-management-operations-finance - A role-based guide for connecting AI API usage, billing, quotas, balances, recharge records, and key governance in one operating model. - AI image generation API for ecommerce creative pipelines: a buyer guide: https://flatkey.ai/blog/ai-image-generation-api-ecommerce-creative-pipelines - A manager-facing guide to evaluating AI image generation APIs and gateways for ecommerce creative pipelines using weighted criteria, decision gates, and a 30-day pilot. - Seedance 2.0 API in 2026: Access, Pricing, and Fallback Routing: https://flatkey.ai/blog/seedance-2-0-api - A current guide to Seedance 2.0 API access, pricing verification, asynchronous jobs, and safe fallback routing across changing video-model versions. - DeepSeek API Pricing (2026): Compare OpenAI, Claude, Gemini, and Qwen: https://flatkey.ai/blog/deepseek-api-pricing - Compare DeepSeek API pricing with OpenAI, Claude, Gemini, and Qwen using dated token rates, reproducible workload math, cache caveats, and a scheduled refresh workflow. - Gemini API Pricing in 2026: Current Model Costs and Workload Calculator: https://flatkey.ai/blog/gemini-api-pricing - Compare current Gemini API pricing with reproducible workload-cost tables for Gemini 3.6 Flash, 3.5 Flash-Lite, Gemini 2.5 models, Batch jobs, caching, and long-context workloads.