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

# Create a Webhook

`POST /v1/environment/webhooks`

Create a webook 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 webook 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

## 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 webook event values
  - `headers` WebhookHeader[] — Array of custom webhook headers
    - `key` string, required — Key/name of a header
    - `value` string, required — Value of a header

## 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.

## Changes

- **2024-07-28** `99050ced80fa` — 13 warning, 21 info
  - removed the request property `name`
  - removed the request property `store_id`
  - removed the optional property `allOf[subschema #1: webhook]/name` from the response with the `200` status
  - removed the optional property `allOf[subschema #1: webhook]/store_id` from the response with the `200` status
  - …30 more

[Change history](https://skmtc.dev/shipengine/apis/shipengine-api/changes/v1/environment/webhooks/post.md)

---

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