Skip to main content

Product · simple — a shop

The case. A fabric shop wants agents to find its articles. The order is completed on its own site.

What the example shows. One read API, one skill with kinds, a live search, and a handover submit that sends the person to the site with their selection. No playbook: choosing is the whole journey.

product-simple.yaml
# Product · simple — a shop whose order is completed on its own site.
# One API, one skill. No playbook: browsing and choosing is the whole journey.
station:
id: maison-indigo
name: Maison Indigo

global:
language: fr
currency: EUR
locale: fr-FR

domain:
domain_type: retail
entity_name: article
entity_name_plural: articles


voice:
tone: friendly
persona: "une conseillère textile qui connaît chaque tissu de l'atelier"
rules:
- "Ne jamais inventer un article ou un prix : tout vient de l'outil."
- "Citer le prix exact, en euros, avec le signe €."

apis:
- name: boutique
openapi_url: https://api.maison-indigo.example.fr/openapi.json
base_url: https://api.maison-indigo.example.fr
operations: # allowlist: nothing else is reachable
- {id: searchProducts, access: read}
auth: {type: none}

profiles:
tous:
when: "true"
grants:
- boutique.searchProducts

skills:
- name: articles
cognitive:
objective: "aider à trouver le tissu ou le vêtement qui correspond au projet"
diagnose: [l'usage, la couleur, le budget]
params:
q: {type: text, set_by: [llm]} # what the person looks for, in their own words
invoke: {method: searchProducts, args: {q: "$params.q"}}
kinds: {article: {}}
present:
fields:
name: {from: name, type: text, role: title}
price: {from: price, type: price, role: billed}
image: {from: image_url, type: image}
page: {from: slug, type: url, role: link, template: "{tenant_url}/article/{value}"}
submit:
- name: commande
mode: handover # the customer finishes on the shop's own site
url: "{tenant_url}/commande?add={items}"
render: {component: carousel}

submit_guard:
confirm: true

What happens​

the person or the agentCoreresult
"a blue wax print for a dress"articles → searchProducts with qa carousel of articles, with prices and images
adds two articlesno guard: they enter the selectiontotal in euros
clicks "Finalise"confirm checkeda link to /commande?add=… on the tenant's site

Key points​

  • invoke: {method: searchProducts} queries the tenant's search on every question: stock is always up to date. Convoy keeps no copy of it; an article is chosen only if the room was shown it.
  • The present fields are typed and have a role: title the name, billed the price. The page field (role: link) gives the link to the article's page on the tenant's site, from its slug. Without a link field, the card has no link.
  • handover executes nothing at the tenant: its site takes the payment.
  • profiles: everything is closed until a profile is granted an operation. Here one profile, tous (when: "true"), is granted boutique.searchProducts: everyone may search (Profiles).