Create a theme
POST
https://www.rapidoform.com/be/api/theme
All requests require X-EMAIL and X-API-KEY. See authentication and errors. JSON request bodies also require Content-Type: application/json. All IDs in examples are synthetic; replace them with your own values.
Parameters
| Name | Type / location | Description |
|---|---|---|
| themeName | string | Optional; defaults to My Theme. |
| backgroundColor, questionColor, questionTypeColor, btnBackgroundColor, btnTextColor, bottomLineColor | string | Optional CSS colors. |
| backgroundImage, backgroundImageType, backgroundImageTypeColor | string | Optional background media and treatment. |
| logo, logoType, logoTypeColor, logoAltText | string | Optional logo configuration. |
| textAlignment, welcomeTextAlignment | string | Optional text alignment. |
| fontSize, welcomeFontSize | string | Optional font size; default is "1.5". |
| fontFamily, fontUrl, radius | string | Optional font family, font resource and border radius. |
| bgImgBrigthness, logoSize | number | Optional image brightness (default 1) and logo size (default 72). Keep the spelling bgImgBrigthness. |
| isPaidTheme | boolean | Optional; defaults to false. |
themeCreatorId is assigned from the authenticated user. Assign the returned theme ID to a form through Update a form.
Example request
curl --request POST 'https://www.rapidoform.com/be/api/theme' \
--header "X-EMAIL: $RAPIDOFORM_EMAIL" \
--header "X-API-KEY: $RAPIDOFORM_API_KEY" \
--header 'Content-Type: application/json' \
--data '{"themeName":"Brand theme","backgroundColor":"#ffffff","btnBackgroundColor":"#1d4ed8","btnTextColor":"#ffffff"}'
JSON request body
{
"themeName": "Brand theme",
"backgroundColor": "#ffffff",
"btnBackgroundColor": "#1d4ed8",
"btnTextColor": "#ffffff"
}
Response
Examples show selected fields, not every stored property. Empty arrays are valid for list/report endpoints.
{
"Errors": [],
"Info": [],
"Data": [
{
"savedNewTheme": {
"_id": "000000000000000000000002",
"themeName": "Brand theme",
"backgroundColor": "#ffffff"
}
}
],
"ErrorCode": "SUCCESS",
"fieldErrors": {
"List": []
}
}
HTTP 200 alone does not indicate success. Check ErrorCode and Errors; see troubleshooting.