POST Location/Localities

Get Localities for a postal code and country

Request Information

URI Parameters

None.

Body Parameters

GetLocalities
NameDescriptionTypeAdditional information
CountryID

integer

None.

RegionID

integer

None.

ProvinceID

integer

None.

Name

string

Required

Lang

string

None.

StoreID

integer

None.

Request Formats

application/json, text/json

Sample:
{
  "CountryID": 1,
  "RegionID": 1,
  "ProvinceID": 1,
  "Name": "sample string 2",
  "Lang": "sample string 3",
  "StoreID": 4
}

application/xml, text/xml

Sample:
<GetLocalities xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ShopworldApi.Web.Models.View.Location">
  <Lang xmlns="http://schemas.datacontract.org/2004/07/ShopworldApi.Web.Models.Common.Base">sample string 3</Lang>
  <StoreID xmlns="http://schemas.datacontract.org/2004/07/ShopworldApi.Web.Models.Common.Base">4</StoreID>
  <CountryID>1</CountryID>
  <Name>sample string 2</Name>
  <ProvinceID>1</ProvinceID>
  <RegionID>1</RegionID>
</GetLocalities>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

Collection of Locality
NameDescriptionTypeAdditional information
ID

integer

None.

Name

string

None.

ProvinceID

integer

None.

Places

Collection of Place

None.

Response Formats

application/json, text/json

Sample:
[
  {
    "ID": 1,
    "Name": "sample string 2",
    "ProvinceID": 1,
    "Places": [
      {
        "ID": 1,
        "Name": "sample string 2",
        "PostalCode": "sample string 3",
        "LocalityID": 1
      },
      {
        "ID": 1,
        "Name": "sample string 2",
        "PostalCode": "sample string 3",
        "LocalityID": 1
      }
    ]
  },
  {
    "ID": 1,
    "Name": "sample string 2",
    "ProvinceID": 1,
    "Places": [
      {
        "ID": 1,
        "Name": "sample string 2",
        "PostalCode": "sample string 3",
        "LocalityID": 1
      },
      {
        "ID": 1,
        "Name": "sample string 2",
        "PostalCode": "sample string 3",
        "LocalityID": 1
      }
    ]
  }
]

application/xml, text/xml

Sample:
<ArrayOfLocality xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/ShopworldApi.Web.Models.View.Location">
  <Locality>
    <ID>1</ID>
    <Name>sample string 2</Name>
    <Places>
      <Place>
        <ID>1</ID>
        <LocalityID>1</LocalityID>
        <Name>sample string 2</Name>
        <PostalCode>sample string 3</PostalCode>
      </Place>
      <Place>
        <ID>1</ID>
        <LocalityID>1</LocalityID>
        <Name>sample string 2</Name>
        <PostalCode>sample string 3</PostalCode>
      </Place>
    </Places>
    <ProvinceID>1</ProvinceID>
  </Locality>
  <Locality>
    <ID>1</ID>
    <Name>sample string 2</Name>
    <Places>
      <Place>
        <ID>1</ID>
        <LocalityID>1</LocalityID>
        <Name>sample string 2</Name>
        <PostalCode>sample string 3</PostalCode>
      </Place>
      <Place>
        <ID>1</ID>
        <LocalityID>1</LocalityID>
        <Name>sample string 2</Name>
        <PostalCode>sample string 3</PostalCode>
      </Place>
    </Places>
    <ProvinceID>1</ProvinceID>
  </Locality>
</ArrayOfLocality>