---
title: "Update search widget configuration"
method: POST
path: "/workspace/{workspaceId}/search"
tags: ["Workspace"]
---

# Update search widget configuration

`POST /workspace/{workspaceId}/search`

## Request

- Base URL: `https://api.savanto.ai`
- URL: `https://api.savanto.ai/workspace/{workspaceId}/search`
- Auth: HTTP bearer

## Path parameters

- `workspaceId` string, required

## Request body

- object
  - `enabled` boolean
  - `showTrigger` boolean
  - `triggerPosition` 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left'
  - `keyboardShortcut` string
  - `searchProducts` boolean
  - `searchPosts` boolean
  - `resultLayout` 'stacked' | 'tabbed'
  - `searchOnSubmit` boolean
  - `askAssistant` boolean
  - `askAssistantLabel` string
  - `productTabLabel` string
  - `postTabLabel` string
  - `inputPlaceholder` string
  - `theme` object
    - `colorScheme` 'light' | 'dark' | 'auto'
    - `primaryColor` string
    - `darkPrimaryColor` string
    - `trigger` object
      - `background` string
      - `textColor` string
      - `borderColor` string
      - `darkBackground` string
      - `darkTextColor` string
      - `darkBorderColor` string
      - `iconUrl` union
        - string, uri
        - ''
  - `customCSS` string

## Response `201`

Updated search config

- object
  - `object` 'widget_config', required
  - `requestId` string, required
  - `data` object, required
    - `config` object, required

## Other responses

- `400`: Validation error
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not found
- `409`: Conflict
- `413`: Payload too large
- `429`: Rate limit exceeded

---

[API](https://skmtc.dev/savanto/apis/savanto-api.md) · [All operations](https://skmtc.dev/savanto/apis/savanto-api/llms.txt) · [OpenAPI document](https://skmtc.dev/savanto/apis/savanto-api/revisions/82437327a878?raw)
