Theme (User)
The Theme API provides methods for managing and creating Weebly themes for a given Cloud user.
If you want to manage your custom themes, use the Theme (User) API.
If you want to manage your custom themes, use the Theme (User) API.
In this topic:
Fields
- theme_name (string)
Name given to a theme (ex: "My Red Theme")
- is_custom (boolean)
Depicts whether the theme is a custom theme or not. Custom themes are added by a user or added via the Weebly Cloud API. (ex: "1")
- date_created (timestamp)
Date when the theme was added to the user's account. (ex: "2014-06-06 01:07:53")
- theme_zip (url)
Publicly accessible url that points to the zip file containing the theme contents. This is only used when adding a theme to a site (ex: "http://myhost.com/custom_theme.zip")
GET /user/USER_ID/theme
Lists all themes available to the given user. An optional flag of "custom_only" can be included to only show custom themes.
Example CURL Request
Example Response
POST /user/USER_ID/theme
Creates a new theme in the user account. NOTE: theme_zip must be publicly accessible and follow the structure for custom themes.
Example CURL Request
Example Response
Sets the theme for a given site. This theme change takes place immediately, but won't be seen on the published site until next publish. An "is_custom" flag is required in order to distinguish between Weebly themes and custom themes.
Example CURL Request
Example Response