User Guide
6.4
6.4
  • Rocket.Chat
    • Our Plans
  • Deploy
    • Deploy Rocket.Chat
      • System Requirements
      • Deploy with Docker & Docker Compose
      • Deploy with AWS
      • Deploy with Snaps
      • Updating Rocket.Chat
      • Scaling Rocket.Chat
        • Microservices
        • Running Multiple Instances
        • Automation Tools
          • Ansible
          • OpenShift
          • Vagrant
      • Additional Deployment Methods
        • Deploy with Kubernetes
        • Deploy with Digital Ocean
        • Deploy on Google Compute Engine
        • Deploy with Ubuntu
        • Deploy with CentOS
        • Deploy on Kali
        • Deploy on Debian
        • Deploy on IBM Cloud
        • Deploy on Windows 10
        • Plug-in Deployments
        • Unsupported Methods
          • OpenSUSE Leap 42.2
          • FreeBSD
            • Deploying Rocket.Chat Server Binaries on a FreeBSD system
          • Windows Server
          • Linode
          • Scalingo
          • Cloudron.io
          • Jelastic
          • Aliyun
          • Galaxy
          • Syncloud
          • OpenShift
  • Setup and Configure
    • Environment Configuration
      • Deployment Environment Variables
        • Manage Settings Using Environmental Variables
      • MongoDB Configuration
        • MongoDB URI Authentication
        • MongoDB Backup and Restore
        • Additional MongoDB Driver Options
        • Configure a Replica Set for MongoDB
        • Migrate from Built-In Meteor MongoDB to External Server
        • Migrate from mmap to WiredTiger Storage Engine
        • Supported MongoDB Versions
      • Firewall Configuration
      • Configuring SSL Reverse Proxy
      • Additional Configurations
        • Running in a sub folder with Apache
        • Univention Corporate Server (UCS)
        • Setting Up Client SSL Certificate Authentication for Rocket.Chat
        • Setting up Process Managers and Init Systems
      • Check Node.js Version
    • Installing Client Apps
      • Desktop & Mobile Apps
      • Minimum Requirements for Client Apps
    • Trials
      • Pro Trial
      • Enterprise Trial
    • License Application
    • Accessing Your Workspace
      • Rocket.Chat Setup Wizard
      • Admin Account Creation
      • Basic White-labeling
      • Inviting Users
    • Advanced workspace management
      • Google Translate Integration
      • Database Migration
      • Restoring an Admin User
      • CDN
      • Troubleshooting
      • Client Compatibility Matrix
    • Rocket.Chat Air-gapped Deployment
      • Offline Workspace Registration
      • Offline License
      • Air-gapped workspace Configuration
      • Air-gapped App Installation
    • Roles in Rocket.Chat
  • Use Rocket.Chat
    • User Guides
      • Access your workspace
      • Main Menu
      • User Panel
        • Account
        • Accessibility and appearance
        • Manage Devices
      • Rooms
        • Channels
          • Create a new Channel
          • Edit A Channel
          • Manage Channel Members
          • Search Messages in a Channel
        • Teams
          • Create a new Team
          • Edit a Team
          • Manage Team Members
          • Manage Team Channels
          • Teams Premium Plan
        • Discussions
          • Create a new Discussion
          • Edit A Discussion
          • Search Messages in Discussion
          • Manage Discussion Members
        • Direct Messages
          • Create a new Direct Message
          • Direct Message Actions
        • Threads
          • Create a New Thread
        • Room Roles
      • Messages
        • Message Actions
        • Off-the-record (OTR) Messaging User Guide
      • Notifications
      • Security Bundle
        • Data Loss Prevention User Guide
        • End to End Encryption User Guide
        • Two Factor Authentication User Guide
      • Keyboard Shortcuts
    • Workspace Administration
      • Workspace
      • Subscription
      • Registration
      • Engagement
      • Moderation
      • Federation
      • Rooms
      • Users
        • Guest Users
        • Monthly Active Contacts (MACs)
        • Add users through Identity management and authentication services
      • Invites
      • User Status
      • Permissions
        • Setting's Permission
      • Device Management
      • Email Inboxes
      • Mailer
      • Third-party Login
      • Integrations
        • AppVeyor
        • Azure Alerts
        • BitRocket
        • Dead Simple Screen Sharing
        • EasyRedmine
        • Giphy Integrations
        • GitLab
        • Google Calendar
        • GitHub
        • Graylog
        • Jenkins notifications via Rocket.Chat Marketplace
        • JFrog Xray
        • MicroBadger
        • Microsoft Teams
        • NewRelic
        • Nextcloud and WebDAV integrations
        • Nextcloud Rocket.Chat App
        • Nixstats notification
        • PagerDuty
        • Prometheus
        • Grafana
        • Review Board
        • RunDeck Job Notifications
        • Sentry
        • Simple Telegram Bot
        • TravisCI
        • Uptime Robot
        • Zapier
        • django-rocketchat-auth 1.2
        • Add Jira notifications via webhook
      • Import
        • Import from HipChat
        • Import from Slack
          • SlackBridge
        • Import CSV
      • Reports
      • Sounds
      • Emoji
      • Settings
        • Accounts
          • Custom Fields
        • Analytics
        • Assets
        • Bots
        • CAS
        • Conference Call
        • Custom Emoji Filesystem
        • Custom Sound Filesystem
        • Discussion
        • E2E Encryption
        • Email
          • Edit your Email Content
          • Direct email reply
          • Email configuration
        • Federation
          • Matrix Bridge
            • Matrix Admin Guide
              • Matrix Homeserver Setup
                • Matrix Allow/Block List
              • Matrix Bridge Configuration
            • Matrix User's Guide
              • Create federated rooms
              • Invite external users to your Rocket.Chat server
              • Communicate with a federated user
              • Search and join public channels on the Matrix network
              • Assign roles for users in federated rooms
            • Matrix Bridge FAQs
          • Rocket.Chat Basic Federation
            • Cross-server Federated Channels
        • File Upload
          • Minio
          • Recommendations for File Upload
          • File Upload FAQs
        • General
          • Net Promoter Score (NPS) survey
        • IRC Federation
        • Layout
        • LDAP
        • Logs
        • Message
        • Meta
        • Mobile
        • Omnichannel Admin's Guide
          • Queue Types (Routing Algorithm)
        • OTR
        • Outlook Calendar
        • Premium
        • Push
        • Rate Limiter
        • Retention Policy
        • SAML
        • Page
        • Search
        • Setup Wizard
        • SlackBridge
        • Smarsh
        • SMS
        • Threads
        • Troubleshoot
        • User Data Download
        • Voice Channel
        • Webdav Integration
        • WebRTC
        • OAuth
        • Device Management
    • Authentication
      • Authentication Across Plans
      • LDAP
        • Configure LDAP Connection
        • LDAP User Search
        • LDAP Data Sync Settings
        • LDAP Premium Settings
        • LDAP Setup
      • SAML
        • SAML Configuration
        • Active Directory Federation Services
        • Keycloak
      • OAuth
        • Facebook OAuth Setup
        • Google OAuth Setup
        • GitLab OAuth Setup
        • GitHub OAuth Setup
        • LinkedIn OAuth Setup
        • Nextcloud OAuth Setup
        • WordPress OAuth Setup
        • MS Office 365 Custom OAuth Setup
        • Additional OAuth Methods
      • OpenID Connect
        • Keycloak
        • Okta Identity Cloud Service
      • Iframe-based Single Sign-On
    • User Management
      • Custom Roles
      • Device Manager
        • Device Management Settings
      • Message Auditor
        • Audit Edits, Deletions, and Encrypted Communications
        • Audit Logs
    • Omnichannel
      • Current Chats
      • Omnichannel Reports
      • Analytics
      • Real-time Monitoring
      • Managers
      • Agents
      • Departments
      • Custom Fields
      • Livechat Triggers
      • Livechat Widget Installation
      • Livechat Widget Appearance
      • Webhooks
      • Business Hours
      • Monitors
      • Units
      • Canned Responses
        • Canned Responses Omnichannel Manager's Guide
      • Tags
      • SLA Policies
      • Priorities
    • Rocket.Chat Cloud
      • Create your new cloud account
      • Manage your cloud account
        • Custom domain for your Cloud-hosted workspace
        • Profile
        • Organization Settings
        • Workspaces
        • Invoices
        • Payment Methods
        • Security
        • Support
        • Contact Sales
    • Rocket.Chat Voice Channel
      • Getting Started with Voice Channel
      • Voice Channel Admin Guide
        • Configure without previously having a PBX server
          • SIP Extensions
          • Configure asterisk manager interface and users
        • Configure with an active PBX server
          • Associate agents with extensions in Rocket.Chat
      • Voice Channel Technical Specification
      • Voice Channel Agent Guides
        • How to make myself available to accept calls?
        • How to take a call in Rocket.Chat voice channel?
        • How to initiate an outbound call as an agent?
      • Voice Channel FAQs
    • Rocket.Chat Conference Call
      • Conference Call Admin Guide
        • Pexip app
        • Jitsi app
        • BigBlueButton (BBB) app
        • Google Meet app
      • Conference Call User's Guide
      • Omnichannel Video/Audio Call Configuration
    • Rocket.Chat Federation
    • Rocket.Chat Mobile
      • Rooms on Rocket.Chat Mobile
      • Messages and Threads on Mobile
      • Push Notifications
        • Secured Push Notification
        • Push Notifications User Guide
    • Omnichannel Agent's Guides
      • Omnichannel Conversation
      • Omnichannel Queue
      • Omnichannel Contact Center
        • Omnichannel Contact Manager Assignment
      • Email Inboxes
  • Extend Rocket.Chat Capabilities
    • Rocket.Chat Marketplace
      • Rocket.Chat Public Apps Guides
        • Omnichannel Apps
          • SMS
          • Telegram App
            • Telegram Agent's Guide
          • Rasa App
          • Salesforce CRM Integration
            • Salesforce CRM Agent's Guide
          • HubSpot CRM
            • HubSpot CRM Agent's Guide
          • Dialogflow App
            • Upload File To Ongoing Dialogflow Chats
          • Twitter App
            • Twitter App Agent's Guide
          • Facebook App
            • Facebook App Agent's Guide
          • WhatsApp
            • WhatsApp Agent's Guide
          • WhatsApp Sandbox
            • WhatsApp Sandbox Agent's Guide
          • Instagram Direct
            • Instagram Direct Agent's Guide
          • WhatsApp Cloud App
            • Configure Whatsapp Cloud App
            • Using WhatsApp Cloud App
        • Atlassian Apps
          • Jira Server v2.0
          • Bamboo Integration
          • Bitbucket Server
          • Confluence Server
          • Jira Server
        • Pexip App
        • Jitsi app
        • BigBlueButton (BBB) app
        • Google Meet app
        • Trello
          • Using the Trello App
        • Zoom
          • Using the Zoom App
        • Data Loss Prevention (DLP) App
        • Poll
        • Poll Plus
          • Poll Plus Features
        • Microsoft Teams Bridge
          • Using Microsoft Teams Bridge
        • GitHub App
          • Using GitHub App
        • Google Drive
          • Using the Google Drive App
        • Google Calendar
          • Using the Google Calendar App
        • Zapier App
          • Install Zapier App
          • Using Zapier App
        • ChatGPT App
          • Using the ChatGPT App
        • Mod Assist App
          • Using the Mod Assist App
        • ClamAV Integration
      • App Storage Location
    • Integrations
    • Rocket.Chat API
  • Resources
    • Frequently Asked Questions
      • Accessing your workspace FAQs
      • License FAQs
        • Trial FAQ
        • Downgrade behavior
        • Fair use allowance FAQs
      • My Account FAQs
      • Registration
      • Message Privacy
      • Localization
      • Apps FAQs
      • Update FAQs
      • WhatsApp Cloud API FAQs
      • Cloud FAQs
      • Support FAQs
      • Whatsapp Business App FAQs
      • Identity Management FAQ
      • Deployment FAQ
        • Updating Rocket.Chat FAQ
        • Snaps FAQ
      • Federation FAQs
      • Monthly Active Contacts FAQs
      • Omnichannel FAQs
    • Brand and Visual Guidelines
      • Logo
      • Typography
      • Colors
      • Patterns
      • Iconography
      • Photos
      • Brand Usage Examples
      • Media Kit
    • Developer Documentation
    • Glossary
  • Contribute to Rocket.Chat
    • Contributor Code of Conduct
    • How Can I Help?
    • Annual Contribution Programs
  • APPLICABLE TERMS
    • Customer Terms of Service
    • Additional Terms
      • Terms of Use
      • Acceptable Use Policy
      • Service-Specific Terms
        • Master Service Agreement for Professional Services
        • Cloud Services Terms
          • Marketplace and Apps
  • CUSTOMER CENTER
    • Cloud Services Center
      • Rocket.Chat Cloud Hosting Service Level Agreement (SLA)
    • Security Center
      • Security Policy
      • Compliance Resources
      • Security fixes and updates
        • cve-2022-32211
      • End-to-End Encryption Specifications
    • Support Center
      • Premium Support Plans
        • Support Prerequisites and Version Durability
        • Premium Support Channels
        • Our Support Ticket Classification System and SLAs
        • Rocket.Chat Legacy Support
      • Community Resources
    • Legal Center
      • Privacy Policy
        • Subprocessors
        • Privacy Policy Facebook Messenger
        • Privacy Notice for Air-Gapped Workspaces
      • GDPR
        • Data Processing Agreement
      • LGDP
        • Nomeação do Encarregado pelo Tratamento de Dados Pessoais
      • DMCA Policy
      • Accessibility statement
      • Code of Conduct: Services
      • Law Enforcement
        • Guidelines for Law Enforcement
        • Censorship and Harmful Content
        • Server Lookup
      • Historical Agreements and Policy Archive
