# realestateVIEW Agent Profile API Documentation

Scrappa's `GET /api/realestateview/agent` returns the public profile of one realestateVIEW agent. Send the numeric `id`, which is `agents[].id` in search and listing results.

## What you get

`name`, `position`, `description`, `phone`, `mobile`, `email`, `photo_url`, `social`, `stats`, `sales_performance`, `rent_performance` and the `agency`. `stats` holds the average days on market, the average sold and leased price and the number of sold, leased and current listings. Prices are in Australian dollars.

## Hidden contact details

Phone, mobile and email follow what the agent shows publicly. A hidden value is `null`.

## Listings

Use `/api/realestateview/agent-listings` for the listings of the agent.

## Unknown ids

An id that realestateVIEW does not know answers `404` (`not_found`) and is not billed. An id that is not a number answers `422`.

- **Documentation:** [https://scrappa.co/docs/realestateview-api/realestateview_agent](https://scrappa.co/docs/realestateview-api/realestateview_agent)
- **API group:** realestateVIEW API
- **Endpoint:** `GET https://scrappa.co/api/realestateview/agent`

## Authentication

Send your Scrappa API key in the `X-API-KEY` request header. Paid endpoints also support accountless x402 payments when called without an API key.

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | string | Yes | Numeric agent id from search or listing (agents[].id), for example 104933. |

## Example request

```bash
#!/bin/bash

curl -X GET \
    -H "x-api-key: YOUR_API_KEY_HERE" \
    "https://scrappa.co/api/realestateview/agent?id=104933"
```

## Example response

```json
{
    "success": true,
    "agent": {
        "id": 104933,
        "name": "Sample Agent",
        "first_name": "Sample",
        "last_name": "Agent",
        "position": null,
        "phone": "1300 000 000",
        "mobile": "0400 000 000",
        "email": null,
        "photo_url": null,
        "profile_path": "/agent-profile/sample-agent-104933/",
        "agency_id": null,
        "sold_listings": 16,
        "average_sold_price": 569161,
        "description": "Sample Agent sold 16 properties in the last 12 months.",
        "is_primary_contact": false,
        "social": [],
        "stats": {
            "average_days_on_market": 63,
            "average_leased_days_on_market": 0,
            "average_sold_price": 569161,
            "average_leased_price": null,
            "sold_listings": 16,
            "leased_listings": 0,
            "buy_listings": 6,
            "rent_listings": 0
        },
        "sales_performance": [],
        "rent_performance": [],
        "agency": {
            "id": 24798,
            "name": "Sample Realty",
            "slug": "sample-realty",
            "address": "Suite 1, Level 2, 34 Sample Street, Melbourne, VIC 3000",
            "suburb": "Melbourne",
            "postcode": "3000",
            "logo_url": "https://view.com.au/viewstatic/images/listing/300-min/f9a416dc651440608bd7cbc8b2450bae.png",
            "brand_colour": "00202F",
            "profile_path": "/real-estate-agency/sample-realty-24798/"
        }
    },
    "meta": {
        "endpoint_family": "agent_profile",
        "billable": true,
        "attempts": 1
    }
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 404 | Not Found | No agent exists with that id (`not_found`). Non-billable. |
| 422 | Validation Error | A query parameter is missing, unknown or unusable. Unknown parameters are rejected, never ignored (`request_rejected` is the same failure raised by the source). Non-billable. |
| 503 | Source Unavailable | realestateVIEW could not be reached in time, refused the request, or its answer changed shape (`upstream_unavailable`, `request_blocked`, `deadline_exhausted`, `parser_drift`). Retryable and never billed. Clients are never rate limited. |

## More Scrappa resources

- [API documentation](https://scrappa.co/docs)
- [Full LLM-readable API reference](https://scrappa.co/llms-full.txt)
- [OpenAPI specification](https://scrappa.co/docs/api.json)
- [Pricing](https://scrappa.co/pricing)
