// This file was auto-generated by Fern from our API Definition.

/**
 * A macro is a pre-defined response template (saved reply) that can be used to quickly reply to conversations.
 */
export interface Macro {
    /** String representing the object's type. Always has the value `macro`. */
    type?: "macro";
    /** The unique identifier for the macro. */
    id?: string;
    /** The name of the macro. */
    name?: string;
    /** The body of the macro in HTML format with placeholders transformed to XML-like format. */
    body?: string;
    /** The plain text version of the macro body with original Intercom placeholder format. */
    body_text?: string;
    /** The time the macro was created in ISO 8601 format. */
    created_at?: string;
    /** The time the macro was last updated in ISO 8601 format. */
    updated_at?: string;
    /** Who can view this macro. */
    visible_to?: Macro.VisibleTo;
    /** The team IDs that can view this macro when visible_to is set to specific_teams. */
    visible_to_team_ids?: string[];
    /** Where the macro is available for use. */
    available_on?: Macro.AvailableOn.Item[];
}

export namespace Macro {
    /** Who can view this macro. */
    export const VisibleTo = {
        Everyone: "everyone",
        SpecificTeams: "specific_teams",
    } as const;
    export type VisibleTo = (typeof VisibleTo)[keyof typeof VisibleTo];
    export type AvailableOn = AvailableOn.Item[];

    export namespace AvailableOn {
        export const Item = {
            Inbox: "inbox",
            Messenger: "messenger",
        } as const;
        export type Item = (typeof Item)[keyof typeof Item];
    }
}
