← Bird + Google Dialogflow integrations

Detect Intent with Google Dialogflow API on New SMS Message Received from Bird API

Pipedream makes it easy to connect APIs for Google Dialogflow, Bird and 2,700+ other apps remarkably fast.

Trigger workflow on
New SMS Message Received from the Bird API
Next, do this
Detect Intent with the Google Dialogflow API
No credit card required
Intro to Pipedream
Watch us build a workflow
Watch us build a workflow
8 min
Watch now ➜

Trusted by 1,000,000+ developers from startups to Fortune 500 companies

Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo
Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo

Developers Pipedream

Getting Started

This integration creates a workflow with a Bird trigger and Google Dialogflow action. When you configure and deploy the workflow, it will run on Pipedream's servers 24x7 for free.

  1. Select this integration
  2. Configure the New SMS Message Received trigger
    1. Connect your Bird account
    2. Configure timer
  3. Configure the Detect Intent action
    1. Connect your Google Dialogflow account
    2. Configure Session ID
    3. Optional- Configure Query Params
    4. Optional- Configure Query Input
    5. Optional- Configure Output Audio Config
    6. Optional- Configure Output Audio Config Mask
    7. Optional- Configure Input Audio File or URL
  4. Deploy the workflow
  5. Send a test event to validate your setup
  6. Turn on the trigger

Details

This integration uses pre-built, source-available components from Pipedream's GitHub repo. These components are developed by Pipedream and the community, and verified and maintained by Pipedream.

To contribute an update to an existing component or create a new component, create a PR on GitHub. If you're new to Pipedream component development, you can start with quickstarts for trigger span and action development, and then review the component API reference.

Trigger

