> ## Documentation index
> Fetch the complete documentation index at: https://upstash.com/docs/llms.txt
> Ask it with GET https://upstash.com/docs/ask?q=<keywords or question>. Short keywords rank best.
> Use these to discover all available pages before exploring further.
> Feature requests: https://upstash.com/docs/common/help/feature-requests.md lists what users asked for and how to vote for a request or add one.
> Page rating: `GET https://upstash.com/docs/feedback?path=/docs/workflow/steps/createWebhook&helpful=true` (or `false`) records whether this page helped. An optional `comment` (URL-encoded, at most 500 characters) says what was missing or wrong. It is anonymous and needs no key. Comments hold no code, secrets or personal data.

# context.createWebhook

`context.createWebhook()` creates a unique webhook that can be called by external services to trigger workflow continuation.

The webhook URL generated can be called multiple times to resume multiple [`context.waitForWebhook`](/workflow/basics/context/waitForWebhook) steps.

## Arguments

<ParamField body="stepName" type="string" required>
    Name of the step.
</ParamField>

## Response

<ResponseField name="webhookUrl" type="string">
    The unique webhook URL that external services should call to resume the workflow.

    Can be called multiple times to resume multiple [`context.waitForWebhook`](/workflow/basics/context/waitForWebhook) steps.
</ResponseField>

<ResponseField name="eventId" type="string">
    The internal event identifier associated with this webhook.
    This is primarily used internally by [`context.waitForWebhook`](/workflow/basics/context/waitForWebhook).
</ResponseField>

## Usage

```typescript highlight={4}
import { serve } from "@upstash/workflow/nextjs";

export const { POST } = serve(async (context) => {
  const webhook = await context.createWebhook("create webhook");

  console.log(webhook.webhookUrl); // Use this URL with external services
});
```

For more complete examples and use cases, see [the page on webhooks](/workflow/features/webhooks).
