---
title: "Create a Webhook"
method: POST
path: "/v1/environment/webhooks"
tags: ["webhooks"]
---

# Create a Webhook

`POST /v1/environment/webhooks`

Create a webhook for specific events in the environment.

## Request body

- CreateWebhookRequestBody — A create webhook request body
  - `event` 'batch' | 'carrier_connected' | 'order_source_refresh_complete' | 'rate' | 'report_complete' | 'sales_orders_imported' | 'track', required — The possible webhook event values
  - `url` string, url, required — A URL
  - `headers` WebhookHeader[] — Array of custom webhook headers
    - `key` string, required — Key/name of a header
    - `value` string, required — Value of a header
  - `name` string — The name of the webhook
  - `store_id` integer — Store ID

## Response `200`

The request was a success.

- CreateWebhookResponseBody — A webhook
  - `webhook_id` string — A string that uniquely identifies a ShipEngine resource, such as a carrier, label, shipment, etc.
  - `url` string, url — A URL
  - `event` 'batch' | 'carrier_connected' | 'order_source_refresh_complete' | 'rate' | 'report_complete' | 'sales_orders_imported' | 'track' — The possible webhook event values
  - `headers` WebhookHeader[] — Array of custom webhook headers
    - `key` string, required — Key/name of a header
    - `value` string, required — Value of a header
  - `name` string — The name of the webhook
  - `store_id` integer — Store ID

## Other responses

- `400` — The request contained errors.
- `409` — The request conflicts with an existing resource.
- `500` — An error occurred on ShipEngine's side. > This error will automatically be reported to our engineers.

---

[API](https://skmtc.net/shipengine/apis/shipengine-api.md) · [All operations](https://skmtc.net/shipengine/apis/shipengine-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/shipengine/shipengine-api/revisions/6af91511d87e/schema)
