BatchUser: {
    clearInstallationData: (() => void);
    getAttributes: (() => Promise<{
        [key: string]: BatchUserAttribute;
    }>);
    getIdentifier: (() => Promise<string>);
    getInstallationID: (() => Promise<string>);
    getLanguage: (() => Promise<string>);
    getRegion: (() => Promise<string>);
    getTagCollections: (() => Promise<{
        [key: string]: string[];
    }>);
} = ...

Batch's user module

Type declaration

  • clearInstallationData: (() => void)

    Clear all tags and attributes set on an installation and their local cache returned by fetchAttributes and fetchTagCollections. This doesn’t affect data set on profiles using BatchProfile.

      • (): void
      • Returns void

  • getAttributes: (() => Promise<{
        [key: string]: BatchUserAttribute;
    }>)

    Read the saved attributes. Reading is asynchronous so as not to interfere with saving operations.

  • getIdentifier: (() => Promise<string>)

    Get the custom user identifier.

      • (): Promise<string>
      • Returns Promise<string>

        The custom user identifier set with BatchUser.editor().setIdentifier();

  • getInstallationID: (() => Promise<string>)

    Get the unique installation ID, generated by Batch. Batch must be started to read it. You will get the result in a promise.

      • (): Promise<string>
      • Returns Promise<string>

  • getLanguage: (() => Promise<string>)

    Get the language.

      • (): Promise<string>
      • Returns Promise<string>

        The language set with BatchUser.editor().setLanguage();

  • getRegion: (() => Promise<string>)

    Get the region.

      • (): Promise<string>
      • Returns Promise<string>

        The region set with BatchUser.editor().setRegion();

  • getTagCollections: (() => Promise<{
        [key: string]: string[];
    }>)

    Get the tag collections.

      • (): Promise<{
            [key: string]: string[];
        }>
      • Returns Promise<{
            [key: string]: string[];
        }>

        The tags added with BatchUser.editor().addTag()