List all stores

List all stores

GET api/stores

List all stores.

Request syntax

get api/stores

Request parameters

The request accepts no parameters.

Response syntax

[
    {
        "id": integer,
        "store_number": "string",
        "store_name": "string",
        "hostname": "string",
        "group": "string",
        "owner_name": "string",
        "level_of_hierarchy": "string",
        "card_acceptor_identifier": "string",
        "created_at": "timestamp",
        "updated_at": "timestamp"
    }
]

Response parameters

If the action is successful, an HTTP 200 response is returned. The following data is returned in JSON format.

FieldTypeDescription
idIntegerThe store ID.
store_numberStringThe store number.
store_nameStringThe store name.
hostnameStringThe hostname of the node or server that manages the store, for example pfc2324pay0. Empty if no host is assigned.
groupStringThe store group, for example US_ENGAGE.
owner_nameStringA display name generated from the store number, city, and state, for example Store: 9901 (Austin/TX).
level_of_hierarchyStringThe level of hierarchy the store is assigned to, for example United States > NE > NJ. null if the store isn't assigned to a level of hierarchy.
card_acceptor_identifierStringThe card acceptor identifier for the store. This parameter is only returned if the ETL feature is turned on.
created_atTimestampThe timestamp for when the store was initially created.
updated_atTimestampThe timestamp indicating when the store was last updated.

Errors

The following are common errors returned by this API.

CodeMessageCause
---

Examples

Example: List all stores

This example lists all stores. The response has been shortened.

ruby api.rb <customer_code> get api/stores

Response

[
  {
    "id": 250,
    "store_number": "9999",
    "store_name": "Device Depot",
    "hostname": "",
    "group": "",
    "owner_name": "Store: 9999 (New York/New York)",
    "level_of_hierarchy": "United States > NE > NJ",
    "card_acceptor_identifier": "890",
    "created_at": "2016-03-31T20:38:05.179Z",
    "updated_at": "2019-02-26T20:35:28.845Z"
  },
  {
    "id": 25511,
    "store_number": "2324",
    "store_name": "Lucas Test",
    "hostname": "pfc2324pay0",
    "group": "US_ENGAGE",
    "owner_name": "Store: 2324 (Honolulu/HI)",
    "level_of_hierarchy": null,
    "card_acceptor_identifier": "",
    "created_at": "2024-04-24T21:21:20.114Z",
    "updated_at": "2024-04-25T14:46:57.655Z"
  }
]