States are used to categorize theatres based on state.
Verb | Endpoint | Description | |
---|---|---|---|
GET | /v1/states | Get All States. | |
GET | /v1/states/{state-slug} | Get State By Slug. |
page-number
query string parameter to specify which page of results to retrieve.
page-size
query string parameter to specify the number of results per page.
Name | Description |
---|---|
pageSize | The number of results included for each page, up to a maximum of 100. Defaults to 10. |
pageNumber | The page number returned. |
count | The total number of results available across all pages. |
_embedded.States | A list of State Representations returned. |
Relation | Description | Verbs | Templated |
---|---|---|---|
self | The current list of states results. | GET | No |
previous | The previous page of states results. | GET | No |
next | The next page of states results. | GET | No |
Name | Description |
---|---|
name | Full name for display. |
abbreviation | The state abbreviation. |
slug | The state slug. |
_embedded.Cities | A list of City Representations returned. |
Relation | Description | Methods | Templated |
---|---|---|---|
self | The current state representation. | GET | No |
https://api.amctheatres.com/v2/theatres | A list of theatres in this state. | GET | No |
Name | Description |
---|---|
name | Full name for display. |
slug | The city slug. |
Relation | Description | Methods | Templated |
---|---|---|---|
self | The current city representation. | GET | No |
https://api.amctheatres.com/v2/theatres | List of theatres in the current city. | GET | No |
GET /v1/states
{ "pageSize": 1, "pageNumber": 1, "count": 42, "_embedded": { "states": [ { "name": "ALABAMA", "abbreviation": "AL", "slug": "alabama", "_embedded": { "cities": [ { "name": "MONTGOMERY", "slug": "montgomery", "_links": { "self": { "href": "https://api.amctheatres.com/v1/states/alabama/montgomery", "templated": false }, "https://api.amctheatres.com/v2/theatres": { "href": "https://api.amctheatres.com/v2/theatres?state=alabama&city=montgomery", "templated": false } } } ] }, "_links": { "self": { "href": "https://api.amctheatres.com/v1/states/alabama", "templated": false }, "https://api.amctheatres.com/v2/theatres": { "href": "https://api.amctheatres.com/v2/theatres?state=alabama", "templated": false } } } ] }, "_links": { "self": { "href": "https://api.amctheatres.com/v1/states?pageNumber=1&pageSize=1", "templated": false }, "previous": { "href": "https://api.amctheatres.com/v1/states?pageNumber=1&pageSize=1", "templated": false }, "next": { "href": "https://api.amctheatres.com/v1/states?pageNumber=2&pagesize=1" } } }
GET /v1/states/wyoming
{ "name": "WYOMING", "abbreviation": "WY", "slug": "wyoming", "_embedded": { "cities": [ { "name": "CHEYENNE", "slug": "cheyenne", "_links": { "self": { "href": "https://api.amctheatres.com/v1/states/wyoming/cheyenne", "templated": false }, "https://api.amctheatres.com/rels/v2/theatres": { "href": "https://api.amctheatres.com/v2/theatres?state=wyoming&city=cheyenne", "templated": false } } } ] }, "_links": { "self": { "href": "https://api.amctheatres.com/v1/states/wyoming", "templated": false }, "https://api.amctheatres.com/rels/v2/theatres": { "href": "https://api.amctheatres.com/v2/theatres?state=wyoming", "templated": false } } }