Files

1 line
2.9 KiB
JSON

{"text":["Models","Perplexity","sonar-pro","Sonar Pro","Note: Sonar Pro pricing includes Perplexity search pricing.","Get API key","Try in Chat","Specifications","Context Window","200K","Modalities","text","Price","$3.34 in ยท $16.70 out, per million tokens","Model ID","perplexity/sonar-pro","Quick start","Get an API key โ†’","TypeScript","Python","cURL","Go","import","OpenAI","from","openai","const","client = new","({","apiKey","process.env.HANZO_API_KEY","baseURL","https://api.hanzo.ai/v1","})","response =","await","client.chat.completions.","create","model","messages","[{","role","user","content","Hello!","}]","console.","log","response.choices",".message.content","client = OpenAI","api_key=os","environ","HANZO_API_KEY","],","base_url=","response = client","chat","completions","model=","messages=","print","response","choices","].","message","curl","https://api.hanzo.ai/v1/chat/completions","-H","Content-Type: application/json","Authorization: Bearer","-d","\"model\": \"perplexity/sonar-pro\",","\"messages\": [{\"role\": \"user\", \"content\": \"Hello!\"}]","package","main","context","fmt","os","github.com/sashabaranov/go-openai","func","()","cfg := openai","DefaultConfig","Getenv","))","cfg","BaseURL =","client := openai","NewClientWithConfig","resp","_ := client","CreateChatCompletion","Background","(),","ChatCompletionRequest","Model","Messages","[]","ChatCompletionMessage","Role","ChatMessageRoleUser","Content","},","Println","Choices","Message","More from Perplexity","Sonar","127K","Sonar is lightweight, affordable, fast, and simple to use โ€” now featuring citations and the ability to customize sources. It is designed for companies seeking to integrate lightweight question-and-answer features...","Sonar Deep Research","128K","Sonar Deep Research is a research-focused model designed for multi-step retrieval, synthesis, and reasoning across complex topics. It autonomously searches, reads, and evaluates sources, refining its approach as it gathers...","Sonar Pro Search","Exclusively available on the OpenRouter API, Sonar Pro's new Pro Search mode is Perplexity's most advanced agentic search system. It is designed for deeper reasoning and analysis. Pricing is based...","Sonar Reasoning Pro","Note: Sonar Pro pricing includes Perplexity search pricing. See [details here](https://docs.perplexity.ai/guides/pricing#detailed-pricing-breakdown-for-sonar-reasoning-pro-and-sonar-pro) Sonar Reasoning Pro is a premier reasoning model powered by DeepSeek R1 with Chain of Thought (CoT). Designed for...","View all Perplexity models โ†’","Use Sonar Pro via Hanzo AI","One API key. Every major model. OpenAI-compatible. Start free.","Get an API key","Browse All Models"],"links":["/models","/models/perplexity","https://platform.hanzo.ai/api-keys","/chat","/models/perplexity/sonar","/models/perplexity/sonar-deep-research","/models/perplexity/sonar-pro-search","/models/perplexity/sonar-reasoning-pro"]}