twilio-labs / function-templates

Twilio Function templates for different Voice, SMS, Video, Chat, Sync, etc use cases
MIT License
339 stars 317 forks source link
code-exchange javascript sendgrid serverless twilio twilio-api twilio-functions

Twilio Function Templates

A Twilio Labs Project

Twilio Functions are a serverless environment to build and run Twilio applications so you can get to production faster. You provide the Node.js code to perform the task you need and Twilio runs it. You can read more about Twilio Functions and how to use them in the introductory blog post.

Attention

With the release of Node v18, the Node.js ecosystem is migrating over from the old CommonJS (CJS) standard to the newer, ES Modules (ESM) standard. Using ESM modules in CJS code is not possible. You can read about the differences in far more detail in this blog Post.. The following snippets may causes errors.

These templates are also available through twilio-run new inside the twilio-run CLI.

Usage

Each Function lives in its own directory within this repo. The easiest way to use the templates is through the Twilio CLI. Check out our docs for the different ways you can use these templates.

Available Functions

Complete list of available functions

Todo

Please add ideas if you have them.

Contributing

This project welcomes contributions. Please check out our Contributing guide to learn more on how to get started.

License

MIT © Twilio Inc.