Items with filter and s_contains - Precisely Data Integrity Suite

Data Integrity Suite APIs

Product
Data_Integrity
Spatial_Analytics
Data_Enrichment
geo_addressing_1
Services
Spatial Analytics
Data Enrichment
Geo Addressing
ft:title
Data Integrity Suite APIs
ft:locale
en-US
PublicationType
pt_developer
copyrightfirst
2023
copyrightlast
2026

Returns records from the enrich buildings dataset which contain the input geometry. Here we pass a point object as input but any geometry can be sent including lines and polygons. If a line or polygon geometry was sent as input then the whole of the line or polygon must be contained within the building for a match to be made.

Example Request

https://api.cloud.precisely.com/v1/ogcapi/enrich/collections/pbb_usa/items?filter=s_contains(GEOM,POINT (-74.011728 40.701114))&limit=100

Request parameters

Name Type Required Description
collectionId * string Yes Unique identifier of the collection.

Example: pbb_usa

filter string No

The CQL2 filter clause.

filter=s_contains(GEOM,POINT (-74.011728 40.701114))

  • s_contains = the spatial operation to use
  • GEOM = The 1st parameter pf the spatial operation. This refers to the geometry in the target spatial table, in this case the building table pbb_usa. GEOM is a keyword which represents the spatial table geometry
  • POINT (-74.011728 40.701114) = This is the well known text representation of the input geometry.

Example Response Visualized

The red point shows the input point and the blue polygon is the building records that is returned in the response.

A map showing a red point within a blue polygon labeled Battery Maritime Building.

Example Response:

