---
title: "Update Widget Styles"
method: PUT
path: "/api/products/{product_id}/widget-styles"
tags: ["products"]
---

# Update Widget Styles

`PUT /api/products/{product_id}/widget-styles`

## Request

- Base URL: `https://api.usecrow.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.usecrow.ai/api/products/{product_id}/widget-styles`
- Auth: none declared
- TypeScript: <https://skmtc.dev/usecrow/apis/crow-backend-multi-tenant-saas/docs/api/products/:product_id/widget-styles/put.ts> (a function with typed inputs; its response is checked against the schema)

Update widget styles for a product

Accepts a partial or complete WidgetStyleConfig object.
The styles are stored as JSONB and merged with defaults on the client side.

## Path parameters

- `product_id` string, required

## Headers

- `authorization` string, nullable

## Request body

- UpdateWidgetStylesRequest: Request model for updating widget styles
  - `styles` WidgetStyleConfig, required: Complete widget style configuration. All fields are optional - only specified fields override defaults. This allows partial updates and deep merging with defaults.
    - `colors` ColorsConfig: Color configuration shared between widget and copilot
      - `primary` string, nullable
      - `background` string, nullable
      - `text` string, nullable
      - `border` string, nullable
      - `botBubble` string, nullable
      - `botText` string, nullable
      - `userBubble` string, nullable
      - `userText` string, nullable
      - `userBorder` string, nullable
      - `messagesBackground` string, nullable
      - `bubbleBackground` string, nullable
      - `bubbleBorder` string, nullable
      - `bubbleIcon` string, nullable
    - `typography` TypographyConfig: Typography configuration
      - `fontFamily` string, nullable
      - `fontSize` integer, nullable
      - `headerFontSize` integer, nullable
      - `fontWeight` integer, nullable
      - `lineHeight` number, nullable
      - `letterSpacing` number, nullable
    - `animations` AnimationsConfig: Animation configuration
      - `duration` number, nullable
      - `easing` string, nullable
    - `dimensions` WidgetDimensionsConfig: Widget dimension configuration
      - `width` integer, nullable
      - `maxHeight` integer, nullable
      - `borderRadius` integer, nullable
      - `padding` integer, nullable
      - `messagesMaxHeight` integer, nullable
    - `position` WidgetPositionConfig: Widget position configuration (floating mode)
      - `right` integer, nullable
      - `bottom` integer, nullable
      - `bubbleRight` integer, nullable
      - `bubbleBottom` integer, nullable
    - `bubble` WidgetBubbleConfig: Chat bubble button configuration
      - `size` integer, nullable
      - `iconSize` integer, nullable
      - `background` string, nullable
      - `border` string, nullable
      - `iconColor` string, nullable
      - `label` string, nullable
    - `shadows` WidgetShadowsConfig: Shadow configuration for widget
      - `widget` string, nullable
      - `bubble` string, nullable
    - `branding` WidgetBrandingConfig: Branding configuration for widget
      - `showPoweredBy` boolean, nullable
      - `poweredByText` string, nullable
      - `showLogo` boolean, nullable
      - `logoUrl` string, nullable
    - `customCss` string, nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/usecrow/apis/crow-backend-multi-tenant-saas.md) - [All operations](https://skmtc.dev/usecrow/apis/crow-backend-multi-tenant-saas/llms.txt) - [OpenAPI document](https://skmtc.dev/usecrow/apis/crow-backend-multi-tenant-saas/revisions/b2950af46532?raw)
