Fetch multiple features by type and ID
FeatureCollection Elements.Batch(ElementBatchParamsparameters, CancellationTokencancellationToken = default)
POST/api/v1/features/batch
Fetch multiple features by type and ID
ElementBatchParams parameters = new()
{
Elements =
[
new()
{
ID = 21154906,
Type = Type.Node,
},
new()
{
ID = 4589123,
Type = Type.Way,
},
],
};
var featureCollection = await client.Elements.Batch(parameters);
Console.WriteLine(featureCollection);{
"features": [
{
"geometry": {
"coordinates": [
2.3522,
48.8566
],
"type": "Point"
},
"properties": {
"@id": "bar",
"@type": "bar",
"amenity": "bar",
"cuisine": "bar",
"name": "bar"
},
"type": "Feature",
"id": "node/21154906"
}
],
"type": "FeatureCollection"
}Returns Examples
{
"features": [
{
"geometry": {
"coordinates": [
2.3522,
48.8566
],
"type": "Point"
},
"properties": {
"@id": "bar",
"@type": "bar",
"amenity": "bar",
"cuisine": "bar",
"name": "bar"
},
"type": "Feature",
"id": "node/21154906"
}
],
"type": "FeatureCollection"
}