Interface TelegramNodeParameters

Source
interface TelegramNodeParameters {
    action?:
        | "find_location"
        | "record_audio"
        | "record_video"
        | "record_video_note"
        | "typing"
        | "upload_audio"
        | "upload_document"
        | "upload_photo"
        | "upload_video"
        | "upload_video_note";
    additionalFields?: | { disable_notification?: boolean }
    | {
        cache_time?: number;
        show_alert?: boolean;
        text?: string;
        url?: string;
    }
    | { mimeType?: string }
    | {
        appendAttribution?: boolean;
        caption?: string;
        disable_notification?: boolean;
        disable_web_page_preview?: boolean;
        duration?: number;
        fileName?: string;
        height?: number;
        message_thread_id?: number;
        parse_mode?: "HTML" | "Markdown" | "MarkdownV2";
        performer?: string;
        reply_to_message_id?: number;
        thumb?: string;
        title?: string;
        width?: number;
    };
    approvalOptions?: {
        values: {
            approvalType?: "single"
            | "double";
            approveLabel?: string;
            disapproveLabel?: string;
        };
    };
    binaryData?: boolean;
    binaryPropertyName?: string;
    chatId?: string;
    defineForm?: "json"
    | "fields";
    description?: string;
    download?: boolean;
    file?: string;
    fileId?: string;
    forceReply?: {
        force_reply?: boolean;
        selective?: boolean;
    };
    formFields?: {
        values: {
            acceptFileTypes?: string;
            elementName?: string;
            fieldLabel: string;
            fieldName?: string;
            fieldOptions: { values: { option?: string }[] };
            fieldType:
                | "number"
                | "file"
                | "text"
                | "email"
                | "date"
                | "html"
                | "checkbox"
                | "dropdown"
                | "hiddenField"
                | "password"
                | "radio"
                | "textarea";
            fieldValue?: string;
            formatDate?: string;
            html?: string;
            limitSelection?: "exact"
            | "range"
            | "unlimited";
            maxSelections?: number;
            minSelections?: number;
            multipleFiles?: boolean;
            multiselect?: boolean;
            multiselectLegacyNotice?: string;
            numberOfSelections?: number;
            placeholder?: string;
            requiredField?: boolean;
        }[];
    };
    inlineKeyboard?: {
        rows: {
            row?: {
                buttons: {
                    additionalFields?: {
                        callback_data?: (...)
                        | (...);
                        pay?: (...) | (...) | (...);
                        switch_inline_query?: (...) | (...);
                        switch_inline_query_current_chat?: (...) | (...);
                        url?: (...) | (...);
                        web_app?: (...) | (...);
                    };
                    text?: string;
                }[];
            };
        }[];
    };
    inlineMessageId?: string;
    jsonOutput?: string;
    latitude?: number;
    longitude?: number;
    media?: {
        media: {
            additionalFields?: {
                caption?: string;
                parse_mode?: "HTML"
                | "Markdown"
                | "MarkdownV2";
            };
            media?: string;
            type?: "video"
            | "photo";
        }[];
    };
    message?: string;
    messageId?: string;
    messageType?: "message"
    | "inlineMessage";
    operation?:
        | "get"
        | "sendMessage"
        | "member"
        | "deleteMessage"
        | "sendAndWait"
        | "leave"
        | "administrators"
        | "setDescription"
        | "setTitle"
        | "answerQuery"
        | "answerInlineQuery"
        | "editMessageText"
        | "pinChatMessage"
        | "sendAnimation"
        | "sendAudio"
        | "sendChatAction"
        | "sendDocument"
        | "sendLocation"
        | "sendMediaGroup"
        | "sendPhoto"
        | "sendSticker"
        | "sendVideo"
        | "unpinChatMessage";
    options?: | {
        appendAttribution?: boolean;
        limitWaitTime?: {
            values: {
                limitType?: | "afterTimeInterval"
                | "atSpecifiedTime";
                maxDateAndTime?: string;
                resumeAmount?: number;
                resumeUnit?: "minutes"
                | "hours"
                | "days";
            };
        };
    }
    | {
        appendAttribution?: boolean;
        limitWaitTime?: {
            values: {
                limitType?: | "afterTimeInterval"
                | "atSpecifiedTime";
                maxDateAndTime?: string;
                resumeAmount?: number;
                resumeUnit?: "minutes"
                | "hours"
                | "days";
            };
        };
        messageButtonLabel?: string;
        responseFormButtonLabel?: string;
        responseFormCustomCss?: string;
        responseFormDescription?: string;
        responseFormTitle?: string;
    };
    queryId?: string;
    replyKeyboard?: {
        rows: {
            row?: {
                buttons: {
                    additionalFields?: {
                        request_contact?: (...)
                        | (...)
                        | (...);
                        request_location?: (...) | (...) | (...);
                        web_app?: (...) | (...);
                    };
                    text?: string;
                }[];
            };
        }[];
    };
    replyKeyboardOptions?: {
        one_time_keyboard?: boolean;
        resize_keyboard?: boolean;
        selective?: boolean;
    };
    replyKeyboardRemove?: {
        remove_keyboard?: boolean;
        selective?: boolean;
    };
    replyMarkup?: | "none"
    | "inlineKeyboard"
    | "forceReply"
    | "replyKeyboard"
    | "replyKeyboardRemove";
    resource?: "file"
    | "message"
    | "chat"
    | "callback";
    responseType?: "approval" | "freeText" | "customForm";
    results?: string;
    text?: string;
    title?: string;
    userId?: string;
}

