---
title: "facet counts by places · RUAL Documentation"
description: "Counts how many items in a list are near each category : &ldquo;412 objects near a hospital&rdquo; in one node. Counts items, not places: an item with t…"
canonical: https://docs.rual.nl/block-types/places/places_facet
language: en
---

# facet counts by places

This block is part of the [`places`](https://docs.rual.nl/block-types/places) group and was last modified in core [`v15.0.0`](https://docs.rual.nl/core-versions/150000).

Counts how many items in a list are near each category : “412 objects near a hospital” in one node. Counts *items*, not places: an item with three hospitals nearby counts once, which is what a facet over an inventory means. Pass `categories` with a shared radius, or `filters` for a named filter per facet.

- items required `v15.0.0` `array` The list to process. Either an array of geo points, or an array of objects with `point path` naming where the coordinate sits.

- point path `v15.0.0` `value` Dotted path to the geo point inside each item, e.g. `general.location`. Leave empty when the items are geo points themselves.

- categories `v15.0.0` `array` Category groups to count, each using `radius`. Either this or `filters` is required.

- radius (m) `v15.0.0` `number` Radius applied to every category. Empty uses 500.

- filters `v15.0.0` `object` Named filters, as `{facet name: filter}`, for facets that need different radii or negation. Combined with `categories` if both are given.

- counts `v15.0.0` `object` Item count per category group or named filter.

- total `v15.0.0` `number` Items that had a usable coordinate and were evaluated. Compare against the input length to spot missing coordinates.

- success `v15.0.0` `condition` True when the query ran. An empty result is still a success.

- error `v15.0.0` `value` Error code when the query could not run: `PLACES_NOT_AVAILABLE`, `CATEGORIES_REQUIRED`.

### Core Releases
