States
Index
To get a list of states within Boxid, make a request like this:
GET /api/v1/states
States are paginated and can be iterated through by passing along a page
parameter:
GET /api/v1/states?page=2
As well as a per_page
parameter to control how many results will be returned:
GET /api/v1/states?per_page=100
You can scope the states by country by passing along a country_id
parameter
too:
GET /api/v1/states?country_id=1
Response
Status:
200 OK
{"states": [{"id": 1,"name": "New York","abbr": "NY","country_id": 1}],"count": 25,"pages": 5,"current_page": 1}
Show
To find out about a single state, make a request like this:
GET /api/v1/states/1
Response
Status:
200 OK
{"id": 1,"name": "New York","abbr": "NY","country_id": 1}