In today’s world, almost every existing application is a real-time app. From chat apps, online games, ride-hailing apps, to collaboration tools, users expect to see instant updates as other users interact with the application. This goes to show that application state synchronization is important in building modern and interactive applications.
Twilio Sync offers a state synchronization API for managing synchronized application states at scale across multiple devices and users.
In this post you will learn how to add real-time functionality to a Node.js application using Sync. You will be building a sports survey application that shows the results of the survey in real time.
To build the case study project for this post you need to have the following development tools installed on your system:
In my last tutorial, I showed you how to add chat to a Laravel app using Twilio Chat. In this tutorial, I’ll be showing you how to enhance the app by adding media support to it using Twilio Programmable Chat. That is, allowing users to send media files as message.
In order to follow this tutorial, you will need the following:
- Composer installed on your local machine
- Basic knowledge of the Laravel Framework
- Basic knowledge of Vue.js
- A Twilio account
Getting Twilio Credentials
Login to your Twilio dashboard and copy both your ACCOUNT SID and AUTH TOKEN.
Before you can start using the Twilio Programmable Chat, you need to first create a chat service:
Take note of your SERVICE SID.
Lastly, you need to create an API key:
Also, take note of both your API SECRET and API SID.
To make …
The Web Speech API has two functions, speech synthesis, otherwise known as text to speech, and speech recognition, or speech to text. We previously investigated text to speech so let's take a look at how browsers handle recognising and transcribing speech with the
Being able to take voice commands from users means you can create more immersive interfaces and users like using their voice. In 2018, Google reported that 27% of the global online population is using voice search on mobile. With speech recognition in the browser you can enable users to speak to your site across everything from a voice search to creating an interactive bot as part of the application.
Let's see how the API works and what we can build with it.
What you'll need
We're going to build an example app to experience the API, if you want to build along …
The internet has a wide variety of information for human consumption. But this data is often difficult to access programmatically if it doesn't come in the form of a dedicated REST API. With Node.js tools like Cheerio, you can scrape and parse this data directly from web pages to use for your projects and applications.
Let's use the example of scraping MIDI data to train a neural network that can generate classic Nintendo-sounding music. In order to do this, we'll need a set of music from old Nintendo games. Using Cheerio we can scrape this data from the Video Game Music Archive.
Getting started and setting up dependencies
Before moving on, you will need to make sure you have an up to date version of Node.js and npm installed.
Navigate to the directory where you want this code to live and run the following command …
AWS Lambda is a serverless computing platform that enables you to run programs in response to events without having to configure and administer servers. The code that runs on AWS Lambda in response to an event is called a Lambda function.
With AWS Lambda Layers you can separate your function code from its dependencies so you won't have to upload them on every change of your code. A Lambda Layer is a ZIP archive that contains libraries, a custom runtime, or other dependencies. With Layers, you can use libraries without needing to include them in your deployment package. You can share layers across multiple Lambda functions, and moving runtime dependencies into layers can drastically reduce the size of your deployment package.
The Twilio Node Helper Library lets you write Node.js code to make HTTP requests to the Twilio API. Including the Twilio Node Helper Library in the code you deploy …
Over time, digital media outreach mediums have expanded from email and SMS to social media. It is estimated that the average user spends at least 2 hours and 22 minutes on social media and messaging platforms per day. In a world where almost everyone is connected, companies have jumped on this opportunity and used it to promote and campaign for their products and services. But what’s the point of sending promotional content if there is no way to track it? The Twilio API for WhatsApp recently added the read receipts feature where one can effectively measure if the recipient consumes the content sent to them. In this tutorial, I’m going to take you through on how you can obtain the status of a WhatsApp message sent via the Twilio API for WhatsApp.
To complete this tutorial you will need the following:
Businesses can better serve customers by determining how a phone call is going in real-time either with a machine learning model and platform, like TensorFlow, or with an API. This post will show how to perform entity sentiment analysis in real-time on a phone call using Twilio Programmable Voice, Media Streams, and the Google Cloud Speech and Language APIs with Node.js.
- A Twilio account - sign up for a free one here
- A Twilio phone number with Voice capabilities - configure one here
- Node.js installed - download it here
- A Google Cloud account with a valid billing method
Document-Level versus Entity-Level Analysis
Entities are phrases in an utterance or text that are commonly-known such as people, organizations, artwork, organizations, or locations. They're used in Natural Language Processing (NLP) to extract relevant information. This post will perform both document-level sentiment analysis where every word detected is …
QR codes have been referred to as “robot barf.” Which is too bad, because they’re pretty fascinating if you take a closer look.
In this post, you’ll learn about:
- History and inner workings of QR codes
- Use cases and risks
- How to generate QR codes in your application
- How QR codes are used for two-factor authentication
QR codes 101
QR code is an abbreviation for Quick Response code. They’re a type of two-dimensional, or “matrix” barcode which means that information is stored across both the horizontal and vertical axes.
QR codes were invented in Japan during 1994. They were originally used for tracking automobile parts. QR codes could store more data than UPC barcodes (the kind you commonly see on grocery store products and such), so they started to catch on in other industries as well. Denso Wave, the company that invented QR codes, made the spec …
Understanding the case study project
In this post you will see how …
With this new release, we introduce features to uplevel the quality of your Video applications which include, Track Priority and Network Bandwidth Profile API, Region selection, and Reconnection State & Events.
Programmable Video JS SDK 2.0 gives you the building blocks and tools needed to build web based multi-party Video Chat applications. The SDK hides the inherent complexities of Voice, Video, and data communications, which comprise signalling, media exchange, and network traversal to let you focus on providing the user experience your customers will love.
Just like the 1.x version, Programmable Video JS SDK 2.0 is based on WebRTC and is supported on the most popular desktop and mobile browsers including Chrome, Firefox, Safari, and Chrome Edge. Video JS SDK 2.0 supports the same features in 1.x including Dominant Speaker detection, Network quality …