openapi.json

Developers

API reference

Call the SanDeals REST API from any HTTP client. Search deals, browse the catalog and read site metadata.

Base URL
https://www.sandeals.net
  • OpenAPI 3.1.0
  • Version 1.1.0
  • Auth: None
  • JSON

Specwww.sandeals.net/openapi.json

Overview

The REST API returns the same public deal catalog as the MCP server. Use searchDeals for natural-language requests and listDeals to browse a category. Results contain only values from the catalog; never present codes or discounts that are not in the response.

To use the API from ChatGPT, create a Custom GPT, open Actions, choose Import from URL and paste https://www.sandeals.net/openapi.json. Set Authentication to None. The operation to call is searchDeals.

Authentication

No API key or account is required. Requests are anonymous and the API is read-only. Responses allow cross-origin requests (Access-Control-Allow-Origin: *).

Rate limits

Search endpoints and the MCP server share a budget of 60 requests per minute per client and a global budget per minute. A request over the budget returns 429 Too Many Requests with a Retry-After header in seconds. Wait that long before retrying.

Errors

Errors use standard HTTP status codes and a JSON body with ok: false.

400The query is missing or invalid.
413The request body is larger than 16 KB.
429Rate limit reached. Retry after the number of seconds in Retry-After.
503Search is temporarily unavailable. Retry after 60 seconds.

Search deals on SanDeals.net

GET/api/search-advancedsearchDeals

Searches the catalog for discount codes, vouchers and deals. Use it when the user asks for deals or coupons from SanDeals or online stores. Returns structured JSON with each deal's title, href (deal link), category and summary.

Query parameters

NameTypeDescription
qRequiredstringA keyword or a natural-language request, for example coffee, giày, voucher or ưu đãi cafe.min length 1
limitintegerMaximum number of results, from 1 to 50. Defaults to 10.1–50 · default 10

Responses

200Structured deal search resultsAgentSearchResponse
400Missing queryErrorResponse

Try it

Send a real request from your browser. Edit the values, then select Send request. Requests count toward the limit of 60 per minute.

cURL
curl 'https://www.sandeals.net/api/search-advanced?q=coffee&limit=10'
200 response
{
  "ok": true,
  "query": "coffee",
  "total": 1,
  "results": [
    {
      "title": "Example Cafe",
      "href": "https://slink.sandeals.net/example",
      "category": "food",
      "summary": "Example cafe deals",
      "score": 13,
      "source": "deals"
    }
  ],
  "response": "Found 1 deal for \"coffee\":\n1. Example Cafe — https://slink.sandeals.net/example",
  "meta": {
    "mode": "agent",
    "language": "en",
    "matched": true
  }
}

Search deals (POST, agent mode)

POST/api/search-advancedsearchDealsPost

Runs the same search as searchDeals with the query in a JSON body. Set mode to agent to get structured JSON. For ChatGPT Actions, use searchDeals (GET).

Request body

NameTypeDescription
queryRequiredstringThe search query.
modeenumSet to agent to get structured results.agent · ui · default agent
limitinteger1–50 · default 10

Responses

200Structured deal search resultsAgentSearchResponse

Try it

Send a real request from your browser. Edit the values, then select Send request. Requests count toward the limit of 60 per minute.

cURL
curl -X POST 'https://www.sandeals.net/api/search-advanced' \
  -H "Content-Type: application/json" \
  -d '{"query":"coffee deals","limit":10,"mode":"agent"}'
200 response
{
  "ok": true,
  "query": "string",
  "total": 1,
  "results": [
    {
      "title": "string",
      "href": "https://www.sandeals.net/",
      "category": "string",
      "summary": "string",
      "score": 1,
      "source": "deals"
    }
  ],
  "response": "string",
  "meta": {
    "mode": "string",
    "language": "string",
    "response_time_ms": 1,
    "matched": true,
    "fallback": true
  }
}

List or filter the deals catalog

GET/api/dealslistDeals

Lists deals from the catalog, filtered by category or keyword. Use it to browse a category such as food, shopping or tech. For natural-language requests, use searchDeals.

Query parameters

NameTypeDescription
categoryenumall · books · shopping · travel · food · tech · lifestyle · education · default all
searchstringKeyword to match against deal titles and summaries.
qstringAlias for search.
limitintegermax 200 · default 100

Responses

200Deal catalogobject

Try it

Send a real request from your browser. Edit the values, then select Send request. Requests count toward the limit of 60 per minute.

cURL
curl 'https://www.sandeals.net/api/deals?category=all&limit=100'
200 response
{
  "ok": true,
  "deals": [
    {
      "title": "string",
      "href": "string",
      "category": "string",
      "summary": "string"
    }
  ],
  "total": 1,
  "categories": [
    "string"
  ]
}

Get SanDeals agent discovery metadata

GET/api/llmsgetSiteMetadata

Returns the site's capabilities, categories, agent instructions and API links. Call it first if you need to learn about SanDeals before searching.

Responses

200Site and API metadata for agentsobject

Try it

Send a real request from your browser. Edit the values, then select Send request. Requests count toward the limit of 60 per minute.

cURL
curl 'https://www.sandeals.net/api/llms'
200 response
{}

Schemas

Objects returned by the endpoints above.

DealResult

NameTypeDescription
titleRequiredstring
hrefRequiredstring (uri)URL of the deal or its smart link.
categoryRequiredstring
summarystring | null
scorenumber
sourceenumdeals · products

Deal

NameTypeDescription
titlestring
hrefstring
categorystring
summarystring | null

AgentSearchResponse

NameTypeDescription
okRequiredboolean
queryRequiredstring
totalRequiredinteger
resultsRequiredDealResult[]
responsestringA short, human-readable summary of the results.
metaobject

ErrorResponse

NameTypeDescription
okboolean
errorobject
resultsobject[]
totalinteger

Next steps

You know the endpoints. Next, connect an agent or import the spec.