Logoja e SHANNON A.I.
SHANNON A.I.
Bisedë Çmimet API Hulumtim Kompania Pentest AI Nxitja e fillimit
Identifikohu
Plani & Përdorimi
Bisedë Çmimet API Hulumtim Kompania Pentest AI Nxitja e fillimit Identifikohu Plani & Përdorimi

Zgjidh gjuhën tënde

Të gjitha gjuhët janë të barabarta. Zgjidh atë që dëshiron të përdorësh.

Dokumentacion API

Shannon API

API i pajtueshëm me OpenAI dhe Anthropic me thirrje funksionesh, kërkim në ueb dhe dalje të strukturuara.

Merr çelësin tënd API Provo Playground V2
Dokumentacion
  • OV Përmbledhje
  • CP Aftësitë
  • QS Fillim i shpejtë
  • PG API Playground E re
  • AU Autentikim
  • ML Modelet
  • FN Thirrje funksionesh
  • JS Dalje të strukturuara
  • SS Transmetim
  • WS Kërkim i integruar në ueb
  • AN Formati Anthropic
  • SD SDK
  • ER Trajtimi i gabimeve
  • CL Ndryshime
  • AK Çelësi yt API
  • US Përdorimi yt

Shannon AI API Documentation

Përmbledhje

Dokumentacion publik

Gjithçka që ju nevojitet për të publikuar me API-në e pajtueshme me OpenAI dhe Anthropic të Shannon.

URL bazë I pajtueshëm me OpenAI
https://api.shannon-ai.com/v1/chat/completions

Përdorni API Chat Completions me thirrje funksionesh dhe streaming.

URL bazë I pajtueshëm me Anthropic
https://api.shannon-ai.com/v1/messages

Formati Claude Messages me mjete dhe header anthropic-version.

HTTP Autentikim
Authorization: Bearer <api-key>

Ose X-API-Key me anthropic-version për thirrje në stilin Claude.

Akses Statusi
Dokumentacion publik - çelësi kërkohet për thirrje

Streaming, thirrje funksionesh, dalje të strukturuara, kërkim në ueb.

Lista e nisjes
  • +
    Drejto SDK-në tënde te Shannon
    Vendos baseURL në endpoint-et OpenAI ose Anthropic më lart.
    Konfigurim
  • +
    Shto çelësin tënd API
    Përdor tokenë Bearer për thirrjet OpenAI ose X-API-Key + anthropic-version.
    Siguri
  • +
    Aktivizo mjetet dhe daljet e strukturuara
    Mbështet mjetet/funksionet OpenAI, skemën JSON dhe web_search të integruar.
    Aftësi
  • +
    Ndiq përdorimin
    Shiko konsumimin e tokenëve dhe kërkimeve në këtë faqe kur je i identifikuar.
    Analitikë

Aftësitë

OpenAI + Anthropic

Zëvendësim plug-and-play për API-të OpenAI dhe Anthropic me mbështetje native për mjete, dalje të strukturuara dhe kërkim të integruar në ueb.

AI

Zëvendësim i menjëhershëm

Kompatibil

Punon me SDK-të OpenAI dhe Anthropic. Thjesht ndrysho URL-në bazë.

AI

Thirrje funksionesh

Mjete

Përcakto mjete, lëre Shannon t’i thërrasë. Mbështet mënyrat auto, forced dhe none.

AI

Kërkim i integruar në ueb

Kërkim

Kërkim në kohë reale me citime burimesh. Automatikisht i disponueshëm.

AI

Dalje të strukturuara

JSON

Modaliteti JSON dhe zbatimi i skemës JSON për nxjerrje të besueshme të të dhënave.

AI

Mjete me shumë rrotullime

Agjentik

Cikle automatike ekzekutimi funksionesh. Deri në 10 iteracione për kërkesë.

AI

Transmetim

Shpejt

Server-sent events për transmetim tokenësh në kohë reale.

Fillim i shpejtë

5 minuta

Nisuni në tre hapa. Shannon pasqyron klientët OpenAI dhe Anthropic.

1

Vendos URL-në bazë

Përdor endpoint-in e pajtueshëm me OpenAI.

https://api.shannon-ai.com/v1/chat/completions
2

Shto çelësin tënd API

Përdor Bearer auth në header Authorization.

3

Dërgo mesazhin tënd të parë

Zgjidh një gjuhë dhe zëvendëso çelësin tënd.

Python
from openai import OpenAI

client = OpenAI(
    api_key="YOUR_API_KEY",
    base_url="https://api.shannon-ai.com/v1"
)

