---
name: agency
description: "Set up the Market Research Agency company template on naïve for the person you work for: ask its setup questions, install it with the naive CLI or the API, then hand them the approvals."
url: https://usenaive.ai/companies/market-research-agency
blueprint: clients-research
template: agency
---

# Market Research Agency on naïve

A person asked you, their coding agent, to set up the Market Research Agency company for them on naïve. Follow this file top to bottom. Market sizing, competitor teardowns and voice-of-customer reports for each client, every figure sourced. You approve every report before it leaves.

- Page: https://usenaive.ai/companies/market-research-agency
- Listing (the source of truth, no key needed): `GET https://api.vetta.sh/v1/blueprints/artifacts/clients-research/agency`, release 1.4.0. Where it and this file disagree, the listing wins.

## What this template runs

| Part | Name | What it does |
| --- | --- | --- |
| Agent | `Sales` (required) | New business. Finds leads, writes to them, follows up and books the first call. Every email waits for your yes. |
| Agent | `Client manager` (required) | Accounts. Runs each client: the kickoff, the calls, the weekly update and the renewal. |
| Agent | `Desk researcher` (required) | Market sizing. Frames each client's question and sizes the market from public sources, method shown. |
| Agent | `Competitor analyst` (required) | Competitors. Tears down each client's competitors: pricing, positioning, product, funding and stack, in one table. |
| Agent | `Voice-of-customer analyst` (required) | Customer insight. Reads what buyers say about each client and its competitors, and counts the themes. |
| Agent | `Marketing` (required) | Content. Writes the posts and case studies that bring in leads, each one saved for you to approve. |
| Mini app | `crm` | CRM |
| Mini app | `calendar` | Calendar |
| Mini app | `ads` | Ads |
| Mini app | `seo-geo` | SEO & GEO |
| Persona | `Agency` | The agency itself: who clients and leads hear from. |

| Timer | When | Does | Cap per run |
| --- | --- | --- | --- |
| `Sales` | `30 8 * * 1-5` (every weekday at 08:30) | Morning pipeline pass | $2.00 |
| `Client manager` | `0 9 * * 1` (every Monday at 09:00) | Monday week ahead | $2.00 |

- Team: 6 agents
- Reports: 3 kinds
- Every figure: Sourced
- Reports leave: Only after you approve

## Cost

- From $20/mo per company, includes 100,000 credits. The person pays the plan in a browser. You never enter payment details, subscribe, top up or upgrade for them.
- Each timer run is capped at the amount in the table above. A run that would pass its cap stops instead of spending.

## Prerequisites

