# Research a website

> Read the business's website to help write the agent.

Source: https://docs.mycrmsim.com/docs/dbr-campaigns/dbr-research-website

```http
POST https://backend.mysmsgateway.app/api/v1/ext/dbr-campaigns/research-website
```

- Category: myCRMSIM DBR Campaigns / DBR Campaigns
- Auth: Bearer access token
- Scope: `dbr_campaigns.write`

Optional, before Create campaign with a new agent. It reads the site (up to a couple of minutes) and returns a description of the business and suggestions. Pass the returned `session_id` and `research_id` to Create campaign with a new agent so the agent is written with what was found. The research is kept for one hour.

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `workspace_id` | body | number | yes | A workspace of the installer. Example: `7` |
| `url` | body | string | yes | The website, http(s). Example: `https://harbourdental.com.au` |
| `session_id` | body | string | no | Your own id for this campaign draft (letters, numbers, - and _). One is made for you when left out. |

## Request body

```json
{
  "workspace_id": 7,
  "url": "https://harbourdental.com.au"
}
```

## Response 200

OK

```json
{
  "success": true,
  "data": {
    "session_id": "api-6f1d2c3b-…",
    "research_id": "r_8c1f…",
    "message": "Read the website.",
    "slots": {
      "company_description": {
        "value": "Family dental clinic in Sydney offering check-ups, cleaning and whitening."
      }
    },
    "suggestions": {
      "offer": "Free check-up for returning patients"
    },
    "expires_at": "2026-10-28T10:00:00.000Z"
  }
}
```

## Response 400

Bad url

```json
{
  "success": false,
  "message": "url must be an http(s) address"
}
```

## Response 401

Missing or invalid token

```json
{
  "success": false,
  "message": "Invalid or expired access token."
}
```

## Response 403

Missing scope

```json
{
  "success": false,
  "message": "Missing scope(s): dbr_campaigns.write. This integration was granted: …"
}
```

## Response 404

workspace_id does not exist or is not the installer's (same response for both)

```json
{
  "success": false,
  "message": "Workspace not found or not accessible to this token"
}
```

## Response 502

The campaign service could not be reached

```json
{
  "success": false,
  "message": "The campaign service could not be reached. Try again later."
}
```