Powered by GitBook
On this page
  • Available integrations
  • Incoming webhook script
  • Script details
  • Outgoing webhook script
  • Script details
  • Integration Pattern
  1. Use Rocket.Chat
  2. Workspace Administration

Integrations

Integrate tools and services to ease everyday workflows.

PreviousThird-party LoginNextAppVeyor

Last updated 1 year ago

Rocket.Chat supports webhooks to integrate tools and services you like into the platform. Webhooks are simple event notifications via HTTP POST. This way, any webhook application can post a message to a Rocket.Chat instance and much more.

With scripts, you can point any webhook to Rocket.Chat and process the requests to print customized messages, define the username and avatar of the user of the messages and change the channel for sending messages, or you can cancel the request to prevent undesired messages.

Available integrations

  • Incoming Webhook: Let an external service send a request to Rocket.Chat to be processed.

  • Outgoing Webhook: Let Rocket.Chat trigger and optionally send a request to an external service and process the response.

By default, a webhook is designed to post messages only. The message is part of a JSON structure, which has the same format as that of a .

If you would like more power and control over various features of Rocket.Chat, aside from sending and receiving messages, take a look at

Incoming webhook script

ES2015 / ECMAScript 6 scripts can handle Webhooks to process the request, print customized messages, or cancel the request to prevent undesired messages.

