A sample repository, demonstrating how to use child workflows with Restack AI.
For a full Typescript documentation refer to https://docs.restack.io/libraries/typescript/reference
- Node 20+, pnpm (or other package manager)
pnpm i
pnpm dev
This will start Node.js app with two Restack Services. Your code will be running and syncing with Restack engine to execute workflows or functions.
To start the Restack Studio, you can use Docker.
docker run -d --pull always --name restack -p 5233:5233 -p 6233:6233 -p 7233:7233 ghcr.io/restackio/restack:main
pnpm schedule-workflow
- Create an account on conole.restack.io
- Create an engine to connect to in cloud
- Create an API token in workspace > settings
- Copy all environment variables to your
.env
in local.
RESTACK_ENGINE_ID=
RESTACK_ENGINE_ADDRESS=
RESTACK_ENGINE_API_KEY=
RESTACK_CLOUD_TOKEN=
- Now run the following command at the root of the folder
childworkflows
pnpm restack-up
- You will be prompted to login to restack and create a new API Token for your workspace
- Add the token to your environment
To deploy the application on Restack, you can use the provided restackUp.ts
script. This script utilizes the Restack Cloud SDK to define and deploy your application stack. It sets up the necessary environment variables and configures the application for deployment.
To get started, ensure you have the required Restack Cloud credentials and environment variables set up. Then, run the script to initiate the deployment process.
For more detailed information on deploying your repository to Restack, refer to the Restack Cloud deployment documentation.