GET
/
search
Search
curl --request GET \
  --url https://api.marzipan.co/v1/search \
  --header 'Authorization: Bearer <token>'
{
  "query": "malbec",
  "total_results": 3,
  "results": {
    "products": [
      {
        "id": "2e2805a1-738e-4118-8a8b-f9431f0e210c",
        "type": "product",
        "title": "Cellar Selection Malbec",
        "slug": "cellar-selection-malbec-2015",
        "url": "https://api.marzipan.co/products/cellar-selection-malbec-2015",
        "excerpt": "Premium Malbec with rich, full-bodied flavor profile and notes of dark fruit",
        "image": {
          "id": "0736c529-a33d-4b8c-8126-eb69779dcdad",
          "path": "1/0736c529-a33d-4b8c-8126-eb69779dcdad.jpg",
          "src": "https://marzipan-cloud-dev.b-cdn.net/1/0736c529-a33d-4b8c-8126-eb69779dcdad.jpg",
          "alt": "Cellar Selection Malbec 2015 bottle",
          "mimeType": "image/jpeg",
          "filename": "0736c529-a33d-4b8c-8126-eb69779dcdad.jpg"
        },
        "price": "£24.99",
        "status": "active"
      }
    ],
    "pages": [
      {
        "id": "page-wine-guide",
        "type": "page",
        "title": "Malbec Wine Guide",
        "slug": "malbec-wine-guide",
        "url": "https://api.marzipan.co/pages/malbec-wine-guide",
        "excerpt": "Learn about Malbec wines, their origins, flavor profiles, and perfect food pairings",
        "image": null,
        "price": null,
        "status": "published"
      }
    ],
    "collections": [
      {
        "id": "885ea507-690b-4598-a8fc-095c0528be24",
        "type": "collection",
        "title": "Red Wine Collection",
        "slug": "red-wines",
        "url": "https://api.marzipan.co/collections/red-wines",
        "excerpt": "Our carefully curated selection of premium red wines including Malbec, Cabernet, and more",
        "image": {
          "id": "1b978a90-3ecb-4f37-b480-9fb81882176e",
          "src": "https://marzipan-cloud-dev.b-cdn.net/1/1b978a90-3ecb-4f37-b480-9fb81882176e.jpg",
          "alt": "Red wine collection"
        },
        "price": null,
        "status": "active"
      }
    ],
    "events": [],
    "subscription_packages": []
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your API token.

Query Parameters

query
string
required

Search term to find matching content

Minimum length: 1
type
enum<string>

Filter results by content type. If not specified, searches all types

Available options:
products,
pages,
collections,
events,
subscription_packages
limit
integer
default:10

Maximum number of results to return per type

Required range: 1 <= x <= 50

Response

200
application/json

Search results

The response is of type object.