response = client.chat.completions.create(
    model="shannon-1.6-lite",
    messages=[
        {"role": "system", "content": "You are a helpful assistant."},
        {"role": "user", "content": "Hello, Shannon!"}
    ],
    max_tokens=1024
)

print(response.choices[0].message.content)
JavaScript
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: 'YOUR_API_KEY',
  baseURL: 'https://api.shannon-ai.com/v1'
});

const response = await client.chat.completions.create({
  model: 'shannon-1.6-lite',
  messages: [
    { role: 'system', content: 'You are a helpful assistant.' },
    { role: 'user', content: 'Hello, Shannon!' }
  ],
  max_tokens: 1024
});

console.log(response.choices[0].message.content);
Go
package main

import (
    "context"
    "fmt"
    openai "github.com/sashabaranov/go-openai"
)

func main() {
    config := openai.DefaultConfig("YOUR_API_KEY")
    config.BaseURL = "https://api.shannon-ai.com/v1"
    client := openai.NewClientWithConfig(config)

    resp, err := client.CreateChatCompletion(
        context.Background(),
        openai.ChatCompletionRequest{
            Model: "shannon-1.6-lite",
            Messages: []openai.ChatCompletionMessage{
                {Role: "system", Content: "You are a helpful assistant."},
                {Role: "user", Content: "Hello, Shannon!"},
            },
            MaxTokens: 1024,
        },
    )
    if err != nil {
        panic(err)
    }
    fmt.Println(resp.Choices[0].Message.Content)
}
cURL
curl -X POST "https://api.shannon-ai.com/v1/chat/completions" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "shannon-1.6-lite",
    "messages": [
      {"role": "system", "content": "You are a helpful assistant."},
      {"role": "user", "content": "Hello, Shannon!"}
    ],
    "max_tokens": 1024
  }'

Formati i përgjigjes

Përgjigje e suksesshme
{
  "id": "chatcmpl-abc123",
  "object": "chat.completion",
  "created": 1234567890,
  "model": "Shannon 1.6 Lite",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": "Hello! I'm Shannon, your AI assistant. How can I help you today?"
      },
      "finish_reason": "stop"
    }
  ],
  "usage": {
    "prompt_tokens": 25,
    "completion_tokens": 18,
    "total_tokens": 43
  }
}

API Playground

E re

Testo Shannon API direkt në shfletues. Ndërto kërkesën, ekzekutoje dhe shiko përgjigjen në kohë reale.

1

Chat, Responses, Messages

Switch across OpenAI Chat Completions, Responses, and Anthropic Messages without leaving the playground.

2

Stream live output

Run real requests, inspect raw JSON, and view stream events from the same operator console.

3

Reuse your key

Signed-in users can pull their Shannon API key straight into the dedicated playground workspace.

/sq/docs/playground

The playground now lives on its own route so the API docs stay Astro-rendered while the request builder remains an explicitly interactive client tool.

Provo Playground V2 Merr çelësin tënd API

Autentikim

Të gjitha kërkesat API kërkojnë autentikim duke përdorur çelësin tënd Shannon API.

Formati OpenAI (i rekomanduar)

HTTP
Authorization: Bearer YOUR_API_KEY

Formati Anthropic

HTTP
X-API-Key: YOUR_API_KEY
anthropic-version: 2023-06-01

Modelet

Shannon ofron disa modele të optimizuara për përdorime të ndryshme.

AI
shannon-1.6-lite Shannon 1.6 Lite

Përgjigje të shpejta dhe efikase për detyra të përditshme

Konteksti 128K
Më i miri për Bisedë, Pyetje-Përgjigje, Gjenerim Përmbajtjeje
AI
shannon-1.6-pro Shannon 1.6 Pro

Arsyetim i avancuar për probleme komplekse

Konteksti 128K
Më i miri për Analizë, Kërkim, Detyra komplekse
AI
shannon-2-lite Shannon 2 Lite

Konteksti 128K
Më i miri për
AI
shannon-2-pro Shannon 2 Pro

Konteksti 128K
Më i miri për
AI
shannon-coder-1 Shannon Coder

Optimizuar për Claude Code CLI me kuotë sipas thirrjes

Konteksti 128K
Më i miri për Gjenerim kodi, Përdorim mjetesh, Integrim CLI
Kuotë sipas thirrjes

Thirrje funksionesh

Përcakto mjete që Shannon mund t’i thërrasë për të kryer veprime ose për të marrë informacion.

Python
from openai import OpenAI
import json

client = OpenAI(
    api_key="YOUR_API_KEY",
    base_url="https://api.shannon-ai.com/v1"
)