Create a new incoming webhook

To create a new incoming webhook:

  • Navigate to Administration > Workspace > Integrations.

  • Click +New at the top right corner.

  • Switch to the Incoming tab**.**

  • Turn on the Enabled toggle.

  • Name: Enter a name for your webhook. The name is optional; however, providing a name to manage your integrations easily is advisable.

  • Post to Channel: Select the channel (or user) where you prefer to receive the alerts. It is possible to override messages.

  • Post as: Choose the username that this integration posts as. The user must already exist.

  • Alias: Optionally enter a nickname that appears before the username in messages.

  • Avatar URL: Enter a link to an image as the avatar URL if you have one. The avatar URL overrides the default avatar.

  • Emoji: Enter an emoji optionally to use the emoji as the avatar. Check the emoji cheat sheet .

  • Turn on the Script Enabled toggle.

  • Paste your script inside the Script field.

  • Save the integration.

  • Use the generated Webhook URL to post messages to Rocket.Chat.

Script details

The Rocket.Chat integration script should be written in ES2015 / ECMAScript 6. The script requires a global class named Script, which is instantiated only once during the first execution and kept in memory. This class contains a method called process_incoming_request, which is called by your server each time it receives a new request. The process_incoming_request method takes an object as a parameter with the request property and returns an object with a content property containing a valid Rocket.Chat message, or an object with an error property, which is returned as the response to the request in JSON format with a Code 400 status.