Properties§

Source§

readonly action?:
    | "find_location"
    | "record_audio"
    | "record_video"
    | "record_video_note"
    | "typing"
    | "upload_audio"
    | "upload_document"
    | "upload_photo"
    | "upload_video"
    | "upload_video_note"

Type of action to broadcast. Choose one, depending on what the user is about to receive. The status is set for 5 seconds or less (when a message arrives from your bot). Default: "typing"

Source§

readonly additionalFields?:
    | { disable_notification?: boolean }
    | {
        cache_time?: number;
        show_alert?: boolean;
        text?: string;
        url?: string;
    }
    | { mimeType?: string }
    | {
        appendAttribution?: boolean;
        caption?: string;
        disable_notification?: boolean;
        disable_web_page_preview?: boolean;
        duration?: number;
        fileName?: string;
        height?: number;
        message_thread_id?: number;
        parse_mode?: "HTML" | "Markdown" | "MarkdownV2";
        performer?: string;
        reply_to_message_id?: number;
        thumb?: string;
        title?: string;
        width?: number;
    }

Default: {}

Source§

readonly approvalOptions?: {
    values: {
        approvalType?: "single" | "double";
        approveLabel?: string;
        disapproveLabel?: string;
    };
}

Default: {}

Source§

readonly binaryData?: boolean

Whether the data to upload should be taken from binary field

Source§

readonly binaryPropertyName?: string

Name of the binary property that contains the data to upload Default: "data"

Source§

readonly chatId?: string

Unique identifier for the target chat or username, To find your chat ID ask @get_id_bot

Source§

readonly defineForm?: "json" | "fields"

Default: "fields"

Source§

readonly description?: string

New chat description, 0-255 characters

Source§

readonly download?: boolean

Whether to download the file Default: true

Source§

readonly file?: string

Animation to send. Pass a file_id to send an animation that exists on the Telegram servers (recommended), an HTTP URL for Telegram to get an animation from the Internet.

Source§

readonly fileId?: string

The ID of the file

Source§

readonly forceReply?: { force_reply?: boolean; selective?: boolean }

Default: {}

Source§

readonly formFields?: {
    values: {
        acceptFileTypes?: string;
        elementName?: string;
        fieldLabel: string;
        fieldName?: string;
        fieldOptions: { values: { option?: string }[] };
        fieldType:
            | "number"
            | "file"
            | "text"
            | "email"
            | "date"
            | "html"
            | "checkbox"
            | "dropdown"
            | "hiddenField"
            | "password"
            | "radio"
            | "textarea";
        fieldValue?: string;
        formatDate?: string;
        html?: string;
        limitSelection?: "exact"
        | "range"
        | "unlimited";
        maxSelections?: number;
        minSelections?: number;
        multipleFiles?: boolean;
        multiselect?: boolean;
        multiselectLegacyNotice?: string;
        numberOfSelections?: number;
        placeholder?: string;
        requiredField?: boolean;
    }[];
}

Default: {} Type options: {"multipleValues":true,"sortable":true}

Source§

readonly inlineKeyboard?: {
    rows: {
        row?: {
            buttons: {
                additionalFields?: {
                    callback_data?: (...) | (...);
                    pay?: (...) | (...) | (...);
                    switch_inline_query?: (...) | (...);
                    switch_inline_query_current_chat?: (...) | (...);
                    url?: (...) | (...);
                    web_app?: (...) | (...);
                };
                text?: string;
            }[];
        };
    }[];
}