# Define available tools/functions
tools = [
    {
        "type": "function",
        "function": {
            "name": "get_weather",
            "description": "Get current weather for a location",
            "parameters": {
                "type": "object",
                "properties": {
                    "location": {
                        "type": "string",
                        "description": "City name, e.g., 'Tokyo'"
                    },
                    "unit": {
                        "type": "string",
                        "enum": ["celsius", "fahrenheit"]
                    }
                },
                "required": ["location"]
            }
        }
    }
]

response = client.chat.completions.create(
    model="shannon-1.6-lite",
    messages=[{"role": "user", "content": "What's the weather in Tokyo?"}],
    tools=tools,
    tool_choice="auto"
)

# Check if model wants to call a function
if response.choices[0].message.tool_calls:
    tool_call = response.choices[0].message.tool_calls[0]
    print(f"Function: {tool_call.function.name}")
    print(f"Arguments: {tool_call.function.arguments}")
JavaScript
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: 'YOUR_API_KEY',
  baseURL: 'https://api.shannon-ai.com/v1'
});

const tools = [
  {
    type: 'function',
    function: {
      name: 'get_weather',
      description: 'Get current weather for a location',
      parameters: {
        type: 'object',
        properties: {
          location: { type: 'string', description: "City name" },
          unit: { type: 'string', enum: ['celsius', 'fahrenheit'] }
        },
        required: ['location']
      }
    }
  }
];

const response = await client.chat.completions.create({
  model: 'shannon-1.6-lite',
  messages: [{ role: 'user', content: "What's the weather in Tokyo?" }],
  tools,
  tool_choice: 'auto'
});

if (response.choices[0].message.tool_calls) {
  const toolCall = response.choices[0].message.tool_calls[0];
  console.log('Function:', toolCall.function.name);
  console.log('Arguments:', toolCall.function.arguments);
}

Opsionet e zgjedhjes së mjetit

"auto" Modeli vendos nëse të thërrasë funksion (parazgjedhur)
"none" Çaktivizo thirrjen e funksioneve për këtë kërkesë
{"type": "function", "function": {"name": "..."}} Detyro një thirrje funksioni specifike

Përgjigja e thirrjes së funksionit

Kur modeli thërret një funksion
{
  "id": "chatcmpl-xyz",
  "choices": [
    {
      "index": 0,
      "message": {
        "role": "assistant",
        "content": null,
        "tool_calls": [
          {
            "id": "call_abc123",
            "type": "function",
            "function": {
              "name": "get_weather",
              "arguments": "{\"location\": \"Tokyo\", \"unit\": \"celsius\"}"
            }
          }
        ]
      },
      "finish_reason": "tool_calls"
    }
  ]
}

Dalje të strukturuara

Detyro Shannon të përgjigjet me JSON të vlefshëm që përputhet me skemën tënde.

Python
from openai import OpenAI

client = OpenAI(
    api_key="YOUR_API_KEY",
    base_url="https://api.shannon-ai.com/v1"
)

# Force JSON output with schema
response = client.chat.completions.create(
    model="shannon-1.6-lite",
    messages=[
        {"role": "user", "content": "Extract: John Doe, 30 years old, engineer"}
    ],
    response_format={
        "type": "json_schema",
        "json_schema": {
            "name": "person_info",
            "schema": {
                "type": "object",
                "properties": {
                    "name": {"type": "string"},
                    "age": {"type": "integer"},
                    "occupation": {"type": "string"}
                },
                "required": ["name", "age", "occupation"]
            }
        }
    }
)

import json
data = json.loads(response.choices[0].message.content)
print(data)  # {"name": "John Doe", "age": 30, "occupation": "engineer"}
JavaScript
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: 'YOUR_API_KEY',
  baseURL: 'https://api.shannon-ai.com/v1'
});

const response = await client.chat.completions.create({
  model: 'shannon-1.6-lite',
  messages: [
    { role: 'user', content: 'Extract: John Doe, 30 years old, engineer' }
  ],
  response_format: {
    type: 'json_schema',
    json_schema: {
      name: 'person_info',
      schema: {
        type: 'object',
        properties: {
          name: { type: 'string' },
          age: { type: 'integer' },
          occupation: { type: 'string' }
        },
        required: ['name', 'age', 'occupation']
      }
    }
  }
});

const data = JSON.parse(response.choices[0].message.content);
console.log(data); // { name: "John Doe", age: 30, occupation: "engineer" }

Opsionet e formatit të përgjigjes

{"type": "json_object"} Detyro dalje JSON të vlefshme (pa skemë specifike)
{"type": "json_schema", "json_schema": {...}} Detyro dalje që përputhet me skemën tënde të saktë

