Skip to content

Create Widget

POST
/api/widgets

Create a new embeddable widget with auto-generated API key

Authorizations

ApiKeyAuth

API key for authentication. Get your API key from the dashboard.

Type
API Key (header: X-Api-Key)

Request Body

application/json
JSON
{
  
"data": {
  
  
"type": "widgets",
  
  
"attributes": {
  
  
  
"name": "string",
  
  
  
"widgetType": "string",
  
  
  
"customization": {
  
  
  
  
"colors": {
  
  
  
  
  
"primary": "string",
  
  
  
  
  
"secondary": "string",
  
  
  
  
  
"background": "string",
  
  
  
  
  
"surface": "string",
  
  
  
  
  
"text": "string",
  
  
  
  
  
"textSecondary": "string",
  
  
  
  
  
"border": "string",
  
  
  
  
  
"error": "string",
  
  
  
  
  
"success": "string",
  
  
  
  
  
"accent": "string"
  
  
  
  
},
  
  
  
  
"fonts": {
  
  
  
  
  
"family": "string",
  
  
  
  
  
"sizeBase": 0,
  
  
  
  
  
"sizeScale": 0,
  
  
  
  
  
"sizeHeading": 0,
  
  
  
  
  
"sizeSmall": 0,
  
  
  
  
  
"weightNormal": 0,
  
  
  
  
  
"weightBold": 0
  
  
  
  
},
  
  
  
  
"borders": {
  
  
  
  
  
"radius": 0,
  
  
  
  
  
"width": 0,
  
  
  
  
  
"style": "string"
  
  
  
  
},
  
  
  
  
"spacing": {
  
  
  
  
  
"padding": 0,
  
  
  
  
  
"margin": 0
  
  
  
  
},
  
  
  
  
"shadows": {
  
  
  
  
  
"preset": "string",
  
  
  
  
  
"custom": "string"
  
  
  
  
},
  
  
  
  
"layout": {
  
  
  
  
  
"variant": "string"
  
  
  
  
},
  
  
  
  
"interaction": {
  
  
  
  
  
"tooltipEnabled": true,
  
  
  
  
  
"animationsEnabled": true,
  
  
  
  
  
"clickThroughEnabled": true,
  
  
  
  
  
"clickThroughUrl": "string"
  
  
  
  
},
  
  
  
  
"chartSettings": {
  
  
  
  
  
"additionalProperties": null
  
  
  
  
},
  
  
  
  
"labels": {
  
  
  
  
  
"additionalProperties": "string"
  
  
  
  
},
  
  
  
  
"language": "string",
  
  
  
  
"branding": {
  
  
  
  
  
"showPoweredBy": true,
  
  
  
  
  
"logoUrl": "string",
  
  
  
  
  
"companyName": "string"
  
  
  
  
},
  
  
  
  
"customCss": "string",
  
  
  
  
"widgetOptions": {
  
  
  
  
  
"showAspects": true,
  
  
  
  
  
"showPoints": true,
  
  
  
  
  
"showHouses": true,
  
  
  
  
  
"chartSize": "string",
  
  
  
  
  
"theme": "string"
  
  
  
  
},
  
  
  
  
"numerologyOptions": {
  
  
  
  
  
"showLifePath": true,
  
  
  
  
  
"showExpression": true,
  
  
  
  
  
"showSoulUrge": true,
  
  
  
  
  
"showPersonality": true,
  
  
  
  
  
"showBirthday": true,
  
  
  
  
  
"showPersonalCycles": true
  
  
  
  
},
  
  
  
  
"dailyHoroscopeOptions": {
  
  
  
  
  
"autoRefresh": true
  
  
  
  
},
  
  
  
  
"moonCalendarOptions": {
  
  
  
  
  
"showMoonrise": true,
  
  
  
  
  
"showMoonset": true,
  
  
  
  
  
"showIllumination": true,
  
  
  
  
  
"showPhaseEmoji": true,
  
  
  
  
  
"highlightFullMoon": true,
  
  
  
  
  
"highlightNewMoon": true
  
  
  
  
},
  
  
  
  
"compatibilityOptions": {
  
  
  
  
  
"showScore": true,
  
  
  
  
  
"showDescription": true,
  
  
  
  
  
"showLifePaths": true
  
  
  
  
}
  
  
  
},
  
  
  
"allowedDomains": [
  
  
  
  
"string"
  
  
  
],
  
  
  
"enabled": true
  
  
}
  
}
}

Responses

Created widget with API key

application/vnd.api+json
JSON
[
]

Playground

Authorization
Body

Samples

Powered by VitePress OpenAPI

AstroAPI Documentation