Adds an inline keyboard that appears right next to the message it belongs to Default: {} Type options: {"multipleValues":true}

Source§

readonly inlineMessageId?: string

Unique identifier of the inline message to edit

Source§

readonly jsonOutput?: string

Default: "[\n {\n "fieldLabel":"Name",\n "placeholder":"enter you name",\n "requiredField":true\n },\n {\n "fieldLabel":"Age",\n "fieldType":"number",\n "placeholder":"enter your age"\n },\n {\n "fieldLabel":"Email",\n "fieldType":"email",\n "requiredField":true\n }\n]" Type options: {"rows":5}

Source§

readonly latitude?: number

Location latitude Type options: {"numberPrecision":10,"minValue":-90,"maxValue":90}

Source§

readonly longitude?: number

Location longitude Type options: {"numberPrecision":10,"minValue":-180,"maxValue":180}

Source§

readonly media?: {
    media: {
        additionalFields?: {
            caption?: string;
            parse_mode?: "HTML" | "Markdown" | "MarkdownV2";
        };
        media?: string;
        type?: "video"
        | "photo";
    }[];
}

The media to add Default: {} Type options: {"multipleValues":true}

Source§

readonly message?: string

Type options: {"rows":4}

Source§

readonly messageId?: string

Unique identifier of the message to delete

Source§

readonly messageType?: "message" | "inlineMessage"

The type of the message to edit Default: "message"

Source§

readonly operation?:
    | "get"
    | "sendMessage"
    | "member"
    | "deleteMessage"
    | "sendAndWait"
    | "leave"
    | "administrators"
    | "setDescription"
    | "setTitle"
    | "answerQuery"
    | "answerInlineQuery"
    | "editMessageText"
    | "pinChatMessage"
    | "sendAnimation"
    | "sendAudio"
    | "sendChatAction"
    | "sendDocument"
    | "sendLocation"
    | "sendMediaGroup"
    | "sendPhoto"
    | "sendSticker"
    | "sendVideo"
    | "unpinChatMessage"

Default: "get"

Source§

readonly options?:
    | {
        appendAttribution?: boolean;
        limitWaitTime?: {
            values: {
                limitType?: | "afterTimeInterval"
                | "atSpecifiedTime";
                maxDateAndTime?: string;
                resumeAmount?: number;
                resumeUnit?: "minutes"
                | "hours"
                | "days";
            };
        };
    }
    | {
        appendAttribution?: boolean;
        limitWaitTime?: {
            values: {
                limitType?: | "afterTimeInterval"
                | "atSpecifiedTime";
                maxDateAndTime?: string;
                resumeAmount?: number;
                resumeUnit?: "minutes"
                | "hours"
                | "days";
            };
        };
        messageButtonLabel?: string;
        responseFormButtonLabel?: string;
        responseFormCustomCss?: string;
        responseFormDescription?: string;
        responseFormTitle?: string;
    }

Default: {}

Source§

readonly queryId?: string

Unique identifier for the query to be answered

Source§

readonly replyKeyboard?: {
    rows: {
        row?: {
            buttons: {
                additionalFields?: {
                    request_contact?: (...) | (...) | (...);
                    request_location?: (...) | (...) | (...);
                    web_app?: (...) | (...);
                };
                text?: string;
            }[];
        };
    }[];
}

Adds a custom keyboard with reply options Default: {} Type options: {"multipleValues":true}

Source§

readonly replyKeyboardOptions?: {
    one_time_keyboard?: boolean;
    resize_keyboard?: boolean;
    selective?: boolean;
}

Default: {}

Source§

readonly replyKeyboardRemove?: { remove_keyboard?: boolean; selective?: boolean }

Default: {}

Source§

readonly replyMarkup?:
    | "none"
    | "inlineKeyboard"
    | "forceReply"
    | "replyKeyboard"
    | "replyKeyboardRemove"

Additional interface options Default: "none"

Source§

readonly resource?: "file" | "message" | "chat" | "callback"

Default: "message"

Source§

readonly responseType?: "approval" | "freeText" | "customForm"

Default: "approval"

Source§

readonly results?: string

A JSON-serialized array of results for the inline query

Source§

readonly text?: string

Text of the message to be sent

Source§

readonly title?: string

New chat title, 1-255 characters

Source§

readonly userId?: string

Unique identifier of the target user