post_purchase_survey
How-did-you-hear survey (after an order)
Description
POST-PURCHASE SURVEY, "How did you hear about us?": what buyers SAY brought them, beside what tracking saw. Asked in three places: on Shopify’s Thank you and Order status pages (the "Hermoso survey" app block, placed once in Settings > Checkout > Customize; not on Shopify Starter), on a hosted page (pageUrl) any store links from its own order email or SMS, and through a signed webhook for answers collected anywhere else (WooCommerce, another survey app, a form). Each answer is written to the Shopify order (metafield hermoso.how_did_you_hear, shown on the order page) and to the brand’s contact (field how_did_you_hear, tag survey:<channel>), and sent as survey.answered to the brand’s Slack, Discord or webhook alerts. action get (default): settings, the page and webhook links, the answer count, whether the Shopify block has loaded. set: enabled, question, options [{ label, channel?, freeText? }] (2-20; channel such as instagram, tiktok, google, ai, word_of_mouth, creator, podcast, email, other), thankYou, shuffle, writeToOrder, writeToContact, accent (hex). link: orderId, email, value, currency -> a link signed with the brand’s secret, so the answer is tied to that order. secret: the signing secret for links and the webhook (rotate:true makes a new one; old signatures stop working). record: an answer the user or agent already has (answer = an option id or label, or the buyer’s own words; otherText, orderId, email, value, currency, at). answers: the answers (days or from/to, channel, source, limit). report: answers and revenue per answer, and for each answer what tracking recorded for the same orders, including how many buyers named a channel tracking credited to direct traffic or nothing. sync: retry writing answers onto orders and contacts. Free.
Parameters
| Parameter | Type | Description |
|---|---|---|
action | "get" | "set" | "link" | "secret" | "answers" | "record" | "report" | "sync" | default get |
enabled | boolean | set: true turns the survey on everywhere (Shopify block, hosted page, webhook) |
question | string | set: the question, up to 160 characters |
options | object[] | set: 2-20 answers, replaces the list |
options[].id | string | |
options[].labelrequired | string | |
options[].channel | string | |
options[].freeText | boolean | this answer asks the buyer to type where (one option at most) |
thankYou | string | set: the line shown after answering |
shuffle | boolean | set: shuffle the answers per buyer (default true; a free-text answer stays last) |
writeToOrder | boolean | set: write the answer onto the Shopify order (default true) |
writeToContact | boolean | set: save the answer on the brand’s contact for that email (default true) |
accent | string | null | set: the hosted page’s button colour, hex; null for the default |
rotate | boolean | secret: true makes a new secret |
answer | string | record: an option id or label, or the buyer’s own words |
optionId | string | |
otherText | string | |
orderId | string | link / record: the order (a Shopify gid, or the store’s own order number) |
email | string | link / record: the buyer’s email (stored hashed; used for the contact) |
value | number | link / record: the order total |
currency | string | three letters, e.g. USD |
at | string | record: when it was answered, ISO time |
days | number | answers / report: the last N days (default 30) |
from | string | |
to | string | |
channel | string | answers: only this channel |
source | "shopify" | "hosted" | "webhook" | "agent" | answers: only this door |
limit | number | answers: 1-200, default 50 |
Example call
Every required parameter is shown, filled from the schema where it gives a value and otherwise with a placeholder naming the type. Replace the placeholders with real values. The same call works on the MCP server, the CLI and POST https://app.hermoso.ai/v1/tools/post_purchase_survey.
MCP (tools/call)
{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"post_purchase_survey","arguments":{}}}
CLI
hermoso call post_purchase_survey --json '{}'
Credits
Credits are spent only on two things: running an AI model (image, video, voice, text, planning, post-production) and Ad Spy research. See Credits & costs.
Related tools
hermoso_tag_audiencesAudiences from your website visitorsregister_merchant_developerRegister Hermoso with a Merchant Center accounthermoso_tag_eventsRecent events from the Hermoso taglist_merchant_accountsList Merchant Center accountshermoso_tag_reportWebsite visits, leads and revenue by sourcelist_merchant_productsList Merchant Center productsinstall_hermoso_tagPut the Hermoso tag on the websitehermoso_tagThe brand’s Hermoso tag (website tracking snippet)