Skip to main content

themes

Creates, updates, deletes, gets or lists a themes resource.

Overview​

Namethemes
TypeResource
Idokta.brands.themes

Fields​

The following fields are returned by SELECT queries:

Successfully retrieved the theme

NameDatatypeDescription
idstring
_linksobjectSpecifies link relations (see Web Linking) available using the JSON Hypertext Application Language specification. This object is used for dynamic discovery of related resources and lifecycle operations.
backgroundImagestring
emailTemplateTouchPointVariantstringVariant for email templates. You can publish a theme for email templates with different combinations of assets. Variants are preset combinations of those assets. (FULL_THEME, OKTA_DEFAULT) (default: OKTA_DEFAULT)
endUserDashboardTouchPointVariantstringVariant for the Okta End-User Dashboard. You can publish a theme for end-user dashboard with different combinations of assets. Variants are preset combinations of those assets. (FULL_THEME, LOGO_ON_FULL_WHITE_BACKGROUND, OKTA_DEFAULT, WHITE_LOGO_BACKGROUND) (default: OKTA_DEFAULT)
errorPageTouchPointVariantstringVariant for the error page. You can publish a theme for error page with different combinations of assets. Variants are preset combinations of those assets. (BACKGROUND_IMAGE, BACKGROUND_SECONDARY_COLOR, OKTA_DEFAULT) (default: OKTA_DEFAULT)
faviconstring
loadingPageTouchPointVariantstringVariant for the Okta loading page. You can publish a theme for Okta loading page with different combinations of assets. Variants are preset combinations of those assets. (NONE, OKTA_DEFAULT) (default: OKTA_DEFAULT)
logostring
primaryColorContrastHexstringPrimary color contrast hex code
primaryColorHexstringPrimary color hex code
secondaryColorContrastHexstringSecondary color contrast hex code
secondaryColorHexstringSecondary color hex code
signInPageTouchPointVariantstringVariant for the Okta sign-in page. You can publish a theme for sign-in page with different combinations of assets. Variants are preset combinations of those assets. > Note: For a non-OKTA_DEFAULT variant, primaryColorHex is used for button background color and primaryColorContrastHex is used to optimize the opacity for button text. (BACKGROUND_IMAGE, BACKGROUND_SECONDARY_COLOR, OKTA_DEFAULT)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_brand_themeselectbrandId, themeId, subdomainRetrieves a theme for a brand
list_brand_themesselectbrandId, subdomainLists all the themes in your brand.

> Important: Currently each org supports only one theme, therefore this contains a single object only.
replace_brand_themereplacebrandId, themeId, subdomain, primaryColorHex, secondaryColorHex, signInPageTouchPointVariant, endUserDashboardTouchPointVariant, errorPageTouchPointVariant, emailTemplateTouchPointVariantReplaces a theme for a brand
upload_brand_theme_background_imageexecbrandId, themeId, subdomain, fileUploads and replaces the background image for the theme. The file must be in PNG, JPG, or GIF format and less than 2 MB in size.
delete_brand_theme_background_imageexecbrandId, themeId, subdomainDeletes a theme background image
upload_brand_theme_faviconexecbrandId, themeId, subdomain, fileUploads and replaces the favicon for the theme
delete_brand_theme_faviconexecbrandId, themeId, subdomainDeletes a theme favicon. The theme will use the default Okta favicon.
upload_brand_theme_logoexecbrandId, themeId, subdomain, fileUploads and replaces the logo for the theme. The file must be in PNG, JPG, or GIF format and less than 100kB in size. For best results use landscape orientation, a transparent background, and a minimum size of 300px by 50px to prevent upscaling.
delete_brand_theme_logoexecbrandId, themeId, subdomainDeletes a Theme logo. The theme will use the default Okta logo.

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
brandIdstringThe ID of the brand
subdomainstring(default: my-org)
themeIdstringThe ID of the theme

SELECT examples​

Retrieves a theme for a brand

SELECT
id,
_links,
backgroundImage,
emailTemplateTouchPointVariant,
endUserDashboardTouchPointVariant,
errorPageTouchPointVariant,
favicon,
loadingPageTouchPointVariant,
logo,
primaryColorContrastHex,
primaryColorHex,
secondaryColorContrastHex,
secondaryColorHex,
signInPageTouchPointVariant
FROM okta.brands.themes
WHERE brandId = '{{ brandId }}' -- required
AND themeId = '{{ themeId }}' -- required
AND subdomain = '{{ subdomain }}' -- required
;

REPLACE examples​

Replaces a theme for a brand

REPLACE okta.brands.themes
SET
emailTemplateTouchPointVariant = '{{ emailTemplateTouchPointVariant }}',
endUserDashboardTouchPointVariant = '{{ endUserDashboardTouchPointVariant }}',
errorPageTouchPointVariant = '{{ errorPageTouchPointVariant }}',
loadingPageTouchPointVariant = '{{ loadingPageTouchPointVariant }}',
primaryColorContrastHex = '{{ primaryColorContrastHex }}',
primaryColorHex = '{{ primaryColorHex }}',
secondaryColorContrastHex = '{{ secondaryColorContrastHex }}',
secondaryColorHex = '{{ secondaryColorHex }}',
signInPageTouchPointVariant = '{{ signInPageTouchPointVariant }}'
WHERE
brandId = '{{ brandId }}' --required
AND themeId = '{{ themeId }}' --required
AND subdomain = '{{ subdomain }}' --required
AND primaryColorHex = '{{ primaryColorHex }}' --required
AND secondaryColorHex = '{{ secondaryColorHex }}' --required
AND signInPageTouchPointVariant = '{{ signInPageTouchPointVariant }}' --required
AND endUserDashboardTouchPointVariant = '{{ endUserDashboardTouchPointVariant }}' --required
AND errorPageTouchPointVariant = '{{ errorPageTouchPointVariant }}' --required
AND emailTemplateTouchPointVariant = '{{ emailTemplateTouchPointVariant }}' --required
RETURNING
id,
_links,
backgroundImage,
emailTemplateTouchPointVariant,
endUserDashboardTouchPointVariant,
errorPageTouchPointVariant,
favicon,
loadingPageTouchPointVariant,
logo,
primaryColorContrastHex,
primaryColorHex,
secondaryColorContrastHex,
secondaryColorHex,
signInPageTouchPointVariant;

Lifecycle Methods​

Uploads and replaces the background image for the theme. The file must be in PNG, JPG, or GIF format and less than 2 MB in size.

EXEC okta.brands.themes.upload_brand_theme_background_image
@brandId='{{ brandId }}' --required,
@themeId='{{ themeId }}' --required,
@subdomain='{{ subdomain }}' --required
@@json=
'{
"file": "{{ file }}"
}'
;