Description:Emit new event when a new SMS message is received. [See the documentation](https://developers.messagebird.com/api/sms-messaging/#list-messages)
Version:0.0.1
Key:message_bird-new-sms-message-received

Bird Overview

Message Bird is a communications platform offering a suite of API solutions for sending messages, making voice calls, and conducting video conferences. With Pipedream, you can harness these capabilities to automate personalized notifications, streamline customer support, and facilitate global communication workflows. Message Bird's API on Pipedream allows you to send real-time alerts, trigger voice messages based on customer actions, and integrate with other services to create powerful, multi-channel communication systems.

Trigger Code

import messagebird from "../../message_bird.app.mjs";
import { DEFAULT_POLLING_SOURCE_TIMER_INTERVAL } from "@pipedream/platform";

export default {
  key: "message_bird-new-sms-message-received",
  name: "New SMS Message Received",
  description: "Emit new event when a new SMS message is received. [See the documentation](https://developers.messagebird.com/api/sms-messaging/#list-messages)",
  version: "0.0.1",
  dedupe: "unique",
  type: "source",
  props: {
    messagebird,
    db: "$.service.db",
    timer: {
      type: "$.interface.timer",
      default: {
        intervalSeconds: DEFAULT_POLLING_SOURCE_TIMER_INTERVAL,
      },
    },
  },
  methods: {
    _getLastTs() {
      return this.db.get("lastTs");
    },
    _setLastTs(lastTs) {
      this.db.set("lastTs", lastTs);
    },
    generateMeta(message) {
      return {
        id: message.id,
        summary: `New Message ID: ${message.id}`,
        ts: Date.parse(message.createdDatetime),
      };
    },
  },
  async run() {
    let lastTs = this._getLastTs();

    const { items } = await this.messagebird.listSMSMessages({
      params: {
        direction: "mo", // mt = sent, mo = received
        type: "sms",
        from: lastTs,
      },
    });

    if (!items?.length) {
      return;
    }

    for (const message of items) {
      const meta = this.generateMeta(message);
      this.$emit(message, meta);

      if (!lastTs || Date.parse(message.createdDatetime) > Date.parse(lastTs)) {
        lastTs = message.createdDatetime;
      }
    }

    this._setLastTs(lastTs);
  },
};

Trigger Configuration

This component may be configured based on the props defined in the component code. Pipedream automatically prompts for input values in the UI and CLI.
LabelPropTypeDescription
BirdmessagebirdappThis component uses the Bird app.
N/Adb$.service.dbThis component uses $.service.db to maintain state between executions.
timer$.interface.timer

Trigger Authentication

Bird uses API keys for authentication. When you connect your Bird account, Pipedream securely stores the keys so you can easily authenticate to Bird APIs in both code and no-code steps.

Once you sign in, the API key information are available in the Developer Settings, which is shown as Manage API Keys in the middle right of the Dashboard

About Bird

Business in a box. Grow, Manage, Automate your company. Everything you need in one app.

Action

Description:Processes a natural language query and returns structured, actionable data as a result, [See REST docs](https://cloud.google.com/dialogflow/es/docs/reference/rest/v2/projects.agent.sessions/detectIntent) and [client API](https://googleapis.dev/nodejs/dialogflow/latest/google.cloud.dialogflow.v2beta1.Sessions.html#detectIntent2)
Version:1.0.0
Key:google_dialogflow-detect-intent

Google Dialogflow Overview

Google Dialogflow API empowers you to create conversational interfaces for websites, apps, and messaging platforms. Think chatbots that can engage in human-like dialogue, provide customer support, guide through sales processes, or control smart home devices with voice commands. With Pipedream's integration capabilities, you can create automated workflows that trigger actions in other apps based on Dialogflow's processed input, enabling seamless interaction across a plethora of services.

Action Code

import googleDialogflow from "../../google_dialogflow.app.mjs";
import utils from "../../common/utils.mjs";

export default {
  type: "action",
  key: "google_dialogflow-detect-intent",
  version: "1.0.0",
  name: "Detect Intent",
  description: "Processes a natural language query and returns structured, actionable data as a result, [See REST docs](https://cloud.google.com/dialogflow/es/docs/reference/rest/v2/projects.agent.sessions/detectIntent) and [client API](https://googleapis.dev/nodejs/dialogflow/latest/google.cloud.dialogflow.v2beta1.Sessions.html#detectIntent2)",
  props: {
    googleDialogflow,
    sessionId: {
      propDefinition: [
        googleDialogflow,
        "sessionId",
      ],
    },
    queryParams: {
      label: "Query Params",
      description: "Properties of Query Parameters, See [client API](https://googleapis.dev/nodejs/dialogflow/latest/google.cloud.dialogflow.v2beta1.IQueryParameters.html)",
      type: "object",
      optional: true,
    },
    queryInput: {
      label: "Query Input",
      description: "Properties of a Query Input, See [client API](https://googleapis.dev/nodejs/dialogflow/latest/google.cloud.dialogflow.v2beta1.IQueryInput.html). For example `{\"text\":{\"text\":\"Hi, what are you doing?\",\"languageCode\":\"en-EN\"}}`",
      type: "object",
      optional: true,
    },
    outputAudioConfig: {
      label: "Output Audio Config",
      description: "Properties of an Output Audio Config, See [client API](https://googleapis.dev/nodejs/dialogflow/latest/google.cloud.dialogflow.v2beta1.IOutputAudioConfig.html)",
      type: "object",
      optional: true,
    },
    outputAudioConfigMask: {
      label: "Output Audio Config Mask",
      description: "Properties of a Field Mask, See [client API](https://googleapis.dev/nodejs/dialogflow/latest/google.protobuf.IFieldMask.html)",
      type: "object",
      optional: true,
    },
    inputAudioFile: {
      label: "Input Audio File or URL",
      description: "Provide a file URL or a path to a file in the `/tmp` directory.",
      type: "string",
      optional: true,
    },
  },
  async run({ $ }) {
    const response = await this.googleDialogflow.detectIntent({
      sessionId: this.sessionId,
      queryParams: utils.parseObject(this.queryParams),
      queryInput: utils.parseObject(this.queryInput),
      outputAudioConfig: utils.parseObject(this.outputAudioConfig),
      outputAudioConfigMask: utils.parseObject(this.outputAudioConfigMask),
      inputAudioFile: this.inputAudioFile,
    });
    $.export("$summary", `Configured query has been sent and received response with ID(${response[0]?.responseId}).`);
    return response[0]; //It always returns an array[3] with no info in index 1, 2
  },
};

Action Configuration

This component may be configured based on the props defined in the component code. Pipedream automatically prompts for input values in the UI.

LabelPropTypeDescription
Google DialogflowgoogleDialogflowappThis component uses the Google Dialogflow app.
Session IDsessionIdstring

A unique session ID, ID of the session created when a context created can be used, e.g. acb92b1d-0a8c-4369-a5fa-ddd7954b2b46

Query ParamsqueryParamsobject

Properties of Query Parameters, See client API

Query InputqueryInputobject

Properties of a Query Input, See client API For example {"text":{"text":"Hi, what are you doing?","languageCode":"en-EN"}}

Output Audio ConfigoutputAudioConfigobject

Properties of an Output Audio Config, See client API

Output Audio Config MaskoutputAudioConfigMaskobject

Properties of a Field Mask, See client API

Input Audio File or URLinputAudioFilestring

Provide a file URL or a path to a file in the /tmp directory.

Action Authentication

Google Dialogflow uses API keys for authentication. When you connect your Google Dialogflow account, Pipedream securely stores the keys so you can easily authenticate to Google Dialogflow APIs in both code and no-code steps.

About Google Dialogflow

Create conversational experiences across devices and platforms.

More Ways to Connect Google Dialogflow + Bird

Create Context with Google Dialogflow API on New SMS Message Received from Bird API
Bird + Google Dialogflow
 
Try it
Create Entities with Google Dialogflow API on New SMS Message Received from Bird API
Bird + Google Dialogflow
 
Try it
Create Entity Type with Google Dialogflow API on New SMS Message Received from Bird API
Bird + Google Dialogflow
 
Try it
Create Intent with Google Dialogflow API on New SMS Message Received from Bird API
Bird + Google Dialogflow
 
Try it
Create or Update Agent with Google Dialogflow API on New SMS Message Received from Bird API
Bird + Google Dialogflow
 
Try it
New SMS Message Received from the Bird API

Emit new event when a new SMS message is received. See the documentation

 
Try it
Create Contact with the Bird API

Creates a new contact. See the documentation

 
Try it
Send SMS with the Bird API

Sends an SMS message. See the documentation

 
Try it
Send Voice Message with the Bird API

Sends a voice message. See the documentation

 
Try it
Create Context with the Google Dialogflow API

Creates a context, See REST docs and client API

 
Try it
Create Entities with the Google Dialogflow API

Batch create entities, See REST docs and client API docs

 
Try it

Explore Other Apps

1
-
24
of
2,700+
apps by most popular

HTTP / Webhook
HTTP / Webhook
Get a unique URL where you can send HTTP or webhook requests
Node
Node
Anything you can do with Node.js, you can do in a Pipedream workflow. This includes using most of npm's 400,000+ packages.
Python
Python
Anything you can do in Python can be done in a Pipedream Workflow. This includes using any of the 350,000+ PyPi packages available in your Python powered workflows.
Pipedream Utils
Pipedream Utils
Utility functions to use within your Pipedream workflows
Notion
Notion
Notion is a new tool that blends your everyday work apps into one. It's the all-in-one workspace for you and your team.
OpenAI (ChatGPT)
OpenAI (ChatGPT)
OpenAI is an AI research and deployment company with the mission to ensure that artificial general intelligence benefits all of humanity. They are the makers of popular models like ChatGPT, DALL-E, and Whisper.
Anthropic (Claude)
Anthropic (Claude)
AI research and products that put safety at the frontier. Introducing Claude, a next-generation AI assistant for your tasks, no matter the scale.
Google Sheets
Google Sheets
Use Google Sheets to create and edit online spreadsheets. Get insights together with secure sharing in real-time and from any device.
Telegram
Telegram
Telegram, is a cloud-based, cross-platform, encrypted instant messaging (IM) service.
Google Drive
Google Drive
Google Drive is a file storage and synchronization service which allows you to create and share your work online, and access your documents from anywhere.
Pinterest
Pinterest
Pinterest is a visual discovery engine for finding ideas like recipes, home and style inspiration, and more.
Google Calendar
Google Calendar
With Google Calendar, you can quickly schedule meetings and events and get reminders about upcoming activities, so you always know what’s next.
Shopify
Shopify
Shopify is a complete commerce platform that lets anyone start, manage, and grow a business. You can use Shopify to build an online store, manage sales, market to customers, and accept payments in digital and physical locations.
Supabase
Supabase
Supabase is an open source Firebase alternative.
MySQL
MySQL
MySQL is an open-source relational database management system.
PostgreSQL
PostgreSQL
PostgreSQL is a free and open-source relational database management system emphasizing extensibility and SQL compliance.
Premium
AWS
AWS
Amazon Web Services (AWS) offers reliable, scalable, and inexpensive cloud computing services.
Premium
Twilio SendGrid
Twilio SendGrid
Send marketing and transactional email through the Twilio SendGrid platform with the Email API, proprietary mail transfer agent, and infrastructure for scalable delivery.
Amazon SES
Amazon SES
Amazon SES is a cloud-based email service provider that can integrate into any application for high volume email automation
Premium
Klaviyo
Klaviyo
Email Marketing and SMS Marketing Platform
Premium
Zendesk
Zendesk
Zendesk is award-winning customer service software trusted by 200K+ customers. Make customers happy via text, mobile, phone, email, live chat, social media.
Premium
ServiceNow
ServiceNow
The smarter way to workflow
Slack
Slack
Slack is a channel-based messaging platform. With Slack, people can work together more effectively, connect all their software tools and services, and find the information they need to do their best work — all within a secure, enterprise-grade environment.
Microsoft Teams
Microsoft Teams
Microsoft Teams has communities, events, chats, channels, meetings, storage, tasks, and calendars in one place.