A valid Rocket.Chat message must contain a text field that serves as the body of the message. If you redirect the message to a channel other than the one indicated by the webhook token, yyou can specify a channel field that accepts room id or, if prefixed with "#" or "@", channel name or user, respectively.

/* exported Script */
/* globals console, _, s */

/** Global Helpers
 *
 * console - A normal console instance
 * _       - An underscore instance
 * s       - An underscore string instance
 */

class Script {
  /**
   * @params {object} request
   */
  process_incoming_request({ request }) {
    // request.url.hash
    // request.url.search
    // request.url.query
    // request.url.pathname
    // request.url.path
    // request.url_raw
    // request.url_params
    // request.headers
    // request.user._id
    // request.user.name
    // request.user.username
    // request.content_raw
    // request.content

    // console is a global helper to improve debug
    console.log(request.content);

    return {
      content:{
        text: request.content.text
        // "attachments": [{
        //   "color": "#FF0000",
        //   "author_name": "Rocket.Cat",
        //   "author_link": "https://open.rocket.chat/direct/rocket.cat",
        //   "author_icon": "https://open.rocket.chat/avatar/rocket.cat.jpg",
        //   "title": "Rocket.Chat",
        //   "title_link": "https://rocket.chat",
        //   "text": "Rocket.Chat, the best open source chat",
        //   "fields": [{
        //     "title": "Priority",
        //     "value": "High",
        //     "short": false
        //   }],
        //   "image_url": "https://rocket.chat/images/mockup.png",
        //   "thumb_url": "https://rocket.chat/images/mockup.png"
        // }]
       }
    };

    // return {
    //   error: {
    //     success: false,
    //     message: 'Error example'
    //   }
    // };
  }
}
curl -X POST \
  -H 'Content-Type: application/json' \
  --data '{
      "emoji": ":smirk:",
      "text": "Example message",
      "attachments": [
          {
              "title": "Rocket.Chat",
              "title_link": "https://rocket.chat",
              "text": "Rocket.Chat, the best open source chat",
              "image_url": "link-to-an-image",
              "color": "#764FA5"
          }
      ]
  }' \
  https://your-webhook-url

