ordercloud-javascript-sdk
    Preparing search index...

    Class MessageSenders

    Index
    • Returns this

      enables impersonation by calling the subsequent method with the stored impersonation token

      MessageSenders.As().List() // lists MessageSenders using the impersonated users' token
      
    • Delete a message sender Check out the docs for more info

      Parameters

      • messageSenderID: string

        ID of the message sender.

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<void>

    • Delete a message sender assignment Check out the docs for more info

      Parameters

      • messageSenderID: string

        ID of the message sender.

      • listOptions: { buyerID?: string; supplierID?: string; userGroupID?: string; userID?: string } = {}
        • OptionalbuyerID?: string

          ID of the buyer.

        • OptionalsupplierID?: string

          ID of the supplier.

        • OptionaluserGroupID?: string

          ID of the user group.

        • OptionaluserID?: string

          ID of the user.

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<void>

    • List message senders Check out the docs for more info

      Type Parameters

      Parameters

      • listOptions: {
            filters?: Filters;
            page?: number;
            pageSize?: number;
            search?: string;
            searchOn?: ("ID" | "Name")[];
            sortBy?: ("ID" | "Name" | "!ID" | "!Name")[];
        } = {}
        • Optionalfilters?: Filters

          An object or dictionary representing key/value pairs to apply as filters. Valid keys are top-level properties of the returned model or 'xp.???'

        • Optionalpage?: number

          Page of results to return. When paginating through many items (> page 30), we recommend the "Last ID" method, as outlined in the Advanced Querying documentation.

        • OptionalpageSize?: number

          Number of results to return per page.

        • Optionalsearch?: string

          Word or phrase to search for.

        • OptionalsearchOn?: ("ID" | "Name")[]

          Comma-delimited list of fields to search on.

        • OptionalsortBy?: ("ID" | "Name" | "!ID" | "!Name")[]

          Comma-delimited list of fields to sort by.

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<RequiredObjectDeep<ListPage<TMessageSender>>>

    • List message sender assignments Check out the docs for more info

      Type Parameters

      Parameters

      • listOptions: {
            buyerID?: string;
            level?: "Group" | "Company";
            messageSenderID?: string;
            page?: number;
            pageSize?: number;
            supplierID?: string;
            userGroupID?: string;
        } = {}
        • OptionalbuyerID?: string

          ID of the buyer.

        • Optionallevel?: "Group" | "Company"

          Level of the message sender assignment. Possible values: Group, Company, BuyerGroup.

        • OptionalmessageSenderID?: string

          ID of the message sender.

        • Optionalpage?: number

          Page of results to return. When paginating through many items (> page 30), we recommend the "Last ID" method, as outlined in the Advanced Querying documentation.

        • OptionalpageSize?: number

          Number of results to return per page.

        • OptionalsupplierID?: string

          ID of the supplier.

        • OptionaluserGroupID?: string

          ID of the user group.

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<RequiredObjectDeep<ListPage<TMessageSenderAssignment>>>

    • List message sender cc listener assignments Check out the docs for more info

      Type Parameters

      Parameters

      • listOptions: {
            filters?: Filters;
            page?: number;
            pageSize?: number;
            search?: string;
            searchOn?: (
                | "BuyerID"
                | "UserID"
                | "UserGroupID"
                | "MessageConfigName"
                | "SupplierID"
            )[];
            sortBy?: (
                | "BuyerID"
                | "UserID"
                | "UserGroupID"
                | "MessageConfigName"
                | "SupplierID"
                | "!BuyerID"
                | "!UserID"
                | "!UserGroupID"
                | "!MessageConfigName"
                | "!SupplierID"
            )[];
        } = {}
        • Optionalfilters?: Filters

          An object or dictionary representing key/value pairs to apply as filters. Valid keys are top-level properties of the returned model or 'xp.???'

        • Optionalpage?: number

          Page of results to return. When paginating through many items (> page 30), we recommend the "Last ID" method, as outlined in the Advanced Querying documentation.

        • OptionalpageSize?: number

          Number of results to return per page.

        • Optionalsearch?: string

          Word or phrase to search for.

        • OptionalsearchOn?: ("BuyerID" | "UserID" | "UserGroupID" | "MessageConfigName" | "SupplierID")[]

          Comma-delimited list of fields to search on.

        • OptionalsortBy?: (
              | "BuyerID"
              | "UserID"
              | "UserGroupID"
              | "MessageConfigName"
              | "SupplierID"
              | "!BuyerID"
              | "!UserID"
              | "!UserGroupID"
              | "!MessageConfigName"
              | "!SupplierID"
          )[]

          Comma-delimited list of fields to sort by.

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<RequiredObjectDeep<ListPage<TMessageCCListenerAssignment>>>

    • Create or update a message sender If an object with the same ID already exists, it will be overwritten. Check out the docs for more info

      Type Parameters

      Parameters

      • messageSenderID: string

        ID of the message sender.

      • messageSender: MessageSender

        Required fields: Name, MessageTypes, DeliveryConfigID

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<RequiredDeep<TMessageSender>>

    • Create or update a message sender assignment Check out the docs for more info

      Parameters

      • messageSenderAssignment: MessageSenderAssignment

        Required fields: MessageSenderID

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<void>

    • Create or update a message sender cc listener assignment Check out the docs for more info

      Parameters

      • messageCCListenerAssignment: MessageCCListenerAssignment

        Required fields: MessageSenderAssignment, MessageType

      • requestOptions: RequestOptions = {}
        • OptionalaccessToken?: string

          Alternative token to the one stored in the sdk instance (useful for impersonation).

        • OptionalrequestType?: string

          Identify the type of request. Useful for error logs.

        • Optionalsignal?: AbortSignal

          AbortSignal that can be used to cancel the request.

      Returns Promise<void>