Menu · Build with AI
Build with AI

Prompt: agent profile

An agent page with that agent's listings and a contact form that sends to your CRM.

View as Markdownopenapi.json

This prompt builds one agent's listings with a contact form, leaving the agent's photo and bio to you.

The prompt

Prompt
Read RUUSTER_IDX.md first and follow its MUST and NEVER rules. Ask me if it doesn't cover something.

Build an agent page at /agents/[agent] that follows <https://help.ruuster.com/idx/recipe-agent-listings>. Show that agent's listings from GET /v1/listings with agent=<the agent's Ruuster slug>, rendered on the server, and a ContactForm posting to my own lead route. The agent's photo and bio are my own content: leave a clearly marked place for them, and do not invent a bio. If the API answers agent_not_found, the page answers 404.

Use these environment variables: IDX_SECRET_KEY (server only), SITE_ORIGIN and SITE_NAME. Never paste a secret key into a chat, and never put IDX_SECRET_KEY in browser code, a URL or a log. No key goes in any page: my pages call my own /api/idx route, made with createListingsRoute from @ruuster/idx/route, which adds my secret key on the server (on a site with no server, the widgets call the API with no key from my approved website address).

Fair housing: describe homes, places and amenities only. Never describe the people who live in an area or who a home or area suits, and never rank schools as a reason to buy.

When you are done, list the agent slugs you used so I can check them.

What it builds

  • app/agents/[agent]/page.tsx with agent=<slug> and the ContactForm
  • a 404 for an agent slug that is not at your brokerage
  • a marked place for the agent's own photo and bio

How to check it

  1. curl -sI an unknown agent's page and see 404.
  2. Send a test message from a real agent's page and find it in your CRM.
  3. Add the agent's photo and bio yourself.

Before you paste it

Follow the setup on Build it with your AI coding assistant once: RUUSTER_IDX.md at the root of your project, the two lines in CLAUDE.md or AGENTS.md, and your keys in .env.local. Never paste a secret key into a chat. Replace the text in square brackets with your own before you send the prompt.