Outgoing webhook script

You can utilize scripts to process all messages from a channel and modify how Rocket.Chat creates or cancels the request. You have the option to either cancel the request and return a message or take no action. Additionally, you can create another request within the script using the HTTP global helper. When a response is received from the request, it executes the script, calling another method that allows you to process the response, similar to incoming webhooks. To create a new outgoing webhook, follow these steps.

Create a new outgoing webhook

To create a new outgoing webhook:

  • Navigate to Administration > Workspace > Integrations.

  • Click +New in the top right corner.

  • Switch to the Outgoing tab**.**

  • Event Trigger: Select the type of event that triggers this outgoing webhook integration.

  • Turn on the Enabled toggle.

  • Name: Enter a name for your webhook.

  • Channel: Enter the channel to listen to.

  • Trigger Words: If your event trigger is Message Sent, enter the words that should trigger this webhook separated by commas.

  • Enter the URL called for each request in the URLs field. You can modify this URL inside the script.

  • Post as: Enter the username that this integration posts as. This field is optional.

  • Alias: Enter a nickname that appears before the username in messages.

  • Avatar URL: Optionally enter an image URL as the avatar for each message the webhook posts.

  • Emoji: Optionally enter an emoji to use as an avatar.

  • Token: Enter a token that is used to verify authorized webhook calls. The token is optional but essential to avoid cross-site request forgery (CSRF) or replay attacks.

  • Turn on Script Enabled.

  • Paste your script inside the Script field.

  • Save your integration.

Script details

The script should be in ES2015 / ECMAScript 6. The script expects a global class called Script. This class is instantiated once, only on the first execution, and kept in memory. The class has a method called prepare_outgoing_request, called in the configured channel for the event triggers:

  • Message Sent: Called in the configured channel when the message starts with any Trigger Words.

  • File Uploaded: Called when any file is uploaded in the configured channel.

  • Room Archived: Called when a room is archived.

  • Room Created: Called when a room is created.

  • User Joined Room: Called when a user joins the channel.

The prepare_outgoing_request method returns an object with at least url and method properties. You can also change the request object and replace it. It is possible to return nothing and cancel the request or return a message.

The Script class has another method named process_outgoing_response. The method process_outgoing_response is called for every request response, with an object as a parameter containing the request property, that is, the object you returned in the previous method and a response property. The process_outgoing_response method can return nothing to proceed with the default processing, return false to stop it, or an object with the content property that contains a valid Rocket.Chat message.

The example script sends commands such as issues, comments, and pull requests to GitHub.

/* exported Script */
/* globals console, _, s, HTTP */

/** Global Helpers
 *
 * console - A standard console instance
 * _       - An underscore instance
 * s       - An underscore string instance
 * HTTP    - The Meteor HTTP object to do sync http calls
 */

