Create a feedback widget
Creates the widget as a draft. Pass active: true to publish immediately — the widget must have at least one option and targeting set, otherwise it stays a draft and the response note explains why. Supply options directly or use optionsPreset for a built-in set. The response includes a dashboardUrl for reviewing the widget in the builder.
Authorization
BearerAuth Use an API key from the Produktly dashboard → Settings → API keys.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/feedback-widgets" \ -H "Content-Type: application/json" \ -d '{ "name": "Site feedback", "options": [ { "name": "Bug", "emoji": "🐛" }, { "name": "Idea", "emoji": "💡" } ], "targeting": { "showOnAllPages": true }, "active": true }'{ "id": 0, "name": "string", "active": true, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "folderId": 0, "themeId": 0, "settings": { "property1": null, "property2": null }, "rules": [ { "property1": null, "property2": null } ], "ruleLogicalOperator": "string", "options": [ { "property1": null, "property2": null } ], "dashboardUrl": "string", "note": "string"}