Mailchimp Developer LogoMailchimp Developer Wordmark

Transactional API

  • Allowlists

    Add, list, or delete from your Rejection Allowlist.

    • Exports

      Start an export, or get information on export jobs in progress.

      • IPs

        Request and manage Dedicated IPs for your account, and set up reverse DNS.

        • Inbound

          Manage your inbound domains and routes.

          • Messages

            Send, schedule, or get information on your emails.

            • Search messages by hour

              post

              /messages/search-time-series

              Search the content of recently sent messages and return the aggregated hourly stats for matching messages.

              body parameters

              • keyrequired
                string

                a valid api key

              • query
                string

                the search terms to find matching messages for

              • date_from
                string

                start date

              • date_to
                string

                end date

              • tags
                string[]

                an array of tag names to narrow the search to, will return messages that contain ANY of the tags

              • senders
                string[]

                an array of sender addresses to narrow the search to, will return messages sent by ANY of the senders

              Search messages by hour

              const mailchimpClient = require("@mailchimp/mailchimp_transactional")(
                "YOUR_API_KEY"
              );
              
              const run = async () => {
                const response = await mailchimpClient.messages.searchTimeSeries();
                console.log(response);
              };
              
              run();
              
              

              Success Response

              • HTTP Status 200

                the array of history information

                • Array
                  object[]

                  the stats for a single hour

                  Show Properties

              Example response

              JSON
              [
                {
                  "time": "2019-08-24T14:15:22Z",
                  "sent": 0,
                  "hard_bounces": 0,
                  "soft_bounces": 0,
                  "rejects": 0,
                  "complaints": 0,
                  "unsubs": 0,
                  "opens": 0,
                  "unique_opens": 0,
                  "clicks": 0,
                  "unique_clicks": 0
                }
              ]
            • Metadata

              Manage your custom metadata fields in your account.

              • Rejects

                Add, list, or delete from your Rejection Denylist.

                • Senders

                  Manage or get information about your sending domains.

                  • Subaccounts

                    Manage your subaccounts, including the abilitiy to pause and resume sending.

                    • Tags

                      List, delete, or get information on your Tags and their sending statistics.

                      • Templates

                        Manage the Templates in your account.

                        • URLs

                          Manage your tracking domains. Some of these endpoints may be deprecated.

                          • Users

                            Get information about your account, or ping Transactional.

                            • Webhooks

                              Manage the webhooks in your account.

                              • Whitelists

                                Add, list, or delete from your Rejection Allowlist. These endpoints are being replaced with a series of functionally identical endpoints called /allowlists.