Skip to content

Search

This quickstart walks you through generating your first search with Siraya AI.

Tavily

from tavily import TavilyClient

tavily_client = TavilyClient(
    api_key="<API_KEY>",
    api_base_url="https://search.siraya.pro/v1/tavily"
)
response = tavily_client.search("Who is Leo Messi?")

print(response)

tavily

Jina

import json
import requests

response = requests.post(
    "https://search.siraya.pro/v1/chat/completions",
    headers={"Authorization":"text","Content-Type":"application/json"},
    data=json.dumps({
      "model": "jina-deepsearch-v1",
      "messages": [
        {
          "role": "user",
          "content": "Hi!"
        },
        {
          "role": "assistant",
          "content": "Hi, how can I help you?"
        },
        {
          "role": "user",
          "content": "what's the latest blog post from jina ai?"
        }
      ],
      "stream": True
    })
)

data = response.json()

jina

Firecrawl

import json
import requests

response = requests.post(
    "https://search.siraya.pro/v1/firecrawl",
    headers={"Authorization":"text","Content-Type":"application/json"},
    data=json.dumps({
      "model": "firecrawl-search",
      "query": "who is Leo Messi?",
    })
)

data = response.json()

firecrawl

Perplexity

import json
import requests

response = requests.post(
    "https://search.siraya.pro/v1/perplexity",
    headers={"Authorization":"text","Content-Type":"application/json"},
    data=json.dumps({
      "model": "perplexity-search",
      "query": "latest AI developments 2024",
      "max_results": 10,
      "search_domain_filter": [
        "science.org",
        "pnas.org",
        "cell.com"
      ],
      "max_tokens_per_page": 1024,
      "country": "US",
      "search_recency_filter": "week",
      "search_after_date": "10/15/2025",
      "search_before_date": "10/16/2025"
    })
)

data = response.json()

perplexity

Exa

import json
import requests

response = requests.post(
    "https://search.siraya.pro/v1/exa",
    headers={"Authorization":"text","Content-Type":"application/json"},
    data=json.dumps({
      "model": "exa-search",
      "query": "Latest research in LLMs",
      "additionalQueries": [
        "LLM advancements",
        "large language model progress"
      ],
      "type": "auto",
      "category": "news",
      "userLocation": "US",
      "numResults": 100,
      "excludeDomains": [
        "baidu.com"
      ],
      "startCrawlDate": "2023-01-01T00:00:00.000Z",
      "endCrawlDate": "2023-12-31T00:00:00.000Z",
      "startPublishedDate": "2023-01-01T00:00:00.000Z",
      "endPublishedDate": "2023-12-31T00:00:00.000Z",
      "includeText": [
        "large language model"
      ],
      "excludeText": [
        "course"
      ],
      "context": True,
      "moderation": False
    })
)

data = response.json()

exa

Cloudsway

import json
import requests

response = requests.post(
    "https://search.siraya.pro/v1/cloudsway",
    headers={"Authorization":"text","Content-Type":"application/json"},
    data=json.dumps({
      "model": "cloudsway-smart-search",
      "q": "Latest research in LLMs",
      "count": 10,
      "offset": 0,
      "freshness": "Month",
      "sites": "baidu.com, google.com",
      "enableContent": True,
      "contentType": "TEXT",
      "contentTimeout": 3,
      "mainText": False
    })
)

data = response.json()

cloudsway