> For the complete documentation index, see [llms.txt](https://docs.imerit.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.imerit.net/sdk/sdk-documentation/project-level-sdk-functions/rerun_webhook.md).

# rerun\_webhook

`imerit_ango.sdk.SDK.`

## rerun\_webhook(project\_id, webhook\_stage\_id)

Re-run a webhook stage in your project.

### Parameters

* **project\_id:** string
  * The unique identifier for the project. You can find the project ID in [the user interface](/sdk/sdk-documentation.md#project-ids) or retrieve it using the [`list_projects`](/sdk/sdk-documentation/project-level-sdk-functions/list_projects.md) function.
* **webhook\_stage\_id:** string
  * The unique identifier for the webhook stage to re-run.
  * You can retrieve webhook stage IDs by calling the [`get_project`](/sdk/sdk-documentation/project-level-sdk-functions/get_project.md) function

Returns:

* **output:** dict
  * A dictionary containing the result of the operation.
  * Including a `status` field indicating whether the request was successful and a `data` field containing the response payload with updated resources produced by the operation.

<details open>

<summary><strong>How to verify in Ango Hub?</strong></summary>

After successfully executing the `rerun_webhook` function, you can validate the changes directly in Ango Hub.

Navigate to: **Projects → \[Your Project] → Workflow**

* Click on the webhook stage.
* Open the **Logs** section.
* Confirm that the webhook has been triggered and is operating as expected.

{% hint style="info" %}
Changes made via the SDK are reflected in Ango Hub in near real-time. If updates are not immediately visible, please refresh the page.
{% endhint %}

</details>

### Example:

{% tabs %}
{% tab title="python" %}

```python
import os
from dotenv import load_dotenv
from imerit_ango.sdk import SDK

load_dotenv('variables.env')
api_key = os.getenv('API_KEY')
project_id = os.getenv('PROJECT_ID')

stage_id = "YOUR_WEBHOOK_STAGE_ID"

ango_sdk = SDK(api_key)
sdk_response = ango_sdk.rerun_webhook(project_id=project_id, webhook_stage_id=stage_id)
```

{% endtab %}

{% tab title="curl" %}

```bash
curl -X POST "https://imeritapi.ango.ai/v2/project/$PROJECT_ID/rerun-webhook" \
  -H "Content-Type: application/json" \
  -H "apikey: $ANGO_API_KEY" \
  -d '{
    "stageId": "YOUR_WEBHOOK_STAGE_ID"
  }'

```

{% endtab %}
{% endtabs %}

{% hint style="info" %}
**See also**

[get\_project](/sdk/sdk-documentation/project-level-sdk-functions/get_project.md), [update\_workflow\_stages](/sdk/sdk-documentation/project-level-sdk-functions/update_workflow_stages.md)
{% endhint %}
