How to add TimeLine Comment to Customers using REST APIs?

Shopify Partner
9 0 3

I am looking to add comments using REST API on customer object, and I am able to add these comments from front-end easily requests are hitting with message and other variables but when I read the documentation it tells that mutation timelineCommentCreate doesn't exist on the 'Mutation' type.


How can we achieve this?

Replies 3 (3)
Shopify Staff
Shopify Staff
1882 202 577

Hi Abdul_Qayyum,


The timelineCommentCreate mutation is not available in Shopify's public API. If you want to store extra data about a customer, one workaround could be to use Metafields. You can create a new metafield for a customer and store your comment there. You can use the metafieldCreate mutation in the GraphQL API, or you can use the /admin/api/#{api_version}/customers/#{customer_id}/metafields.json endpoint in the REST API to do this.


Hope this helps,

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 or the Shopify Web Design and Development Blog

Shopify Partner
9 0 3

Is there any way i can create the activity using REST API?
I just want to create a timeline activity programmatically in Shopify using REST API or something else if Comment APIs are not available!




Shopify Partner
233 6 53

same here, is it on the backlog to add this to the api rest or graphql? would be great if we can add events to the timeline for specific orders through the api


Software Developer | Owner of Tom IT - We build shopify apps
Marketplace Order Connector | Amazon & Walmart DSV
Order Related Documents | Print documents, Email document &Autoprint
Blog Product Spotlight | Add products to your blog articles!