Skip to main content

Theme Customization

2 API calls in this section.

APIs for customizing the visual appearance and branding of the storefront.

Get Theme Settings​

Storefront & Commerce / Advanced Features / Theme Customization
GET/storefront/theme

Retrieves current theme and appearance settings for the storefront.

Authentication Required

Tenant admin access

Headers

ParameterTypeDescription
Authorizationstring

JWT token for tenant admin users

Example: Bearer {{access_token}}

Staging
Request
curl
1curl --globoff --request GET "https://staging-api.ondi.io/functions/v1/storefront/theme" \2  --header "Authorization: Bearer ${ONDI_ACCESS_TOKEN}"

Response examples

200OK
Response body
json
1{2  "success": true,3  "data": {4    "theme_settings": {5      "primary_color": "#007AFF",6      "secondary_color": "#FFFFFF",7      "accent_color": "#FF9500",8      "theme_style": "modern"9    },10    "branding": {11      "logo_url": "https://example.com/logo.png",12      "store_name": "My Awesome Store"13    }14  }15}

Update Theme Settings​

Storefront & Commerce / Advanced Features / Theme Customization
PUT/storefront/theme

Updates theme and appearance settings for the storefront. Supports partial updates.

Authentication Required

Tenant admin access

Headers

ParameterTypeDescription
Authorizationstring

JWT token for tenant admin users

Example: Bearer {{access_token}}

Content-Typestring

Example: application/json

Body parameters

ParameterTypeDescription
theme_settingsobject—
theme_settings.primary_colorstring—
theme_settings.secondary_colorstring—
theme_settings.accent_colorstring—
theme_settings.theme_stylestring—
Staging
Request
curl
1curl --globoff --request PUT "https://staging-api.ondi.io/functions/v1/storefront/theme" \2  --header "Authorization: Bearer ${ONDI_ACCESS_TOKEN}" \3  --header "Content-Type: application/json" \4  --data-raw '{5  "theme_settings": {6    "primary_color": "#34C759",7    "secondary_color": "#FFFFFF",8    "accent_color": "#30D158",9    "theme_style": "modern"10  }11}'

Response examples

200OK
Response body
json
1{2  "success": true,3  "data": {4    "theme_settings": {5      "primary_color": "#34C759",6      "secondary_color": "#FFFFFF",7      "accent_color": "#30D158",8      "theme_style": "modern"9    },10    "updated_at": "2023-12-01T19:00:00Z",11    "message": "Theme settings updated successfully"12  }13}