{
    "type": "FeatureCollection",
    "features": [
        {
            "type": "Feature",
            "properties": {
                "bldgid": "B000CTPA4MY1",
                "fips": "36061",
                "geoid": "360610009001022",
                "lon": -74.011651,
                "lat": 40.701039,
                "elevation": 0,
                "elevhigh": 8,
                "elevlow": -5,
                "area": 56396,
                "bldgtype": "B",
                "ubid": "87G7PX2Q+C8-3-5-3-5",
                "last_seen": "2025-01-01",
                "wkt": "POLYGON ((-74.011291 40.701255, -74.011211 40.701052, -74.011208 40.701052, -74.011142 40.701067, -74.011124 40.701071, -74.011106 40.701026, -74.011106 40.701025, -74.011112 40.701024, -74.01112 40.701022, -74.011093 40.700954, -74.011076 40.700958, -74.011065 40.70093, -74.011058 40.700912, -74.011059 40.700912, -74.011118 40.700898, -74.011122 40.700909, -74.011412 40.700844, -74.011411 40.700843, -74.011408 40.700836, -74.011458 40.700825, -74.011461 40.700832, -74.011462 40.700834, -74.011765 40.700765, -74.011765 40.700764, -74.011761 40.700754, -74.011811 40.700743, -74.011814 40.700752, -74.011865 40.70074, -74.012054 40.700698, -74.012074 40.700693, -74.012084 40.700691, -74.012115 40.700684, -74.012119 40.700683, -74.012116 40.700675, -74.012164 40.700665, -74.012179 40.700706, -74.012177 40.700708, -74.012226 40.700834, -74.012195 40.700841, -74.012217 40.700896, -74.012193 40.700902, -74.012141 40.700914, -74.012229 40.701139, -74.012231 40.701143, -74.012236 40.701141, -74.012254 40.701137, -74.012259 40.701149, -74.01227 40.701177, -74.012277 40.701194, -74.012286 40.701218, -74.011417 40.701416, -74.011359 40.701429, -74.011358 40.701425, -74.011356 40.701422, -74.011355 40.701419, -74.011294 40.701263, -74.011291 40.701255))"
            },
            "geometry": {
                "type": "MultiPolygon",
                "coordinates": [
                    [
                        [
                            [
                                -74.011291,
                                40.701255
                            ],
                            [
                                -74.011211,
                                40.701052
                            ],
                            [
                                -74.011208,
                                40.701052
                            ],
                            [
                                -74.011142,
                                40.701067
                            ],
                            [
                                -74.011124,
                                40.701071
                            ],
                            [
                                -74.011106,
                                40.701026
                            ],
                            [
                                -74.011106,
                                40.701025
                            ],
                            [
                                -74.011112,
                                40.701024
                            ],
                            [
                                -74.01112,
                                40.701022
                            ],
                            [
                                -74.011093,
                                40.700954
                            ],
                            [
                                -74.011076,
                                40.700958
                            ],
                            [
                                -74.011065,
                                40.70093
                            ],
                            [
                                -74.011058,
                                40.700912
                            ],
                            [
                                -74.011059,
                                40.700912
                            ],
                            [
                                -74.011118,
                                40.700898
                            ],
                            [
                                -74.011122,
                                40.700909
                            ],
                            [
                                -74.011412,
                                40.700844
                            ],
                            [
                                -74.011411,
                                40.700843
                            ],
                            [
                                -74.011408,
                                40.700836
                            ],
                            [
                                -74.011458,
                                40.700825
                            ],
                            [
                                -74.011461,
                                40.700832
                            ],
                            [
                                -74.011462,
                                40.700834
                            ],
                            [
                                -74.011765,
                                40.700765
                            ],
                            [
                                -74.011765,
                                40.700764
                            ],
                            [
                                -74.011761,
                                40.700754
                            ],
                            [
                                -74.011811,
                                40.700743
                            ],
                            [
                                -74.011814,
                                40.700752
                            ],
                            [
                                -74.011865,
                                40.70074
                            ],
                            [
                                -74.012054,
                                40.700698
                            ],
                            [
                                -74.012074,
                                40.700693
                            ],
                            [
                                -74.012084,
                                40.700691
                            ],
                            [
                                -74.012115,
                                40.700684
                            ],
                            [
                                -74.012119,
                                40.700683
                            ],
                            [
                                -74.012116,
                                40.700675
                            ],
                            [
                                -74.012164,
                                40.700665
                            ],
                            [
                                -74.012179,
                                40.700706
                            ],
                            [
                                -74.012177,
                                40.700708
                            ],
                            [
                                -74.012226,
                                40.700834
                            ],
                            [
                                -74.012195,
                                40.700841
                            ],
                            [
                                -74.012217,
                                40.700896
                            ],
                            [
                                -74.012193,
                                40.700902
                            ],
                            [
                                -74.012141,
                                40.700914
                            ],
                            [
                                -74.012229,
                                40.701139
                            ],
                            [
                                -74.012231,
                                40.701143
                            ],
                            [
                                -74.012236,
                                40.701141
                            ],
                            [
                                -74.012254,
                                40.701137
                            ],
                            [
                                -74.012259,
                                40.701149
                            ],
                            [
                                -74.01227,
                                40.701177
                            ],
                            [
                                -74.012277,
                                40.701194
                            ],
                            [
                                -74.012286,
                                40.701218
                            ],
                            [
                                -74.011417,
                                40.701416
                            ],
                            [
                                -74.011359,
                                40.701429
                            ],
                            [
                                -74.011358,
                                40.701425
                            ],
                            [
                                -74.011356,
                                40.701422
                            ],
                            [
                                -74.011355,
                                40.701419
                            ],
                            [
                                -74.011294,
                                40.701263
                            ],
                            [
                                -74.011291,
                                40.701255
                            ]
                        ]
                    ]
                ]
            }
        }
    ],
    "timeStamp": "2025-04-23T08:27:16Z",
    "links": [
        {
            "href": "https://api.cloud.precisely.com/v1/ogcapi/enrich/collections/pbb_usa/items?filter=s_contains(GEOM,POINT (-74.011728 40.701114))&limit=100",
            "rel": "self",
            "type": "application/geo+json",
            "title": "Current page"
        },
        {
            "href": "https://api.cloud.precisely.com/v1/ogcapi/enrich/collections/pbb_usa/items?filter=s_contains(GEOM,POINT (-74.011728 40.701114))&limit=100&offset=100",
            "rel": "next",
            "type": "application/geo+json",
            "title": "Next page"
        }
    ]
}