Laalaa Docs

JavaScript

No SDK required — plain fetch().

Base URL for this toolhttps://api.laalaa.me/v1
Protocol/v1/chat/completions (OpenAI)

fetch() — Node 18+ / Bun / Deno

javascript
const res = await fetch("https://api.laalaa.me/v1/chat/completions", {  method: "POST",  headers: {    Authorization: "Bearer sk-xxxxxxxxxxxx",    "Content-Type": "application/json",  },  body: JSON.stringify({    model: "claude-opus-4-8",    messages: [{ role: "user", content: "Hello" }],  }),});const data = await res.json();console.log(data.choices[0].message.content);

Keep the key server-side

Never ship your key in a browser bundle

Anything in browser code is readable — call the gateway from your own backend and let the frontend talk to your backend.

Other tools

ទំព័រនេះមានប្រយោជន៍?