Transmetim

Aktivizo transmetimin e tokenëve në kohë reale me Server-Sent Events për UI të përgjegjshme.

Python
from openai import OpenAI

client = OpenAI(
    api_key="YOUR_API_KEY",
    base_url="https://api.shannon-ai.com/v1"
)

# Enable streaming for real-time responses
stream = client.chat.completions.create(
    model="shannon-1.6-lite",
    messages=[
        {"role": "user", "content": "Write a short poem about AI"}
    ],
    stream=True
)

for chunk in stream:
    if chunk.choices[0].delta.content:
        print(chunk.choices[0].delta.content, end="", flush=True)
JavaScript
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: 'YOUR_API_KEY',
  baseURL: 'https://api.shannon-ai.com/v1'
});

// Enable streaming for real-time responses
const stream = await client.chat.completions.create({
  model: 'shannon-1.6-lite',
  messages: [
    { role: 'user', content: 'Write a short poem about AI' }
  ],
  stream: true
});

for await (const chunk of stream) {
  const content = chunk.choices[0]?.delta?.content;
  if (content) process.stdout.write(content);
}
Këshillë: Përgjigjet stream vijnë si Server-Sent Events. Çdo pjesë përmban një delta me përmbajtje të pjesshme.

Kërkim i integruar në ueb

Shannon përfshin një funksion të integruar web_search që është automatikisht i disponueshëm.

Python
from openai import OpenAI

client = OpenAI(
    api_key="YOUR_API_KEY",
    base_url="https://api.shannon-ai.com/v1"
)

# Web search is automatically available!
# Shannon will use it when needed for current information

response = client.chat.completions.create(
    model="shannon-1.6-lite",
    messages=[
        {"role": "user", "content": "What are the latest AI news today?"}
    ],
    # Optionally, explicitly define web_search tool
    tools=[{
        "type": "function",
        "function": {
            "name": "web_search",
            "description": "Search the web for current information",
            "parameters": {
                "type": "object",
                "properties": {
                    "query": {"type": "string", "description": "Search query"}
                },
                "required": ["query"]
            }
        }
    }]
)

print(response.choices[0].message.content)
# Response includes sources and citations
JavaScript
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: 'YOUR_API_KEY',
  baseURL: 'https://api.shannon-ai.com/v1'
});

// Web search is automatically available!
// Shannon will use it when needed for current information

const response = await client.chat.completions.create({
  model: 'shannon-1.6-lite',
  messages: [
    { role: 'user', content: 'What are the latest AI news today?' }
  ],
  // Optionally, explicitly define web_search tool
  tools: [{
    type: 'function',
    function: {
      name: 'web_search',
      description: 'Search the web for current information',
      parameters: {
        type: 'object',
        properties: {
          query: { type: 'string', description: 'Search query' }
        },
        required: ['query']
      }
    }
  }]
});

console.log(response.choices[0].message.content);
// Response includes sources and citations
Këshillë Pro: Rezultatet e kërkimit në ueb përfshijnë citime. Shannon do të citojë automatikisht burimet.

Formati Anthropic

Shannon mbështet gjithashtu formatin Anthropic Messages API.

https://api.shannon-ai.com/v1/messages
Python
import anthropic

client = anthropic.Anthropic(
    api_key="YOUR_API_KEY",
    base_url="https://api.shannon-ai.com/messages"
)

response = client.messages.create(
    model="shannon-1.6-lite",
    max_tokens=1024,
    messages=[
        {"role": "user", "content": "Hello, Shannon!"}
    ],
    # Tool use (Anthropic format)
    tools=[{
        "name": "web_search",
        "description": "Search the web",
        "input_schema": {
            "type": "object",
            "properties": {
                "query": {"type": "string"}
            },
            "required": ["query"]
        }
    }]
)

print(response.content[0].text)
JavaScript
import Anthropic from '@anthropic-ai/sdk';

const client = new Anthropic({
  apiKey: 'YOUR_API_KEY',
  baseURL: 'https://api.shannon-ai.com/messages'
});

const response = await client.messages.create({
  model: 'shannon-1.6-lite',
  max_tokens: 1024,
  messages: [
    { role: 'user', content: 'Hello, Shannon!' }
  ],
  // Tool use (Anthropic format)
  tools: [{
    name: 'web_search',
    description: 'Search the web',
    input_schema: {
      type: 'object',
      properties: {
        query: { type: 'string' }
      },
      required: ['query']
    }
  }]
});

