Skip to contentSkip to navigationSkip to topbar
Rate this Page:

Examples


(information)

Info

This is a Twilio Labs project

This means this project is 100% open-source. You can find its source code in the Twilio Labs GitHub organization(link takes you to an external page).

We currently don't support the projects through our official support channels. But you are welcome to reach out to us on GitHub for any questions, issues or suggestions or to contribute to this project.

Learn more about Twilio Labs.

There is a lot you can do with the Twilio Serverless Toolkit. Here are some common examples of commands you might want to run.

There are two ways you can use the toolkit. If you are already using the Twilio CLI, you can install it via a plugin. Alternatively, you can use the toolkit as a standalone using twilio-run via npm or another Node.js package manager.

Throughout the docs we'll reference the Twilio CLI commands.


The list command

the-list-command page anchor

The list command allows you to list out:

  • Your services that are associated with your account
  • The environments for a specific service
  • Available builds in a specific service
  • As well as the functions , assets and variables currently deployed in a specific environment of a service

Here is some common taks you might want to do with with the list command.

List existing Serverless services

list-existing-serverless-services page anchor

_10
# List all existing Serverless services in a formatted way:
_10
_10
twilio serverless:list services
_10
_10
# Only list the service SIDs and unique names in a table:
_10
_10
twilio serverless:list services --properties sid,unique_name

Promote a deployment from one environment to another

promote-a-deployment-from-one-environment-to-another page anchor

_10
# Activates the same deployment that is on the "dev" environment to the "stage"
_10
_10
twilio serverless:promote \
_10
--source-environment=dev \
_10
--environment=stage


Rate this Page: