# DDproperty Agent API Documentation

<p><strong>DDproperty Agent API</strong> returns the public profile of one agent: name, job title, agency name and logo, photo, profile text, services, public links, listing counts for sale and rent, the areas the agent works in, and the listing ids with map coordinates. Send the agent <code>id</code> from a listing, or the agent profile <code>url</code>. Phone numbers and messaging ids are not returned. An unknown agent answers not found. Not found and other failures are not billed.</p>

- **Documentation:** [https://scrappa.co/docs/ddproperty-api/ddproperty_agent](https://scrappa.co/docs/ddproperty-api/ddproperty_agent)
- **API group:** DDproperty API
- **Endpoint:** `GET https://scrappa.co/api/ddproperty/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 | No | Agent id from a listing. |
| `url` | string | No | Agent profile url (instead of id). |

## Example response

```json
{
    "data": {
        "id": 10635723,
        "url": "https://www.ddproperty.com/en/agent/ma-yuan-tao-10635723",
        "name": "Ma Yuan Tao",
        "links": {
            "website": "https://lin.ee/EqlrFPJ",
            "facebook": "https://www.facebook.com/yx.property.2024"
        },
        "photo": "https://th1-cdn.pgimgs.com/agent/10635723/APHO.132926932.R550X550.jpg",
        "agency": {
            "logo": "https://th1-cdn.pgimgs.com/agency/43020/CLOGO.82873223.R550X550.jpg",
            "name": "YX PROPERTY"
        },
        "listings": {
            "rent": [
                {
                    "id": 500609630,
                    "latitude": 13.73361,
                    "longitude": 100.587195,
                    "region_code": "TH10"
                },
                {
                    "id": 11255277,
                    "latitude": 13.73361,
                    "longitude": 100.587195,
                    "region_code": "TH10"
                }
            ],
            "sale": [
                {
                    "id": 500639902,
                    "latitude": 13.74782,
                    "longitude": 100.549062,
                    "region_code": "TH10"
                },
                {
                    "id": 500052796,
                    "latitude": 13.75939,
                    "longitude": 100.541384,
                    "region_code": "TH10"
                }
            ]
        },
        "services": [
            "Apartment Rental",
            "Apartment Sales",
            "Commercial Property",
            "Landed House Rental",
            "Landed House Sales",
            "Mortgage Advisory",
            "Official Valuations",
            "Relocation Services"
        ],
        "job_title": "\u0e1c\u0e39\u0e49\u0e08\u0e31\u0e14\u0e01\u0e32\u0e23\u0e1a\u0e31\u0e0d\u0e0a\u0e35",
        "locations": [
            {
                "code": "TH10",
                "name": "Bangkok",
                "rent_count": 21,
                "sale_count": 17
            },
            {
                "code": "TH103902",
                "name": "Khlong Tan Nua",
                "rent_count": 4,
                "sale_count": 0
            },
            {
                "code": "TH103903",
                "name": "Phra Kanong Nua",
                "rent_count": 2,
                "sale_count": 1
            }
        ],
        "description": "YX Property provides property sales, leasing and sourcing services for offices, commercial buildings, warehouses, factories, land, houses and condos.\n\nWe coordinate viewings, negotiations, contracts and handovers, with property management support available.\n\nContact us to list your property or discuss your requirements.",
        "listing_counts": {
            "rent": 26,
            "sale": 18
        }
    },
    "meta": {
        "billable": true,
        "endpoint_family": "agent"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | Neither id nor url was sent, or the id or url has the wrong shape. This response is not billable. |
| 404 | Not Found | No agent with this id exists. This response is not billable. |
| 503 | Upstream Unavailable | DDproperty could not be reached or returned data that does not match the request. This response is not billable and is retryable. |

## 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)
