Skip to content

area information

robert-valueguard edited this page Feb 20, 2024 · 24 revisions

The code below gives an example of how to use the client to get area information data

import valueguard

vgClient = valueguard.Client()
vgClient.authenticate("<username>", "<password>")

print(vgClient.area_information(search_criteria={
"area_id":5
}))

Field list

Field name Description Example
id ID of area information entity 1
area_id ID of area 5
field field information {'id': 1, 'name': 'Befolkningsmängd'}
value Value of the chosen field 1407
unit Unit of the chosen field Antal människor
created_at Creation datetime 2022-06-07T22:00:00.000+0000
updated_at Update datetime 2022-06-07T22:00:00.000+0000
valid_from Valid from datetime 2022-06-07T22:00:00.000+0000
valid_to Valid to datetime 2022-06-07T22:00:00.000+0000
information_source Information about the information source {'id': 1, 'name': 'Communal Ovevrlords'}
tags Information about the area information tag [{'id': 2, 'name': 'Befolkningsstatistik' ]}

Search criteria fields

Field name Description Example
area_ids ID of areas {1, 2, 3}
field_ids ID of fields {1, 2, 3}
valid_at Filter objects within timeframe valid_from and valid_to 2023-09-01

Raw request

Get

curl https://api.valueguard.se/v1/area/information?access_token={access_token}&area_ids={area_id}
Clone this wiki locally