Interface DiscourseNodeParameters

Source
interface DiscourseNodeParameters {
    additionalFields?:
        | {
            category?: string;
            reply_to_post_number?: string;
            topic_id?: string;
        }
        | { active?: boolean; approved?: boolean };
    by?: "username" | "externalId";
    categoryId?: string;
    color?: string;
    content?: string;
    email?: string;
    externalId?: string;
    flag?:
        | "new"
        | "blocked"
        | "active"
        | "staff"
        | "suspect"
        | "suspended";
    groupId?: string;
    limit?: number;
    name?: string;
    operation?: | "create"
    | "get"
    | "getAll"
    | "update"
    | "add"
    | "remove";
    options?: {
        asc?: boolean;
        order?: | "email"
        | "username"
        | "created"
        | "days_visited"
        | "last_emailed"
        | "posts"
        | "posts_read"
        | "read_time"
        | "seen"
        | "topics_viewed"
        | "trust_level";
        showEmails?: boolean;
        stats?: boolean;
    };
    password?: string;
    postId?: string;
    resource?: | "user"
    | "group"
    | "category"
    | "post"
    | "userGroup";
    returnAll?: boolean;
    textColor?: string;
    title?: string;
    updateFields?: | { color?: string; textColor?: string }
    | { cooked?: boolean; edit_reason?: string };
    username?: string;
    usernames?: string;
}

Properties§

Source§

readonly additionalFields?:
    | {
        category?: string;
        reply_to_post_number?: string;
        topic_id?: string;
    }
    | { active?: boolean; approved?: boolean }

Default: {}

Source§

readonly by?: "username" | "externalId"

What to search by Default: "username"

Source§

readonly categoryId?: string

ID of the category

Source§

readonly color?: string

Color of the category Default: "0000FF"

Source§

readonly content?: string

Content of the post

Source§

readonly email?: string

Email of the user to create

Source§

readonly externalId?: string

Discourse SSO external ID

Source§

readonly flag?:
    | "new"
    | "blocked"
    | "active"
    | "staff"
    | "suspect"
    | "suspended"

User flags to search for

Source§

readonly groupId?: string

ID of the group to update

Source§

readonly limit?: number

Max number of results to return Default: 50 Type options: {"minValue":1,"maxValue":100}

Source§

readonly name?: string

Name of the category

Source§

readonly operation?: "create" | "get" | "getAll" | "update" | "add" | "remove"

Choose an operation Default: "create"

Source§

readonly options?: {
    asc?: boolean;
    order?:
        | "email"
        | "username"
        | "created"
        | "days_visited"
        | "last_emailed"
        | "posts"
        | "posts_read"
        | "read_time"
        | "seen"
        | "topics_viewed"
        | "trust_level";
    showEmails?: boolean;
    stats?: boolean;
}

Default: {}

Source§

readonly password?: string

The password of the user to create Type options: {"password":true}

Source§

readonly postId?: string

ID of the post

Source§

readonly resource?: "user" | "group" | "category" | "post" | "userGroup"

Default: "post"

Source§

readonly returnAll?: boolean

Whether to return all results or only up to a given limit

Source§

readonly textColor?: string

Text color of the category Default: "0000FF"

Source§

readonly title?: string

Title of the post

Source§

readonly updateFields?:
    | { color?: string; textColor?: string }
    | { cooked?: boolean; edit_reason?: string }

Default: {}

Source§

readonly username?: string

The username of the user to create

Source§

readonly usernames?: string

Usernames to add to group. Multiples can be defined separated by comma.