States

The state is a subset of the country and every country has list of states followed by state ID. State is also a targeting feature in Kayzen Platform along with Country for more granular target.

Returns a list of states that contain the search query. If no search query is specified, returns all states.

πŸ“˜

GET /api/v1/meta/states

Field

Param

Description

q

string(optional)

Field can be used as search query

country_id

int(optional)

Country ID is a unique ID for every country assigned in Kayzen Platform

per_page

Number of rows per page. Default Value- 25

page

Returns page number. Default Value- 1 page

curl -X GET \
'[HOST]/api/v1/meta/states?page=1&per_page=25&q=helmand&country_id=11' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer ' \
{"data":[{"id":11,"country_id":11,"country_alpha_2":"AF","name":"Helmand","iso_3166_2":"AF-HEL","created_at":"2016-06-23T11:16:36.000Z","updated_at":"2016-06-23T11:16:36.000Z"}],"meta":{"current_page":1,"total_pages":1,"total_entries":1}}