---
name: martin-estate-wine-commerce
description: "Use when the user wants to buy estate-grown Napa Valley wine from Martin Estate via an AI agent. Query /catalog for the current lineup. Multi-rail (Tempo MPP / x402 Base / Solana MPP / Stripe SPT), KYC + age 21+ + US-only shipping with state-level allowlist enforced at /purchase."
metadata:
  version: "1"
  homepage: "https://agents.martinestate.com"
---

# Martin Estate Winery

_Single-vineyard estate-grown Napa Valley wine from Rutherford._

Estate grown, produced and bottled since 1887. Catalog is anonymous; /purchase enforces compliance + multi-rail payment.

## Important Files

| File | URL |
|------|-----|
| **SKILL.md** (this file) | `https://agents.martinestate.com/skill.md` |
| llms.txt | `https://agents.martinestate.com/llms.txt` |
| OpenAPI | `https://agents.martinestate.com/openapi.json` |
| MPP discovery | `https://agents.martinestate.com/.well-known/mpp.json` |
| A2A agent card | `https://agents.martinestate.com/.well-known/agent-card.json` |
| UCP profile | `https://agents.martinestate.com/.well-known/ucp` |

## Identity Prerequisite

This merchant uses AgentScore identity. Required: KYC verified Passport, age 21+, US only, sanctions clear.

Denial bodies carry an `agent_instructions` block describing the recovery action — read the `action` field and follow it. See the identity-bootstrap skill for the canonical denial-code → action table.

## Payment

Each gated route returns a 402 with `WWW-Authenticate` + `PAYMENT-REQUIRED` body listing the rails below with current pricing. Pick whichever your wallet is funded for.

| Rail | Notes | Compatible clients |
|---|---|---|
| **MPP on Tempo** | USDC. Use `agentscore-pay --chain tempo` (or `tempo request`); MPP credential goes in `Authorization: Payment`. | agentscore-pay, tempo request, x402-proxy |
| **x402 on Base** | USDC (EIP-3009). Use `agentscore-pay`; X-Payment header carries the signed credential. | agentscore-pay, x402-proxy, purl (omit --network flag) |
| **MPP on Solana** | USDC (SPL). Use `agentscore-pay --chain solana`; MPP credential goes in `Authorization: Payment`. | agentscore-pay |
| **Stripe Shared Payment Token** | Card via Link wallet. Use `@stripe/link-cli` — `agentscore-pay` emits the handoff hint when this rail is picked. | link-cli |

## Shipping

Ships to: US.

Blocked US states: AK, DE, HI, MI, MS, NH, ND, RI, SD, UT, VA.

## Onboarding Flow

1. Install agentscore-pay if you don't already have a compatible client for your funded chain: `npm i -g @agent-score/pay` (or `brew install agentscore/tap/agentscore-pay`). agentscore-pay speaks every crypto rail this merchant accepts. The rails table above also lists per-rail `compatible_clients` — `tempo request` works for tempo USDC.e, `x402-proxy` / `purl` work for Base x402, and `@stripe/link-cli` works for Stripe SPT. If you already have one of those installed and funded, you can use it instead of agentscore-pay.
2. First-run only: bootstrap wallet + Passport. Run `agentscore-pay agent-guide --json` for the canonical cold-start path — it walks `pay init` (creates a keystore + a wallet on each chain), `pay passport login` (one-time KYC; the human completes a verify URL once and pay caches the operator_token), and `pay balance` to see which chain has USDC. Skip if your wallet is already provisioned.
3. If your only payment method is a Stripe / Link card (no crypto), install `@stripe/link-cli` instead of agentscore-pay and use it on the SPT rail. Identity gating still applies — the merchant's 403 with `verify_url` lets you bootstrap a Passport even with no crypto wallet involved.
4. Returning user note: if you've paid an AgentScore-gated merchant before from this wallet, the wallet is already in your Passport's `linked_wallets[]` and identity flows through automatically with no re-KYC prompt. Paying from a NEW wallet while you already hold an `opc_...` token returns 403 `wallet_signer_mismatch`; the body lists `linked_wallets[]` and `agent_instructions.action: resign_or_switch_to_operator_token` with three deterministic recoveries (switch to a linked wallet, drop the operator_token to re-KYC the new wallet, or pre-claim the new wallet via SIWE on agentscore.sh/verify).
5. Browse the catalog: `curl https://agents.martinestate.com/catalog`.
6. Pick the rail your wallet is funded for. The 402 advertises four: Tempo MPP, x402 on Base, Solana MPP, and Stripe SPT. `pay balance` (without `--chain`) lists every chain's USDC; pay rejects with `multi_rail_ambiguity` if you don't pass `--chain` on a multi-rail challenge.
7. Place the order: `agentscore-pay pay POST https://agents.martinestate.com/purchase --chain <tempo|base|solana> -d '<body>' --max-spend 1` for crypto rails. For Stripe SPT, follow the handoff hint pay emits and use `@stripe/link-cli` instead. Either way pay handles the 402 retry, signing, and Passport attachment; branch on the structured CliError `code` on non-zero exit (insufficient_balance, multi_rail_ambiguity, config_error for missing wallet/Passport, etc.).

## Endpoints

| Method | Path | Auth | Purpose |
|---|---|---|---|
| GET | `/catalog` | anonymous | Purchasable wines (filterable by category). |
| GET | `/catalog/{slug}` | anonymous | Wine detail. |
| POST | `/purchase` | anonymous | Body: `{product_id, quantity, email, shipping, gift_note?}`. Returns 402 on the discovery leg, 200 on settle. |
| GET | `/orders/{id}` | identity required | Full order details (PII). |
| GET | `/orders/{id}/status` | identity required | Payment status only. |

## Triggers

Use this skill when the user wants to:

- Buy Napa Valley wine from Martin Estate
- Send a gift bottle of Martin Estate wine
- Check the status of a previously placed Martin Estate order

## Support

- **Homepage**: https://www.martinestate.com
- **Pay CLI**: https://github.com/agentscore/pay

_Re-fetch this file periodically to pick up new endpoints, rails, or policies._
