Inngest Logo

Trigger your first Inngest function

Welcome to the Inngest Tour! Inngest enables you to write Inngest functions, trigger by events. Trigger your first function below and see its output.

1
Trigger a function
How this works:
await inngest.send({
name: "demo/simple.sleep",
data: {},
});

Multi-Step Inngest Function and Streaming

Inngest Functions can be divided into multiple fault-tolerant steps, removing most Serverless timeouts and enabling streaming updates to the UI.

Flow Control: Throttling and more

Inngest functions can be made to run in parallel, or one after the other, or with a delay. You can control how functions are executed by using Inngest's flow control features. Let's look at the Throttling feature in action.

1
What is Throttling?
Throttling is a way to limit the rate at which a function can run. For example, it is useful for preventing a function from hitting a third party API rate limit.
The below function has a throttle property that limits it to 2 runs per 2 seconds:
import { inngest } from "./client";
export const throttledFunction = inngest.createFunction(
{ id: "demo/throttled-function", throttle: { limit: 2, period: "2s" } },
{ event: "demo/throttled.function" },
async ({ step }) => {
// ...
}
);
2
Throttling in action
Click the button below to trigger a function 10 times in a row. You'll see that only 2 will run at a time.

You're all set!

You've now seen the main features of Inngest. Check out the docs to learn more about Inngest and how to use it in your project.

Check out some project examples

Check out the following video tutorials showcasing how to build Next.js projects with Inngest: