Methods

Method detail for: getGeoSurroundByID

This request requires you to submit an object id. The API will return all objects within the target dataset that are contiguous with your identified object.

Valid Datasets

DatasetDataset DetailsMethod Parameters
ZIP CodesClick To ViewClick To View

When calling this dataset using this method, use these parameters:

  • fields*
  • id*
  • (Note: Items marked with * are required)

Sample Request and Return Data

<?xml version="1.0" encoding="UTF-8" ?> <data> <auth> <loginname>your_username</loginname> <key>your_api_key</key> </auth> <request> <dataset>Z</dataset> <method>getGeoSurroundByID</method> <returnType>xml</returnType> <parameters> <id>15425</id> <fields>zip,name</fields> </parameters> </request> </data>
{ "data":{ "auth":{ "loginname":"your_username", "key":"your_api_key" }, "request":[ { "dataset":"Z", "method":"getGeoSurroundByID", "returnType":"json", "parameters":{ "id":"15425", "fields":"zip,name" } } ] } }
<?xml version="1.0" encoding="UTF-8" ?> <data> <resultcode>0</resultcode> <message>Return OK</message> <requestid>03-14492</requestid> <request> <item> <zip>15683</zip> <name>SCOTTDALE</name> </item> <item> <zip>15469</zip> <name>NORMALVILLE</name> </item> <item> <zip>15486</zip> <name>VANDERBILT</name> </item> <item> <zip>15431</zip> <name>DUNBAR</name> </item> <item> <zip>15455</zip> <name>LEISENRING</name> </item> <item> <zip>15631</zip> <name>EVERSON</name> </item> <item> <zip>15490</zip> <name>WHITE</name> </item> </request> </data>
[ { "resultcode":0, "message":"Return OK", "requestid":"03-14491", "request":[ [ { "zip":"15683", "name":"SCOTTDALE" }, { "zip":"15469", "name":"NORMALVILLE" }, { "zip":"15486", "name":"VANDERBILT" }, { "zip":"15431", "name":"DUNBAR" }, { "zip":"15455", "name":"LEISENRING" }, { "zip":"15631", "name":"EVERSON" }, { "zip":"15464", "name":"MILL RUN" }, { "zip":"15666", "name":"MOUNT PLEASANT" }, { "zip":"15425", "name":"CONNELLSVILLE" }, { "zip":"15428", "name":"DAWSON" }, { "zip":"15456", "name":"LEMONT FURNACE" }, { "zip":"15490", "name":"WHITE" } ] ] } ]