Quick Start
Introduction
Getting Started
API Example
fetch("https://ai.api.4everland.org/api/v1/chat/completions", {
method: "POST",
headers: {
"Authorization": `Bearer ${YOUR_API_KEY}`,
"HTTP-Referer": `${YOUR_SITE_URL}`, // Optional
"X-Title": `${YOUR_SITE_NAME}`, // Optional
"Content-Type": "application/json"
},
body: JSON.stringify({
"model": "google/gemini-pro-1.5",//choose a model
"messages": [
{"role": "user", "content": "What is the meaning of life?"},
],
"top_p:" 1, //Optional parameter
"temperature:" 1, //Optional parameter
"repetition_penalty:" 1, //Optional parameter
})
});Open AI
Last updated