Accessing customers HTML Receipts using api, webhook

Accessing customers HTML Receipts using api, webhook

Spring74
Visitor
2 0 0

I would like to access a customers html receipt link at the time of purchase.

I understand I should be able to by creating an API and using a specific webhook.

Can anyone guide me through this process please.

Reply 1 (1)

Liam
Community Manager
3108 341 879

Hi Spring74,

 

By html receipt link are you referring to the URL of the order status page? If so you'd need to register a webhook that listens for the orders/create event, which will contain data about the order, including the order ID. Then you can use that order_id number and make a GET request to the /admin/api/2024-01/orders/{order_id}.json endpoint to retrieve details about the order, which will contain the order_status_url

 

Liam | Developer Advocate @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog