chap_core.fetch package

Module contents

chap_core.fetch.get_area_polygons(country: str, regions: list[str] = None, admin_level: int = 1) FeatureCollectionModel[source]

Get the polygons for the specified regions in the specified country (only ADMIN1 supported) Returns only the regions that are found in the data Name is put in the id field of the feature

Parameters

countrystr

The country name

regionslist[str], optional

Filtering which regions to get the polygons for based on region name

admin_levelint

Which administrative level to get polygons for (0 for country, 1 for admin-1, etc)

Returns

FeatureCollectionModel

The polygons for the specified regions