---
search:
  tags:
    - customers
    - POST
seo:
  description: >-
    Score a building/landlord lead from PLUTO /… Reference for the POST
    /workspaces/{organizationId}/customers/{id}/building-scorecard endpoint in
    the Pile API.
sidebar:
  label: Create customer building scorecard
  badge: POST
title: Create customer building scorecard
type: openapi-operation
---
Score a building/landlord lead from PLUTO / ACRIS / HPD attributes. Pass `attrs` to score what you have; leave `fetchFromPluto` on (default) to backfill missing attributes from NYC Open Data PLUTO + HPD registrations first. Writes score/tier/XRF eligibility onto the customer and a building_scorecard memory fact.

`POST /workspaces/{organizationId}/customers/{id}/building-scorecard`

**Request body** (`application/json`)

- `attrs` (object)
- `fetchFromPluto` (boolean)

Request body example:

```json
{
  "attrs": {
    "bbl": "string",
    "bin": "string",
    "address": "string",
    "borough": "string",
    "zipcode": "string",
    "unitsRes": 0,
    "unitsTotal": 0,
    "buildingSqft": 0,
    "assessedTotalDollars": 0,
    "yearBuilt": 0,
    "lastSalePriceDollars": 0,
    "lastSaleDate": "string",
    "hpdRegistrationId": "string",
    "hpdManagingAgent": "string",
    "hpdOwnerName": "string",
    "openViolationsCount": 0
  },
  "fetchFromPluto": true
}
```

**Responses**

- `200` — Building scorecard breakdown applied to the customer
- `404` — Customer not found

Response example, 200:

```json
{
  "customerId": "string",
  "attributes": {
    "bbl": "string",
    "bin": "string",
    "address": "string",
    "borough": "string",
    "zipcode": "string",
    "unitsRes": 0,
    "unitsTotal": 0,
    "buildingSqft": 0,
    "assessedTotalDollars": 0,
    "yearBuilt": 0,
    "lastSalePriceDollars": 0,
    "lastSaleDate": "string",
    "hpdRegistrationId": "string",
    "hpdManagingAgent": "string",
    "hpdOwnerName": "string",
    "openViolationsCount": 0
  },
  "breakdown": {
    "score": 0,
    "tier": "A",
    "xrfLeadPaintEligible": true,
    "portfolioScale": "large_multifamily",
    "whyNow": "string",
    "factors": [
      {
        "key": "string",
        "label": "string",
        "points": 0,
        "detail": "string"
      }
    ]
  }
}
```
