The REST Admin API is a legacy API as of October 1, 2024. All apps and integrations should be built with the GraphQL Admin API. For details and migration steps, visit our migration guide.

Requires access to protected customer data.

Events are generated by some Shopify resources when certain actions are completed, such as the creation of an article, the fulfillment of an order, or the addition of a product. By requesting events, your app can know when certain actions have occurred in the shop.

Note

The events returned by the Event resource should not be considered to be realtime. Events might not be created until a few seconds after the action occurs. In rare cases it can take up to a few minutes for some events to appear.

Resources that can create events

Events are generated by the following resources:

Article events

VerbMessageDescription
createNew article created: article_urlThe article was created.
destroyarticle_url was destroyed.The article was deleted.
publishedarticle_url was published.The article was published.
unpublishedarticle_url was unpublished.The article was unpublished.
updatearticle_url was updated (but its published state was not changed).The article was updated.

Blog events

VerbMessageDescription
createNew blog created: new_blog_urlThe blog was created.
destroyblog_name was destroyed.The blog was deleted.
updateblog_name was updated.The blog was updated.

Collection events

VerbMessageDescription
createNew collection created: collection_urlThe collection was created.
destroycollection_url was destroyed.The collection was deleted.
publishedcollection_url was published.The collection was published.
unpublishedcollection_url was hidden.The collection was hidden.
updatecollection_url was updated.The collection was updated.

Comment events

VerbMessageDescription
createNew comment for article_url: comment_excerptThe comment was created.

Order events

Order events can be divided into the following categories:

  • Authorization: Includes whether the authorization succeeded, failed, or is pending.
  • Capture: Includes whether the capture succeeded, failed, or is pending.
  • Email: Includes confirmation or cancellation of the order, as well as shipping.
  • Fulfillment: Includes whether the fulfillment succeeded, failed, or is pending. Also includes cancellation, restocking, and fulfillment updates.
  • Order: Includess the placement, confirmation, closing, re-opening, and cancellation of the order.
  • Refund: Includes whether the refund succeeded, failed, or is pending.
  • Sale: Includes whether the sale succeeded, failed, or is pending.
  • Void: Includes whether the void succeeded, failed, or is pending.
VerbMessageDescription
authorization_failureThe customer, unsuccessfully, tried to authorize: money_amountAuthorization failed. The funds cannot be captured.
authorization_pendingAuthorization for money_amount is pending.Authorization failed. The funds cannot be captured.
authorization_successThe customer successfully authorized us to capture: money_amountAuthorization was successful and the funds are available for capture.
cancelledOrder was cancelled by shop_staff_name. The order was cancelled.
capture_failureWe failed to capture: money_amountThe capture failed. The funds cannot be transferred to the shop.
capture_pendingCapture for money_amount is pending.The capture is in process. The funds are not yet available to the shop.
capture_successWe successfully captured: money_amountThe capture was successful and the funds are now available to the shop.
closedOrder was closed.The order was closed.
confirmedReceived a new order: order_number by customer_name.The order was confirmed.
fulfillment_cancelledWe cancelled number_of_line_items from being fulfilled by the third party fulfillment service.Fulfillment for one or more of the line_items failed.
fulfillment_pendingWe submitted number_of_line_items to the third party service.One or more of the line_items has been assigned to a third party service for fulfillment.
fulfillment_successWe successfully fulfilled line_items.Fulfillment was successful for one or more line_items.
mail_sentmessage_type email was sent to the customer.An email was sent to the customer.
placedOrder was placed.An order was placed by the customer.
re_openedOrder was re-opened.The order was re-opened.
refund_failureWe failed to refund money_amount.The refund failed. The funds are still with the shop.
refund_pendingRefund of money_amount is still pending.THe refund is in process. The funds are still with shop.
refund_successWe successfully refunded money_amount.The refund was successful. The funds have been transferred to the customer.
restock_line_itemsWe restocked number_of_line_items.One or more of the order's line items have been restocked.
sale_failureThe customer failed to pay money_amount.The sale failed. The funds are not available to the shop.
sale_pendingThe money_amount is pending.The sale is in process. The funds are not yet available to the shop.
sale_successWe successfully captured money_amount.The sale was successful. The funds are now with the shop.
updateorder_number was updated.The order was updated.
void_failureWe failed to void the authorization.Voiding the authorization failed. The authorization is still valid.
void_pendingAuthorization void is pending.Voiding the authorization is in process. The authorization is still valid.
void_successWe successfully voided the authorization.Voiding the authorization was successful. The authorization is no longer valid.

Page events

VerbMessageDescription
createNew page created: page_urlThe page was created.
destroypage_url was destroyed.The page was deleted.
publishedpage_url was published.The page was published.
unpublishedpage_url was hidden.The page was hidden.
updatepage_url was updated.The page was updated.

Price rule events

VerbMessageDescription
createNew price rule created: price_ruleThe price rule was created.
destroyprice_rule was destroyed.The price rule was deleted.
updateprice_rule was updated.The price rule was updated.

Product events

VerbMessageDescription
createNew product created: product_titleThe product was created.
destroyproduct_name was destroyed.The product was deleted.
publishedproduct_title was published.The product was published.
unpublishedproduct_title was hidden.The product was hidden.
Was this section helpful?

Properties

