You can also view Looker’s interactive API documentation on the Looker Developer Portal or by using the API Explorer extension.
Get All Themes beta
Implementation Notes
Get an array of all existing themes.
Get a single theme by id with Theme)
This method returns an array of all existing themes. The active time for the theme is not considered.
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
array
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
fields | false | Requested fields. | string | string |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Create Theme beta
Implementation Notes
Create a theme.
Creates a new theme object, returning the theme details, including the created id.
If settings
are not specified, the default theme settings will be copied into the new theme.
The theme name
can only contain alphanumeric characters or underscores. Theme names should not contain any confidential information, such as customer names.
Update an existing theme with Update Theme)
Permanently delete an existing theme with Delete Theme)
For more information, see Creating and Applying Themes.
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
ThemeSettings {
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
body | true | Theme | body |
Theme {
can (object, read-only): Operations the current user is able to perform on this object, begin_at (date-time): Timestamp for when this theme becomes active. Null=always, end_at (date-time): Timestamp for when this theme expires. Null=never, id (string, read-only): Unique Id, name (string): Name of theme. Can only be alphanumeric and underscores., settings (ThemeSettings): Hash of name/value pairs for theme settings. These names get validated. }ThemeSettings { background_color (string): Default background color, base_font_size (string): Base font size for scaling fonts (only supported by legacy dashboards), color_collection_id (string): Optional. ID of color collection to use with the theme. Use an empty string for none., font_color (string): Default font color, font_family (string): Primary font family, font_source (string): Source specification for font, info_button_color (string): Info button color, primary_button_color (string): Primary button color, show_filters_bar (boolean): Toggle to show filters. Defaults to true., show_title (boolean): Toggle to show the title. Defaults to true., text_tile_text_color (string): Text color for text tiles, tile_background_color (string): Background color for tiles, tile_text_color (string): Text color for tiles, title_color (string): Color for titles, warn_button_color (string): Warning button color, tile_title_alignment (string): The text alignment of tile titles (New Dashboards), tile_shadow (boolean): Toggles the tile shadow (not supported) }
|
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
409 | Resource Already Exists |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
422 | Validation Error |
ValidationError {
message (string, read-only, required): Error details, errors (Array[ValidationErrorDetail], read-only): Error detail array, documentation_url (string, read-only, required): Documentation link }ValidationErrorDetail { field (string, read-only): Field with error, code (string, read-only): Error code, message (string, read-only): Error info message, documentation_url (string, read-only, required): Documentation link }
|
429 | Too Many Requests |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Search Themes beta
Implementation Notes
Search all themes for matching criteria.
Returns an array of theme objects that match the specified search criteria.
Search Parameters | Description |
---|---|
begin_at only |
Find themes active at or after begin_at |
end_at only |
Find themes active at or before end_at |
both set | Find themes with an active inclusive period between begin_at and end_at |
Note: Range matching requires boolean AND logic.
When using begin_at
and end_at
together, do not use filter_or
=TRUE
If multiple search params are given and filter_or
is FALSE or not specified,
search params are combined in a logical AND operation.
Only rows that match all search param criteria will be returned.
If filter_or
is TRUE, multiple search params are combined in a logical OR operation.
Results will include rows that match any of the search criteria.
String search params use case-insensitive matching.
String search params can contain %
and ‘_’ as SQL LIKE pattern match wildcard expressions.
example=”dan%” will match “danger” and “Danzig” but not “David”
example=”D_m%” will match “Damage” and “dump”
Integer search params can accept a single value or a comma separated list of values. The multiple values will be combined under a logical OR operation - results will match at least one of the given values.
Most search params can accept “IS NULL” and “NOT NULL” as special expressions to match or exclude (respectively) rows where the column is null.
Boolean search params accept only “true” and “false” as values.
Get a single theme by id with Theme)
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
array
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
id | false | Match theme id. | string | string |
name | false | Match theme name. | string | string |
begin_at | false | Timestamp for activation. | string | date-time |
end_at | false | Timestamp for expiration. | string | date-time |
limit | false | Number of results to return (used with `offset`). | integer | int64 |
offset | false | Number of results to skip before returning any (used with `limit`). | integer | int64 |
sorts | false | Fields to sort by. | string | string |
fields | false | Requested fields. | string | string |
filter_or | false | Combine given search criteria in a boolean OR expression | boolean | boolean |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Get Default Theme beta
Implementation Notes
Get the default theme.
Returns the active theme object set as the default.
The default theme name can be set in the UI on the Admin|Theme UI page
The optional ts
parameter can specify a different timestamp than “now.” If specified, it returns the default theme at the time indicated.
Response Class
ThemeSettings {
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
ts | false | Timestamp representing the target datetime for the active period. Defaults to ‘now’ | string | date-time |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Set Default Theme beta
Implementation Notes
Set the global default theme by theme name.
Only Admin users can call this function.
Only an active theme with no expiration (end_at
not set) can be assigned as the default theme. As long as a theme has an active record with no expiration, it can be set as the default.
Create Theme) has detailed information on rules for default and active themes
Returns the new specified default theme object.
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
ThemeSettings {
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
name | true | Name of theme to set as default | string | string |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
422 | Validation Error |
ValidationError {
message (string, read-only, required): Error details, errors (Array[ValidationErrorDetail], read-only): Error detail array, documentation_url (string, read-only, required): Documentation link }ValidationErrorDetail { field (string, read-only): Field with error, code (string, read-only): Error code, message (string, read-only): Error info message, documentation_url (string, read-only, required): Documentation link }
|
429 | Too Many Requests |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Get Active Themes beta
Implementation Notes
Get active themes.
Returns an array of active themes.
If the name
parameter is specified, it will return an array with one theme if it’s active and found.
The optional ts
parameter can specify a different timestamp than “now.”
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
array
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
name | false | Name of theme | string | string |
ts | false | Timestamp representing the target datetime for the active period. Defaults to ‘now’ | string | date-time |
fields | false | Requested fields. | string | string |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Get Theme or Default beta
Implementation Notes
Get the named theme if it’s active. Otherwise, return the default theme.
The optional ts
parameter can specify a different timestamp than “now.”
Note: API users with show
ability can call this function
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
ThemeSettings {
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
name | true | Name of theme | string | string |
ts | false | Timestamp representing the target datetime for the active period. Defaults to ‘now’ | string | date-time |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Validate Theme beta
Implementation Notes
Validate a theme with the specified information.
Validates all values set for the theme, returning any errors encountered, or 200 OK if valid
See Create Theme) for constraints
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
ValidationErrorDetail {
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
body | true | Theme | body |
Theme {
can (object, read-only): Operations the current user is able to perform on this object, begin_at (date-time): Timestamp for when this theme becomes active. Null=always, end_at (date-time): Timestamp for when this theme expires. Null=never, id (string, read-only): Unique Id, name (string): Name of theme. Can only be alphanumeric and underscores., settings (ThemeSettings): Hash of name/value pairs for theme settings. These names get validated. }ThemeSettings { background_color (string): Default background color, base_font_size (string): Base font size for scaling fonts (only supported by legacy dashboards), color_collection_id (string): Optional. ID of color collection to use with the theme. Use an empty string for none., font_color (string): Default font color, font_family (string): Primary font family, font_source (string): Source specification for font, info_button_color (string): Info button color, primary_button_color (string): Primary button color, show_filters_bar (boolean): Toggle to show filters. Defaults to true., show_title (boolean): Toggle to show the title. Defaults to true., text_tile_text_color (string): Text color for text tiles, tile_background_color (string): Background color for tiles, tile_text_color (string): Text color for tiles, title_color (string): Color for titles, warn_button_color (string): Warning button color, tile_title_alignment (string): The text alignment of tile titles (New Dashboards), tile_shadow (boolean): Toggles the tile shadow (not supported) }
|
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
409 | Resource Already Exists |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
422 | Validation Error |
ValidationError {
message (string, read-only, required): Error details, errors (Array[ValidationErrorDetail], read-only): Error detail array, documentation_url (string, read-only, required): Documentation link }ValidationErrorDetail { field (string, read-only): Field with error, code (string, read-only): Error code, message (string, read-only): Error info message, documentation_url (string, read-only, required): Documentation link }
|
429 | Too Many Requests |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
204 | No errors detected with the theme | string |
Get Theme beta
Implementation Notes
Get a theme by ID.
Use this to retrieve a specific theme, whether or not it’s currently active.
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
ThemeSettings {
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
theme_id | true | Id of theme | string | string |
fields | false | Requested fields. | string | string |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Update Theme beta
Implementation Notes
Update the theme by id.
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
ThemeSettings {
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
theme_id | true | Id of theme | string | string |
body | true | Theme | body |
Theme {
can (object, read-only): Operations the current user is able to perform on this object, begin_at (date-time): Timestamp for when this theme becomes active. Null=always, end_at (date-time): Timestamp for when this theme expires. Null=never, id (string, read-only): Unique Id, name (string): Name of theme. Can only be alphanumeric and underscores., settings (ThemeSettings): Hash of name/value pairs for theme settings. These names get validated. }ThemeSettings { background_color (string): Default background color, base_font_size (string): Base font size for scaling fonts (only supported by legacy dashboards), color_collection_id (string): Optional. ID of color collection to use with the theme. Use an empty string for none., font_color (string): Default font color, font_family (string): Primary font family, font_source (string): Source specification for font, info_button_color (string): Info button color, primary_button_color (string): Primary button color, show_filters_bar (boolean): Toggle to show filters. Defaults to true., show_title (boolean): Toggle to show the title. Defaults to true., text_tile_text_color (string): Text color for text tiles, tile_background_color (string): Background color for tiles, tile_text_color (string): Text color for tiles, title_color (string): Color for titles, warn_button_color (string): Warning button color, tile_title_alignment (string): The text alignment of tile titles (New Dashboards), tile_shadow (boolean): Toggles the tile shadow (not supported) }
|
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
422 | Validation Error |
ValidationError {
message (string, read-only, required): Error details, errors (Array[ValidationErrorDetail], read-only): Error detail array, documentation_url (string, read-only, required): Documentation link }ValidationErrorDetail { field (string, read-only): Field with error, code (string, read-only): Error code, message (string, read-only): Error info message, documentation_url (string, read-only, required): Documentation link }
|
429 | Too Many Requests |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
Delete Theme beta
Implementation Notes
Delete a specific theme by id.
This operation permanently deletes the identified theme from the database.
Because multiple themes can have the same name (with different activation time spans) themes can only be deleted by ID.
All IDs associated with a theme name can be retrieved by searching for the theme name with Theme Search).
Note: Custom themes needs to be enabled by Looker. Unless custom themes are enabled, only the automatically generated default theme can be used. Please contact your Account Manager or help.looker.com to update your license for this feature.
Response Class
None
Parameters
Parameter | Required? | Description | Parameter Type | Data Type |
---|---|---|---|---|
theme_id | true | Id of theme | string | string |
Response Messages
HTTP Status Code | Reason | Response Model |
---|---|---|
400 | Bad Request |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
404 | Not Found |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
429 | Too Many Requests |
Error {
message (string, read-only, required): Error details, documentation_url (string, read-only, required): Documentation link }
|
204 | Successfully deleted. | string |