1. A naïve account. If the person has none, send them to https://app.usenaive.ai/register?blueprint=clients-research&template=agency to sign up, and wait until they say it is done. That page also offers to set this template up in the browser: they can stop once the account exists.
2. A plan, which the person picks and pays in the studio (https://app.usenaive.ai/subscribe), never you. A new company can install first: its install is held until they activate it (see After install).
3. An API key with these six scopes: `agents:read` `agents:write` `sessions:read` `files:read` `files:write` `billing:read`. Why six: the crew needs `agents:read` and `agents:write`. The template's apps get their own key, made from this one, and it needs `sessions:read` `files:read` `files:write` `billing:read`. A key can't give scopes it doesn't have, so without those four the apps and docs are refused.
   The person makes the key in the studio: Settings → API keys → New key (https://app.usenaive.ai/settings), ticking the six scopes. It is shown once. (`naive keys create --name agent --scopes agents:read,agents:write,sessions:read,files:read,files:write,billing:read` also makes one, but only from a CLI signed in with the person's own login, `naive auth login --email`, so normally the person uses the studio.) Have them save it to a file or set `NAIVE_API_KEY` themselves. Never echo, log or commit it.

## First: is it already installed?

Check this before you ask the setup questions. The person may have set it up in the browser already.

```bash
npm i -g @usenaive-sdk/cli
naive --version                         # below 1.1.0 has no `naive install`: use Path B
export NAIVE_API_KEY="$(cat key.txt)"   # a file holding only the key (or the person sets it); it overrides any stored login
naive whoami                            # the organization this key belongs to
naive installs --project market-research-agency
```

Without the CLI: `curl -sS "https://api.vetta.sh/v1/blueprints/installs?project=market-research-agency" -H "Authorization: Bearer $NAIVE_API_KEY"` (SDK: `client.apps.installs.list({ project: "market-research-agency" })`). If it lists a row, the template is installed: skip to After install. If not, go on.

## Setup questions

| key | label | required | type / options | help | example |
| --- | --- | --- | --- | --- | --- |
| `about` | What does your agency do, and for whom? | yes | text | Your team writes to clients and leads from this. |  |
| `offer` | What do you sell, and for about how much? | yes | text |  | Market sizing and competitor teardowns, $5,000 a report |
| `coverage` | Which markets do you cover, and what decisions do clients make with your research? | yes | text | Your team frames every client's question from this. | US consumer hardware; clients decide whether to enter a market and how to price. |

Ask these after checking it isn't already installed (above). Ask the person for every required answer you do not already know, in one message. Never invent an answer. If an answer doesn't cover what the question's help asks for, ask once more; if they still don't have it, use what they gave and tell them they can change it later (After install). Offer the optional ones once and leave them out if they have none. A list answer repeats its key.

## Path A: the naive CLI

```bash
naive install clients-research agency --project market-research-agency --answer 'about=<answer>' --answer 'offer=<answer>' --answer 'coverage=<answer>' --dry-run
naive install clients-research agency --project market-research-agency --answer 'about=<answer>' --answer 'offer=<answer>' --answer 'coverage=<answer>' --new
naive installs --project market-research-agency
```

1. The dry run writes nothing. It lists the named agents, apps and identity (persona) the install would create. The real run also arms the template's schedules and writes its docs and starter board tasks, and adds a CEO (who owns the board) if the company doesn't have one yet; the preview doesn't show those. Tell the person all of that, and get a yes before the real run, which starts agents that spend credits.
2. `--new` refuses a project that already exists instead of changing it. Add `--new` to the dry run too and it tells you before the real run. Then read the result (below).
- Each answer is `--answer 'key=value'`; a list answer repeats the flag. Leave out an optional question the person has no answer for.
- Advanced: `VETTA_API_BASE_URL` overrides the API host (default https://api.vetta.sh).

## Path B: the SDK or HTTP

```ts
import { createClient } from "@usenaive-sdk/managed-agents";
const client = createClient({ apiKey: process.env.NAIVE_API_KEY! });
await client.apps.installs.preview({ blueprint: "clients-research", template: "agency", project: "market-research-agency" }); // the dry run: writes nothing, see Path A note 1
const install = await client.apps.installs.apply({ project: "market-research-agency", blueprint: "clients-research", template: "agency", answers: { "about": "<answer>", "offer": "<answer>", "coverage": "<answer>" }, expected_revision: 0 });
```

```bash
curl -sS -X POST https://api.vetta.sh/v1/blueprints/installs \
  -H "Authorization: Bearer $NAIVE_API_KEY" -H "Content-Type: application/json" -H "Idempotency-Key: $(uuidgen)" \
  -d '{"project":"market-research-agency","blueprint":"clients-research","template":"agency","answers":{"about":"<answer>","offer":"<answer>","coverage":"<answer>"},"expected_revision":0}'
```

As in Path A: check it isn't installed (above) before the questions, and tell the person what the preview leaves out (the CEO, starter board tasks, schedules, docs) before the apply. An error comes back as `error.code` and its message.

## Reading the result

- `status`: `applied` (created; read `failure` and the exit code, a partial apply is still `applied`), `pending` (still finishing on the server: watch `naive installs --project market-research-agency`), `held` (waits for the person, see After install), `failed` (`failure` says why).
- Exit 0: everything was created.
- Exit 1: an API refusal, or a partial apply. An `applied` row with refusals (`failure`, or `report` lines with `action: "refused"`) means the company exists but the refused parts don't. Read `next` and `report`, tell the person exactly what was refused, and don't retry blindly. A refusal about missing scopes means a new key with the six scopes (Prerequisite 3). A refusal that names something the platform must set up (such as "not configured") means the person contacts support: they can't fix it themselves.
- Exit 2: a usage problem, such as a missing or unknown answer. Ask the person, then retry.
- `next` appears on the install's own response only, not later in `naive installs`, so save it.

## After install

- An install with `status: "held"` is not a failure: the company is still being set up, and its team starts once the person activates it in the studio. The checkout is theirs. Tell them, and do not retry.
- The studio (https://app.usenaive.ai) opens on the CEO's chat. That is where the person talks to the company.
- Nothing goes out on its own: each post or send waits in the studio until the person allows it.
- The person connects the accounts it posts from to the `Agency` persona in the studio (Identities).
- To change an answer: `client.apps.installs.update(install.id, { answers })` (`PATCH /v1/blueprints/installs/{id}`) with the whole map, every answer kept. With the CLI: `naive installs context --project market-research-agency` prints the answers, and `naive installs context --project market-research-agency --set key=value` changes one (no clone needed).

## Rules

- Never post, publish or approve anything for the person. Approvals are theirs.
- Never pay, subscribe, top up or upgrade. Show any checkout link verbatim and stop.
- Never build it around a real person, a brand, or work the person holds no rights to.
- Every figure names its source: A report lists where each number came from. A figure the team cannot source does not appear as fact. An estimate is labelled as one, with the steps that produced it.
- On any refusal (exit 1, or an `error` from the API), stop. Tell the person exactly what was refused (`error.code` and message, or the `next` and `report` lines) and ask before you try anything else. Only a usage problem (exit 2) is retried, once the person has answered.
