1. Packages
  2. Auth0
  3. API Docs
  4. Branding
Auth0 v3.3.1 published on Thursday, Mar 14, 2024 by Pulumi

auth0.Branding

Explore with Pulumi AI

auth0 logo
Auth0 v3.3.1 published on Thursday, Mar 14, 2024 by Pulumi

    This resource allows you to manage branding within your Auth0 tenant. Auth0 can be customized with a look and feel that aligns with your organization’s brand requirements and user expectations.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as auth0 from "@pulumi/auth0";
    import * as fs from "fs";
    
    const myBrand = new auth0.Branding("myBrand", {
        logoUrl: "https://mycompany.org/logo.png",
        colors: {
            primary: "#0059d6",
            pageBackground: "#000000",
        },
        universalLogin: {
            body: fs.readFileSync("universal_login_body.html", "utf8"),
        },
    });
    
    import pulumi
    import pulumi_auth0 as auth0
    
    my_brand = auth0.Branding("myBrand",
        logo_url="https://mycompany.org/logo.png",
        colors=auth0.BrandingColorsArgs(
            primary="#0059d6",
            page_background="#000000",
        ),
        universal_login=auth0.BrandingUniversalLoginArgs(
            body=(lambda path: open(path).read())("universal_login_body.html"),
        ))
    
    package main
    
    import (
    	"os"
    
    	"github.com/pulumi/pulumi-auth0/sdk/v3/go/auth0"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func readFileOrPanic(path string) pulumi.StringPtrInput {
    	data, err := os.ReadFile(path)
    	if err != nil {
    		panic(err.Error())
    	}
    	return pulumi.String(string(data))
    }
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := auth0.NewBranding(ctx, "myBrand", &auth0.BrandingArgs{
    			LogoUrl: pulumi.String("https://mycompany.org/logo.png"),
    			Colors: &auth0.BrandingColorsArgs{
    				Primary:        pulumi.String("#0059d6"),
    				PageBackground: pulumi.String("#000000"),
    			},
    			UniversalLogin: &auth0.BrandingUniversalLoginArgs{
    				Body: readFileOrPanic("universal_login_body.html"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.IO;
    using System.Linq;
    using Pulumi;
    using Auth0 = Pulumi.Auth0;
    
    return await Deployment.RunAsync(() => 
    {
        var myBrand = new Auth0.Branding("myBrand", new()
        {
            LogoUrl = "https://mycompany.org/logo.png",
            Colors = new Auth0.Inputs.BrandingColorsArgs
            {
                Primary = "#0059d6",
                PageBackground = "#000000",
            },
            UniversalLogin = new Auth0.Inputs.BrandingUniversalLoginArgs
            {
                Body = File.ReadAllText("universal_login_body.html"),
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.auth0.Branding;
    import com.pulumi.auth0.BrandingArgs;
    import com.pulumi.auth0.inputs.BrandingColorsArgs;
    import com.pulumi.auth0.inputs.BrandingUniversalLoginArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var myBrand = new Branding("myBrand", BrandingArgs.builder()        
                .logoUrl("https://mycompany.org/logo.png")
                .colors(BrandingColorsArgs.builder()
                    .primary("#0059d6")
                    .pageBackground("#000000")
                    .build())
                .universalLogin(BrandingUniversalLoginArgs.builder()
                    .body(Files.readString(Paths.get("universal_login_body.html")))
                    .build())
                .build());
    
        }
    }
    
    resources:
      myBrand:
        type: auth0:Branding
        properties:
          logoUrl: https://mycompany.org/logo.png
          colors:
            primary: '#0059d6'
            pageBackground: '#000000'
          universalLogin:
            body:
              fn::readFile: universal_login_body.html
    

    Create Branding Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Branding(name: string, args?: BrandingArgs, opts?: CustomResourceOptions);
    @overload
    def Branding(resource_name: str,
                 args: Optional[BrandingArgs] = None,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Branding(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 colors: Optional[BrandingColorsArgs] = None,
                 favicon_url: Optional[str] = None,
                 font: Optional[BrandingFontArgs] = None,
                 logo_url: Optional[str] = None,
                 universal_login: Optional[BrandingUniversalLoginArgs] = None)
    func NewBranding(ctx *Context, name string, args *BrandingArgs, opts ...ResourceOption) (*Branding, error)
    public Branding(string name, BrandingArgs? args = null, CustomResourceOptions? opts = null)
    public Branding(String name, BrandingArgs args)
    public Branding(String name, BrandingArgs args, CustomResourceOptions options)
    
    type: auth0:Branding
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args BrandingArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args BrandingArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args BrandingArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args BrandingArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args BrandingArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var brandingResource = new Auth0.Branding("brandingResource", new()
    {
        Colors = new Auth0.Inputs.BrandingColorsArgs
        {
            PageBackground = "string",
            Primary = "string",
        },
        FaviconUrl = "string",
        Font = new Auth0.Inputs.BrandingFontArgs
        {
            Url = "string",
        },
        LogoUrl = "string",
        UniversalLogin = new Auth0.Inputs.BrandingUniversalLoginArgs
        {
            Body = "string",
        },
    });
    
    example, err := auth0.NewBranding(ctx, "brandingResource", &auth0.BrandingArgs{
    	Colors: &auth0.BrandingColorsArgs{
    		PageBackground: pulumi.String("string"),
    		Primary:        pulumi.String("string"),
    	},
    	FaviconUrl: pulumi.String("string"),
    	Font: &auth0.BrandingFontArgs{
    		Url: pulumi.String("string"),
    	},
    	LogoUrl: pulumi.String("string"),
    	UniversalLogin: &auth0.BrandingUniversalLoginArgs{
    		Body: pulumi.String("string"),
    	},
    })
    
    var brandingResource = new Branding("brandingResource", BrandingArgs.builder()        
        .colors(BrandingColorsArgs.builder()
            .pageBackground("string")
            .primary("string")
            .build())
        .faviconUrl("string")
        .font(BrandingFontArgs.builder()
            .url("string")
            .build())
        .logoUrl("string")
        .universalLogin(BrandingUniversalLoginArgs.builder()
            .body("string")
            .build())
        .build());
    
    branding_resource = auth0.Branding("brandingResource",
        colors=auth0.BrandingColorsArgs(
            page_background="string",
            primary="string",
        ),
        favicon_url="string",
        font=auth0.BrandingFontArgs(
            url="string",
        ),
        logo_url="string",
        universal_login=auth0.BrandingUniversalLoginArgs(
            body="string",
        ))
    
    const brandingResource = new auth0.Branding("brandingResource", {
        colors: {
            pageBackground: "string",
            primary: "string",
        },
        faviconUrl: "string",
        font: {
            url: "string",
        },
        logoUrl: "string",
        universalLogin: {
            body: "string",
        },
    });
    
    type: auth0:Branding
    properties:
        colors:
            pageBackground: string
            primary: string
        faviconUrl: string
        font:
            url: string
        logoUrl: string
        universalLogin:
            body: string
    

    Branding Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Branding resource accepts the following input properties:

    Colors BrandingColors
    Configuration settings for colors for branding.
    FaviconUrl string
    URL for the favicon.
    Font BrandingFont
    Configuration settings to customize the font.
    LogoUrl string
    URL of logo for branding.
    UniversalLogin BrandingUniversalLogin
    Configuration settings for Universal Login.
    Colors BrandingColorsArgs
    Configuration settings for colors for branding.
    FaviconUrl string
    URL for the favicon.
    Font BrandingFontArgs
    Configuration settings to customize the font.
    LogoUrl string
    URL of logo for branding.
    UniversalLogin BrandingUniversalLoginArgs
    Configuration settings for Universal Login.
    colors BrandingColors
    Configuration settings for colors for branding.
    faviconUrl String
    URL for the favicon.
    font BrandingFont
    Configuration settings to customize the font.
    logoUrl String
    URL of logo for branding.
    universalLogin BrandingUniversalLogin
    Configuration settings for Universal Login.
    colors BrandingColors
    Configuration settings for colors for branding.
    faviconUrl string
    URL for the favicon.
    font BrandingFont
    Configuration settings to customize the font.
    logoUrl string
    URL of logo for branding.
    universalLogin BrandingUniversalLogin
    Configuration settings for Universal Login.
    colors BrandingColorsArgs
    Configuration settings for colors for branding.
    favicon_url str
    URL for the favicon.
    font BrandingFontArgs
    Configuration settings to customize the font.
    logo_url str
    URL of logo for branding.
    universal_login BrandingUniversalLoginArgs
    Configuration settings for Universal Login.
    colors Property Map
    Configuration settings for colors for branding.
    faviconUrl String
    URL for the favicon.
    font Property Map
    Configuration settings to customize the font.
    logoUrl String
    URL of logo for branding.
    universalLogin Property Map
    Configuration settings for Universal Login.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Branding resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Branding Resource

    Get an existing Branding resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: BrandingState, opts?: CustomResourceOptions): Branding
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            colors: Optional[BrandingColorsArgs] = None,
            favicon_url: Optional[str] = None,
            font: Optional[BrandingFontArgs] = None,
            logo_url: Optional[str] = None,
            universal_login: Optional[BrandingUniversalLoginArgs] = None) -> Branding
    func GetBranding(ctx *Context, name string, id IDInput, state *BrandingState, opts ...ResourceOption) (*Branding, error)
    public static Branding Get(string name, Input<string> id, BrandingState? state, CustomResourceOptions? opts = null)
    public static Branding get(String name, Output<String> id, BrandingState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Colors BrandingColors
    Configuration settings for colors for branding.
    FaviconUrl string
    URL for the favicon.
    Font BrandingFont
    Configuration settings to customize the font.
    LogoUrl string
    URL of logo for branding.
    UniversalLogin BrandingUniversalLogin
    Configuration settings for Universal Login.
    Colors BrandingColorsArgs
    Configuration settings for colors for branding.
    FaviconUrl string
    URL for the favicon.
    Font BrandingFontArgs
    Configuration settings to customize the font.
    LogoUrl string
    URL of logo for branding.
    UniversalLogin BrandingUniversalLoginArgs
    Configuration settings for Universal Login.
    colors BrandingColors
    Configuration settings for colors for branding.
    faviconUrl String
    URL for the favicon.
    font BrandingFont
    Configuration settings to customize the font.
    logoUrl String
    URL of logo for branding.
    universalLogin BrandingUniversalLogin
    Configuration settings for Universal Login.
    colors BrandingColors
    Configuration settings for colors for branding.
    faviconUrl string
    URL for the favicon.
    font BrandingFont
    Configuration settings to customize the font.
    logoUrl string
    URL of logo for branding.
    universalLogin BrandingUniversalLogin
    Configuration settings for Universal Login.
    colors BrandingColorsArgs
    Configuration settings for colors for branding.
    favicon_url str
    URL for the favicon.
    font BrandingFontArgs
    Configuration settings to customize the font.
    logo_url str
    URL of logo for branding.
    universal_login BrandingUniversalLoginArgs
    Configuration settings for Universal Login.
    colors Property Map
    Configuration settings for colors for branding.
    faviconUrl String
    URL for the favicon.
    font Property Map
    Configuration settings to customize the font.
    logoUrl String
    URL of logo for branding.
    universalLogin Property Map
    Configuration settings for Universal Login.

    Supporting Types

    BrandingColors, BrandingColorsArgs

    PageBackground string
    Background color of login pages in hexadecimal.
    Primary string
    Primary button background color in hexadecimal.
    PageBackground string
    Background color of login pages in hexadecimal.
    Primary string
    Primary button background color in hexadecimal.
    pageBackground String
    Background color of login pages in hexadecimal.
    primary String
    Primary button background color in hexadecimal.
    pageBackground string
    Background color of login pages in hexadecimal.
    primary string
    Primary button background color in hexadecimal.
    page_background str
    Background color of login pages in hexadecimal.
    primary str
    Primary button background color in hexadecimal.
    pageBackground String
    Background color of login pages in hexadecimal.
    primary String
    Primary button background color in hexadecimal.

    BrandingFont, BrandingFontArgs

    Url string
    URL for the custom font.
    Url string
    URL for the custom font.
    url String
    URL for the custom font.
    url string
    URL for the custom font.
    url str
    URL for the custom font.
    url String
    URL for the custom font.

    BrandingUniversalLogin, BrandingUniversalLoginArgs

    Body string
    The html template for the New Universal Login Experience.
    Body string
    The html template for the New Universal Login Experience.
    body String
    The html template for the New Universal Login Experience.
    body string
    The html template for the New Universal Login Experience.
    body str
    The html template for the New Universal Login Experience.
    body String
    The html template for the New Universal Login Experience.

    Import

    As this is not a resource identifiable by an ID within the Auth0 Management API,

    branding can be imported using a random string.

    We recommend Version 4 UUID

    Example:

    $ pulumi import auth0:index/branding:Branding my_brand "22f4f21b-017a-319d-92e7-2291c1ca36c4"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Auth0 pulumi/pulumi-auth0
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the auth0 Terraform Provider.
    auth0 logo
    Auth0 v3.3.1 published on Thursday, Mar 14, 2024 by Pulumi