← Back to Perplexity
Sonar Chat Completions API
Creates an asynchronous chat completion job.
Perplexity·$0.01 per call
Example code
// Using @orth/sdk - The simplest way to call APIs
// Install: npm install @orth/sdk
import Orthogonal from "@orth/sdk";
const orthogonal = new Orthogonal({
apiKey: process.env.ORTHOGONAL_API_KEY,
});
const output = await orthogonal.run({
api: "perplexity",
path: "/async/chat/completions"
});
console.log(output);Body parameters
request
object
required Show child attributes