Ana içeriğe geç

Widget Stili Oluştur

Mevcut node için bir stil ön ayarı oluşturur. Dönen id, widget'a widgetStyleId olarak verilen değerdir.

Kimlik Doğrulama: Bearer token gereklidir.

Endpoint: POST /api/v2/widget-styles


İstek Gövdesi

AlanTipZorunluAçıklama
namestringEvetmin 1, max 255. Node bazında benzersiz
primary_colorstringEvetmax 32. CSS renk (#3b82f6, rgb(...))
secondary_colorstringEvetmax 32
background_colorstringEvetmax 32
surface_colorstringEvetmax 32
text_colorstringEvetmax 32
muted_text_colorstringEvetmax 32
border_colorstringEvetmax 32
font_familystringEvetmax 255. CSS font-family değeri
font_size_baseintEvetpx. min 8, max 32
font_size_headingintEvetpx. min 10, max 64
font_weight_headingintEvetmin 100, max 900
border_radiusintHayırpx. min 0, max 64. Varsayılan 0
custom_cssstringHayırmax 32768. Üretilen CSS değişkenlerinden sonra eklenen ham CSS — son yazan kazanır

Yanıt — 201 Created

Oluşturulan WidgetStyleResponse döner (Widget Stilini Getir ile aynı yapı).

KodAçıklama
400Doğrulama hatası
401Yetkisiz
409Bu node'da aynı isimde bir stil zaten mevcut