Skip to content

Instantly share code, notes, and snippets.

View michogar's full-sized avatar
🏄
Thinking about surfing...

Micho García michogar

🏄
Thinking about surfing...
View GitHub Profile
@michogar
michogar / index.js
Last active January 23, 2023 20:34
Getting multiple features with multiple cql filters at the same time
const axios = require('axios')
const geosolutions = 'https://demo.geo-solutions.it/geoserver'
const URL = (typeNames, cqlFilter, propertyName) => `${geosolutions}/wfs?SERVICE=WFS&VERSION=2.0.0&REQUEST=GetFeature&typeNames=${typeNames}&propertyName=${propertyName}&cql_filter=${cqlFilter}&outputFormat=application/json`
const typeNames = '(topp:tasmania_water_bodies)(topp:tasmania_roads)'
const cqlFilter = `AREA<1066494066;TYPE='alley'`
const propertyName = '(CNTRY_NAME)(TYPE)'