Skip to main content
POST
/
search
/
v1
/
answer
curl -X POST "https://api.case.dev/search/v1/answer" \ -H "Authorization: Bearer $CASEDEV_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "query": "<string>" }'
{
  "answer": "<string>",
  "citations": [
    {
      "id": "<string>",
      "url": "<string>",
      "title": "<string>",
      "publishedDate": "<string>",
      "text": "<string>"
    }
  ],
  "model": "<string>",
  "searchType": "<string>"
}

Documentation Index

Fetch the complete documentation index at: https://docs.case.dev/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

API key starting with sk_case_

Body

application/json

Answer generation configuration

query
string
required

The question or topic to research and answer

useCustomLLM
boolean
default:false

Use Case.dev LLM for answer generation instead of provider's native answer

model
string
default:gpt-4o

LLM model to use when useCustomLLM is true

searchType
enum<string>
default:auto

Type of search to perform

Available options:
auto,
web,
news,
academic
numResults
integer
default:10

Number of search results to consider

Required range: 1 <= x <= 50
includeDomains
string[]

Only search within these domains

excludeDomains
string[]

Exclude these domains from search

temperature
number
default:0.3

LLM temperature for answer generation

Required range: 0 <= x <= 2
maxTokens
integer
default:2048

Maximum tokens for LLM response

text
boolean
default:true

Include text content in response

stream
boolean
default:false

Stream the response (only for native provider answers)

Response

Answer generated successfully

answer
string

The generated answer with citations

citations
object[]

Sources used to generate the answer

model
string

Model used for answer generation

searchType
string

Type of search performed