メニュー

ページを評価:

Twilio Runtime

Traffic to a communications-based application is unpredictable, and properly scaling for spikes is difficult. Runtime is a serverless environment for your Node.js code and static files that handles scaling, hosting, and maintenance for you so that you can focus on your application code instead of stressing about server uptime. Find the documentation, sample code, and developer tools needed to build something amazing.

Deploy your first Function
Twilio manages deployments and scaling of resources so you can focus on your application code instead of server maintenance
1
Twilioサーバー
code-image
Write Functions with built-in access to the Twilio SDK and other Twilio helpers
2
アプリケーション

const axios = require('axios');

exports.handler = async (context, event, callback) => {
  const twiml = new Twilio.twiml.MessagingResponse();
  const response = await axios
    .get('https://dog.ceo/api/breeds/image/random');

  twiml
    .message(`Hello, ${event.From}! Enjoy this doge!`)
    .media(response.data.message);

  return callback(null, twiml);
};
Your code responds to traffic and scales effortlessly
3
Hello, +2134567890! Enjoy this doge!

はじめる

You're just a few clicks away from deploying a Function that can scale to any number of incoming SMS, Calls, and more. No need to deploy or manage your own server. Let's get started!

You can also use the Twilio CLI and Serverless Toolkit to quickly deploy a pre-made app template, or bootstrap your own app from scratch.

If you prefer a GUI, no worries, just visit the Twilio Console to get started!

Build your Serverless Application

Understand the Concepts

Learn how Runtime works to provide scaling, reliability, and flexibility for your app. Building an application in Runtime has some key differences from building on your own server using Express or Flask. Set yourself up for success by learning the key concepts and JavaScript methods that you'll be interacting with on your development journey.

Use these docs to learn about Runtime core concepts, the different steps involved in building in the cloud, and examples of common use cases.

Explore the Serverless Toolkit

The Serverless Toolkit is CLI tooling to help you develop locally and deploy to Twilio Runtime.

If you want to streamline your workflow, bootstrap and deploy apps quickly, easily integrate with your own CI/CD pipeline, and develop from the comfort of your own IDE, then the Serverless toolkit will be the Twilio CLI plugin for you.

ページを評価:

フィードバックくださりありがとうございます!

We are always striving to improve our documentation quality, and your feedback is valuable to us. How could this documentation serve you better?

Sending your feedback...
🎉 Thank you for your feedback!
Something went wrong. Please try again.

Thanks for your feedback!

Refer us and get $10 in 3 simple steps!

ステップ1

Get link

Get a free personal referral link here

ステップ2:

Give $10

Your user signs up and upgrade using link

ステップ3

Get $10

1,250 free SMSes
OR 1,000 free voice mins
OR 12,000 chats
OR more