arguments
Refers to a certain event and its resources.

A text field containing information about the event.

created_at
The date and time (ISO 8601 format) when the event was created.

id
->id
The ID of the event.

description
deprecated
A human readable description of the event.

A relative URL to the resource the event is for, if applicable.

message
A human readable description of the event. Can contain some HTML formatting.

subject_id
The ID of the resource that generated the event.

subject_type

The type of the resource that generated the event. Valid values:


verb
The type of event that occurred. Different resources generate different types of event. See the Resources section for a list of possible verbs.

Was this section helpful?
{}The Event resource
{
  "arguments": [
    "IPod Nano - 8GB"
  ],
  "body": null,
  "created_at": "2015-04-20T08:33:57-11:00",
  "id": 164748010,
  "description": "Received a new order",
  "path": "/admin/orders/406514653/transactions/#1145",
  "message": "Received new order",
  "subject_id": 406514653,
  "subject_type": "Order",
  "verb": "confirmed"
}

Retrieves a list of events. Note: This endpoint implements pagination by using links that are provided in the response header. To learn more, refer to Make paginated requests to the REST Admin API.

api_version
string
required

created_at_max
Show events created at or before this date and time. (format: 2014-04-25T16:15:47-04:00)

created_at_min
Show events created at or after this date and time. (format: 2014-04-25T16:15:47-04:00)

fields
Show only certain fields, specified by a comma-separated list of field names.

filter
Show events of certain resources, specified by a comma-separated list of resource names.

limit
≤ 250
default 50
The number of results to show.

since_id
Show only results after the specified ID.

verb
Show events of a certain type.

Was this section helpful?
Was this section helpful?
get
/admin/api/2024-10/events.json
Copy
curl -X GET "https://your-development-store.myshopify.com/admin/api/2024-10/events.json" \
-H "X-Shopify-Access-Token: {access_token}"
{}Response
JSON
HTTP/1.1 200 OK
{
  "events": [
    {
      "id": 164748010,
      "subject_id": 450789469,
      "created_at": "2008-01-10T06:00:00-05:00",
      "subject_type": "Order",
      "verb": "confirmed",
      "arguments": [
        "#1001",
        "Bob Norman"
      ],
      "body": null,
      "message": "Received new order <a href=\"https://jsmith.myshopify.com/admin/orders/450789469\">#1001</a> by Bob Norman.",
      "author": "Shopify",
      "description": "Received new order #1001 by Bob Norman.",
      "path": "/admin/orders/450789469"
    },
    {
      "id": 365755215,
      "subject_id": 632910392,
      "created_at": "2008-01-10T07:00:00-05:00",
      "subject_type": "Product",
      "verb": "create",
      "arguments": [
        "IPod Nano - 8GB"
      ],
      "body": null,
      "message": "Product was created: <a href=\"https://admin.myshopify.io/store/jsmith/admin/products/632910392\">IPod Nano - 8GB</a>.",
      "author": "Shopify",
      "description": "Product was created: IPod Nano - 8GB.",
      "path": "/admin/products/632910392"
    },
    {
      "id": 677313116,
      "subject_id": 921728736,
      "created_at": "2008-01-10T08:00:00-05:00",
      "subject_type": "Product",
      "verb": "create",
      "arguments": [
        "IPod Touch 8GB"
      ],
      "body": null,
      "message": "Product was created: <a href=\"https://admin.myshopify.io/store/jsmith/admin/products/921728736\">IPod Touch 8GB</a>.",
      "author": "Shopify",
      "description": "Product was created: IPod Touch 8GB.",
      "path": "/admin/products/921728736"
    }
  ]
}

Retrieves a single event by its ID

api_version
string
required

event_id
string
required

fields
Show only certain fields, specified by a comma-separated list of field names.

Was this section helpful?
Path parameters
eventid=677313116
string
required
Was this section helpful?
get
/admin/api/2024-10/events/677313116.json
Copy
curl -X GET "https://your-development-store.myshopify.com/admin/api/2024-10/events/677313116.json" \
-H "X-Shopify-Access-Token: {access_token}"
{}Response
JSON
HTTP/1.1 200 OK
{
  "event": {
    "id": 677313116,
    "subject_id": 921728736,
    "created_at": "2008-01-10T08:00:00-05:00",
    "subject_type": "Product",
    "verb": "create",
    "arguments": [
      "IPod Touch 8GB"
    ],
    "body": null,
    "message": "Product was created: <a href=\"https://admin.myshopify.io/store/jsmith/admin/products/921728736\">IPod Touch 8GB</a>.",
    "author": "Shopify",
    "description": "Product was created: IPod Touch 8GB.",
    "path": "/admin/products/921728736"
  }
}

Retrieves a count of events

api_version
string
required

created_at_max
Count only events created at or before this date and time. (format: 2014-04-25T16:15:47-04:00)

created_at_min
Count only events created at or after this date and time. (format: 2014-04-25T16:15:47-04:00)

Was this section helpful?
Was this section helpful?
get
/admin/api/2024-10/events/count.json
Copy
curl -X GET "https://your-development-store.myshopify.com/admin/api/2024-10/events/count.json" \
-H "X-Shopify-Access-Token: {access_token}"
{}Response
JSON
HTTP/1.1 200 OK
{
  "count": 3
}