console.log(response.content[0].text);
Header i kërkuar: Formati Anthropic kërkon anthropic-version: 2023-06-01.

SDK

Kompatibil

Përdor çdo SDK OpenAI ose Anthropic — thjesht ndrysho URL-në bazë.

SDK të pajtueshme me OpenAI

SDK Python

SDK zyrtar OpenAI Python - funksionon me Shannon

pip install openai
Shiko dokumentet ->
SDK JavaScript / TypeScript

SDK zyrtar OpenAI Node.js - funksionon me Shannon

npm install openai
Shiko dokumentet ->
SDK Go

Klient Go nga komuniteti për API të pajtueshme me OpenAI

go get github.com/sashabaranov/go-openai
Shiko dokumentet ->
SDK Ruby

Klient Ruby nga komuniteti për API të pajtueshme me OpenAI

gem install ruby-openai
Shiko dokumentet ->
SDK PHP

Klient PHP nga komuniteti për API të pajtueshme me OpenAI

composer require openai-php/client
Shiko dokumentet ->
SDK Rust

Klient Rust asinkron për API të pajtueshme me OpenAI

cargo add async-openai
Shiko dokumentet ->

SDK të pajtueshme me Anthropic

SDK Python (Anthropic)

SDK zyrtar Anthropic Python - funksionon me Shannon

pip install anthropic
Shiko dokumentet ->
SDK TypeScript (Anthropic)

SDK zyrtar Anthropic TypeScript - funksionon me Shannon

npm install @anthropic-ai/sdk
Shiko dokumentet ->

Trajtimi i gabimeve

Shannon përdor kode standarde statusi HTTP dhe kthen mesazhe të detajuara gabimi.

400 Kërkesë e keqe Formati i kërkesës ose parametrat janë të pavlefshëm
401 I paautorizuar Çelës API i pavlefshëm ose mungon
402 Kuota e tejkaluar Kuota e tokenëve ose kërkimeve u tejkalua
429 E kufizuar Shumë kërkesa, ngadalësoni
500 Gabim serveri Gabim i brendshëm, provoni më vonë

Formati i përgjigjes së gabimit

Përgjigje gabimi
{
  "error": {
    "message": "Invalid API key provided",
    "type": "authentication_error",
    "code": "invalid_api_key"
  }
}

Ndryshime

LOG

Përditësime dhe përmirësime të fundit të Shannon API.

v2.1.0
2025-01-03
  • E re U shtua modeli shannon-coder-1 për integrimin me Claude Code CLI
  • E re Sistem kuotash sipas thirrjes për modelin Coder
  • E përmirësuar U përmirësua besueshmëria e thirrjes së funksioneve
v2.0.0
2024-12-15
  • E re U shtua pajtueshmëria me Anthropic Messages API
  • E re Ekzekutim mjetesh me shumë rrotullime (deri në 10 iteracione)
  • E re Mbështetje për formatin e përgjigjes JSON Schema
  • E përmirësuar Kërkim në ueb i përmirësuar me citime më të mira
v1.5.0
2024-11-20
  • E re U shtua modeli shannon-deep-dapo për arsyetim kompleks
  • E re Funksion i integruar web_search
  • E përmirësuar U ul vonesa për përgjigje streaming
v1.0.0
2024-10-01
  • E re Publikimi fillestar i API
  • E re Endpoint i pajtueshëm me OpenAI chat completions
  • E re Mbështetje për thirrje funksionesh
  • E re Streaming përmes Server-Sent Events

Çelësi yt API

Akses
Përdor tokenë Bearer për thirrjet OpenAI ose X-API-Key + anthropic-version.
YOUR_API_KEY
Merr çelësin tënd API

Mbaje çelësin tënd API sekret. Rigjenerimi krijon një çelës të ri dhe e bën të vjetrin të pavlefshëm.

Versioni: 1
Rrotulluar së fundi: Kurrë
Përdorur së fundi: Kurrë

Përdorimi yt

Shiko konsumimin e tokenëve dhe kërkimeve në këtë faqe kur je i identifikuar.

-- Thirrjet API
-- Tokenë të përdorur

Shannon Coder (shannon-coder-1)

Kuotë sipas thirrjes për Shannon Coder (shannon-coder-1). Riniset çdo 4 orë.

0 Thirrje të përdorura
0 Thirrje të mbetura

Gati për të ndërtuar?

Merr çelësin tënd API dhe fillo të ndërtosh me Shannon AI sot.

Merr çelësin tënd API Shiko çmimet

Kërkime të njohura:

Provo fjalë kyçe të tjera
Lëviz: ↑ ↓ Zgjidh: Enter Mbyll: Esc