Getting Locations

From Enterprise Help
Revision as of 07:51, 14 May 2015 by Sghosh (Talk | contribs)

Jump to: navigation, search

Some users may manage a business with multiple locations. If this is the case, it is strongly recommended that members are added with a StoreCode value. StoreCode can be used to target recipients when sending mailings with location-specific content. For sites that only have a single location, that location usually will have 001 as the StoreCode.


To get all locations associated with a specific Site, send a GET request to the Stores endpoint.


Sample Request:

  GET https://services.fishbowl.com/api/odata/v1/SITE_ID/Stores HTTP/1.1
Accept: application/json
Authorization: Bearer u7kBYz1UhHkoRSc7V4gruBs-4sEpIkFV-F4LGiFMwfGwJNnT_JzNft
g6_Zm0yWi8P m60iPlmCCHUSwCX5Uru-OJq2jzhbT-E6nAc1OwzghTCmeoo0K69ubDBMFX5hyKlc
AjA9H3Vs-ZNjNYKarpSO5rA5ubG5-Va5Aigm9mp-Pre-EaGAY_HBdxZi-LBMSQ_mSjyIDPBpLFYP
BNzK3cu0xGobGsFLxPtDG3urs_4abXZtvxN8wm9rpsgr


Sample Response:

  {
   "odata.metadata":"http://services.fishbowl.com/API/odata/v1/2147483947/
                     $metadata#Stores",
   "value":[
      {
         "StoreID":37101,
         "BrandID":501,
         "StoreCode":"001",
         "StoreName":"CA - MISSION HILLS (11010 SEPULVEDA BLVD)",
         "PrimaryContactTitle":null,
         "PrimaryContactFirstName":null,
         "PrimaryContactLastName":null,
         "PrimaryContactPhone":null,
         "PrimaryContactEmail":null,
         "SecondaryContactTitle":null,
         "SecondaryContactFirstName":null,
         "SecondaryContactLastName":null,
         "SecondaryContactPhone":null,
         "SecondaryContactEmail":null,
         "DisplayStoreName":"CA - MISSION HILLS (11010 SEPULVEDA BLVD)",
         "DisplayAddress1":"11010 SEPULVEDA BLVD",
         "DisplayAddress2":null,
         "MailingAddress1":"11010 SEPULVEDA BLVD",
         "MailingAddress2":null,
         "MailingCity":"MISSION HILLS",
         "MailingState":"CA",
         "MailingZip":"91345",
         "MailingCountry":"USA",
         "StorePhone":null,
         "StoreEmail":null,
         "StoreFax":null,
         "ShowOnJoin":true,
         "ParticipatesInMailings":true,
         "JoinPageURL":null,
         "JoinPageLocationText":"CA - MISSION HILLS (11010 SEPULVEDA BLVD)",
         "StatusCode":"OP",
         "Latitude":null,
         "Longitude":null,
         "CreatedUtc":"2008-10-25T02:40:29.307Z"
      },
      {
         "StoreID":37100,
         "BrandID":501,
         "StoreCode":"002",
         "StoreName":"CO - THORNTON (501 E 84TH ST)",
         "PrimaryContactTitle":null,
         "PrimaryContactFirstName":null,
         "PrimaryContactLastName":null,
         "PrimaryContactPhone":null,
         "PrimaryContactEmail":null,
         "SecondaryContactTitle":null,
         "SecondaryContactFirstName":null,
         "SecondaryContactLastName":null,
         "SecondaryContactPhone":null,
         "SecondaryContactEmail":null,
         "DisplayStoreName":"CO - THORNTON (501 E 84TH ST)",
         "DisplayAddress1":"501 E 84TH ST",
         "DisplayAddress2":null,
         "MailingAddress1":"501 E 84TH ST",
         "MailingAddress2":null,
         "MailingCity":"THORNTON",
         "MailingState":"CO",
         "MailingZip":"80229",
         "MailingCountry":"USA",
         "StorePhone":null,
         "StoreEmail":null,
         "StoreFax":null,
         "ShowOnJoin":true,
         "ParticipatesInMailings":true,
         "JoinPageURL":null,
         "JoinPageLocationText":"CO - THORNTON (501 E 84TH ST)",
         "StatusCode":"OP",
         "Latitude":null,
         "Longitude":null,
         "CreatedUtc":"2008-10-25T02:40:29.29Z"         
      }
   ]
}