class Script {
  /**
   * @params {object} request
   */
  prepare_outgoing_request({ request }) {
    // request.params            {object}
    // request.method            {string}
    // request.url               {string}
    // request.auth              {string}
    // request.headers           {object}
    // request.data.token        {string}
    // request.data.channel_id   {string}
    // request.data.channel_name {string}
    // request.data.timestamp    {date}
    // request.data.user_id      {string}
    // request.data.user_name    {string}
    // request.data.text         {string}
    // request.data.trigger_word {string}

    let match;

    // Change the URL and method of the request
    match = request.data.text.match(/^pr\s(ls|list)/);
    if (match) {
      return {
        url: request.url + '/pulls',
        headers: request.headers,
        method: 'GET'
      };
    }

    // Prevent the request and return a new message
    match = request.data.text.match(/^help$/);
    if (match) {
      return {
        message: {
          text: [
            '**commands**',
            '```',
              '  pr ls [open|closed|all]  List Pull Requests',
            '```'
          ].join('\n')
          // "channel": "#name-of-channel",
          // "attachments": [{
          //   "color": "#FF0000",
          //   "author_name": "Rocket.Cat",
          //   "author_link": "https://open.rocket.chat/direct/rocket.cat",
          //   "author_icon": "https://open.rocket.chat/avatar/rocket.cat.jpg",
          //   "title": "Rocket.Chat",
          //   "title_link": "https://rocket.chat",
          //   "text": "Rocket.Chat, the best open source chat",
          //   "fields": [{
          //     "title": "Priority",
          //     "value": "High",
          //     "short": false
          //   }],
          //   "image_url": "https://rocket.chat/images/mockup.png",
          //   "thumb_url": "https://rocket.chat/images/mockup.png"
          // }]
        }
      };
    }
  }

  /**
   * @params {object} request, response
   */
  process_outgoing_response({ request, response }) {
    // request              {object} - the object returned by prepare_outgoing_request

    // response.error       {object}
    // response.status_code {integer}
    // response.content     {object}
    // response.content_raw {string/object}
    // response.headers     {object}

    var text = [];
    response.content.forEach(function(pr) {
      text.push('> '+pr.state+' [#'+pr.number+']('+pr.html_url+') - '+pr.title);
    });

    // Return false will abort the response
    // return false;

    // Return empty will proceed with the default response process
    // return;

    return {
      content: {
        text: text.join('\n'),
        parseUrls: false
        // "attachments": [{
        //   "color": "#FF0000",
        //   "author_name": "Rocket.Cat",
        //   "author_link": "https://open.rocket.chat/direct/rocket.cat",
        //   "author_icon": "https://open.rocket.chat/avatar/rocket.cat.jpg",
        //   "title": "Rocket.Chat",
        //   "title_link": "https://rocket.chat",
        //   "text": "Rocket.Chat, the best open source chat",
        //   "fields": [{
        //     "title": "Priority",
        //     "value": "High",
        //     "short": false
        //   }],
        //   "image_url": "https://rocket.chat/images/mockup.png",
        //   "thumb_url": "https://rocket.chat/images/mockup.png"
        // }]
      }
    };
  }
}

Integration Pattern

Pattern for Incoming Webhooks

For incoming webhooks, you notify Rocket.Chat from another platform through webhooks, and the pattern is as follows:

  1. Create an incoming webhook on Rocket.Chat.

  2. Understand the structure of data of the sending platform. Most platforms return data in the form of JSON. Know the structure of data that is sent to your webhook.

  3. Construct a Rocket.Chat message: Using the data returned by the third-party platform, construct a Rocket.Chat message using the returned data's attributes. The payload of the message is in this structure.

Pattern for Outgoing Webhooks

For outgoing webhooks, you notify a third-party platform about events occurring on your Rocket.Chat workspace and the pattern is as follows:

  1. Generate a webhook on a third-party platform, such as Slack.

  2. Create an outgoing webhook and replace the URLs field with the generated webhook URL.

  3. Understand the structure of the data that the third-party platform expects, so as to construct this data from Rocket.Chat's message.

  4. Construct the data expected by the third-party platform.

The data manipulation is done in the webhook's Script class.

You can use the console methods to log information to help debug your script. More information about the console can be found . To view the logs, navigate to Administration > Workspace > View Logs.

To test if your integration works, use to make a POST request to the generated webhook URL.

here
curl
Rocket.Chat Apps.
here
Rocket.Chat message