# Hermoso: post_purchase_survey · Hermoso developer docs

> Machine-readable twin of https://hermoso.ai/docs/reference/ads/post_purchase_survey/. Generated from the shipped page. Do not edit by hand.
> Full agent guide: https://hermoso.ai/llms.txt · MCP: https://app.hermoso.ai/mcp

[Docs](https://hermoso.ai/docs/) / [Tool reference](https://hermoso.ai/docs/reference/) / [Ad campaign management](https://hermoso.ai/docs/reference/ads/) / post_purchase_survey

# `post_purchase_survey`

How-did-you-hear survey (after an order)

Area: THE HERMOSO TAG · [Ad campaign management](https://hermoso.ai/docs/reference/ads/). Generated from the running MCP server, like the rest of the [tool reference](https://hermoso.ai/docs/reference/).

## 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[].label` required `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](https://hermoso.ai/docs/credits/).

## Related tools

- [hermoso_tag_audiences](https://hermoso.ai/docs/reference/ads/hermoso_tag_audiences/) Audiences from your website visitors
- [register_merchant_developer](https://hermoso.ai/docs/reference/ads/register_merchant_developer/) Register Hermoso with a Merchant Center account
- [hermoso_tag_events](https://hermoso.ai/docs/reference/ads/hermoso_tag_events/) Recent events from the Hermoso tag
- [list_merchant_accounts](https://hermoso.ai/docs/reference/ads/list_merchant_accounts/) List Merchant Center accounts
- [hermoso_tag_report](https://hermoso.ai/docs/reference/ads/hermoso_tag_report/) Website visits, leads and revenue by source
- [list_merchant_products](https://hermoso.ai/docs/reference/ads/list_merchant_products/) List Merchant Center products
- [install_hermoso_tag](https://hermoso.ai/docs/reference/ads/install_hermoso_tag/) Put the Hermoso tag on the website
- [hermoso_tag](https://hermoso.ai/docs/reference/ads/hermoso_tag/) The brand’s Hermoso tag (website tracking snippet)

[All 759 Ad campaign management tools](https://hermoso.ai/docs/reference/ads/) · [tools.json](https://hermoso.ai/docs/reference/tools.json)
