Sidebar Menu

GetUrbanizationListForZipCode

The GetUrbanizationListForZipCode method returns all possible urbanization names for a given ZIP Code. (Urbanization names are used for addresses in Puerto Rico only.)

Endpoint

GET (HTTP): https://pav3.cdyne.com/PavService.svc/GetUrbanizationListForZipCode?ZipCode={ZIPCODE}&LicenseKey={LICENSEKEY}

GET (HTTPS): https://pav3.cdyne.com/PavService.svc/rest_s/GetUrbanizationListForZipCode?ZipCode={ZIPCODE}&LicenseKey={LICENSEKEY}

Syntax

GetUrbanizationListForZipCode(ZipCode, LicenseKey)

Request Parameters

Parameter Name Description Data Type Required Sample Value
ZipCode

ZIP Code.

String True 00956
LicenseKey

Your license key.

String True F01d89fd-5155-5455-5585-e84ab8de8591

Response

Returns: UrbanizationResponse object

Code Samples

// http://pav3.cdyne.com/PavService.svc?wsdl was added as Service Reference and given the name WSDL

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using GetUrbanizationListForZipCode.WSDL;

namespace GetUrbanizationListForZipCode
{
    class Program
    {
        static void Main(string[] args)
        {
            WSDL.PavServiceClient PSC = new PavServiceClient("pavsoap");
            WSDL.UrbanizationResponse UR = new WSDL.UrbanizationResponse();

            UR = PSC.GetUrbanizationListForZipCode("23320", "YOUR LICENSE KEY");

            if (UR.ReturnCode == 0)
            {
                Console.WriteLine("Urbanization Names Found: " + "\n");

                foreach (string Urban in UR.UrbanizationList)
                {
                    Console.WriteLine(Urban);
                }
            }
            else if (UR.ReturnCode == 1)
                Console.WriteLine("Invalid input.");
            else if (UR.ReturnCode == 2)
                Console.WriteLine("Invalid license key.");
            else if (UR.ReturnCode == 3)
                Console.WriteLine("No match found.");

            Console.ReadLine();
        }
    }
}
<cfhttp method="GET" url="http://pav3.cdyne.com/PavService.svc/GetUrbanizationListForZipCode" result="result">
  <cfhttpparam type="URL" name="ZipCode" value="23320">
  <cfhttpparam type="URL" name="LicenseKey" value="YOUR LICENSE KEY">
</cfhttp>
<cfset xmlDoc = XmlParse(#result.FileContent#) />
<cfdump var="#xmlDoc#" />
' http://pav3.cdyne.com/PavService.svc?wsdl was added as Service Reference and given the name WSDL

Imports GetUrbanizationListForZipCode.WSDL
Module Module1

    Sub Main()

        Dim PSC As New PavServiceClient("pavsoap")
        Dim UR As New UrbanizationResponse

        UR = PSC.GetUrbanizationListForZipCode("23320", "YOUR LICENSE KEY")

        If UR.ReturnCode = 0 Then
            Console.WriteLine("Urbanization Names Found: " & vbLf)

            For Each Urban As String In UR.UrbanizationList
                Console.WriteLine(Urban)
            Next

        ElseIf UR.ReturnCode = 1 Then
            Console.WriteLine("Invalid input.")

        ElseIf UR.ReturnCode = 2 Then
            Console.WriteLine("Invalid license key.")

        ElseIf UR.ReturnCode = 3 Then
            Console.WriteLine("No match found.")
        End If

        Console.ReadLine()

    End Sub

End Module
<?php
$client = new SoapClient('http://pav3.cdyne.com/PavService.svc?wsdl');
$param = array(
  'ZipCode' => '23320'
  , 'LicenseKey' => 'YOUR LICENSE KEY'
);
$result = $client->GetUrbanizationListForZipCode($param);

echo "<pre>";
print_r($result);
echo "</pre>";
?>
{
  "ReturnCode": 0,
  "UrbanizationList": [
    "ALTS DE BAYAMON",
    "BOSQUE DE LAS FLORES",
    "BOSQUE DE LAS PALMAS",
    "BOSQUE DE LOS PINOS",
    "CIUDAD INTERAMERICANA",
    "EST DEL BOSQUE",
    "EXT CAMPO ALEGRE",
    "EXT OLLER",
    "EXT SANTA JUANITA",
    "EXT VISTA BELLA",
    "HACIENDAS EL ZORZAL",
    "JARD DE BAYAMONTE",
    "LOMAS VERDES",
    "MANS DE SIERRA TAINA",
    "URB AGUSTIN STAHL",
    "URB AVENTURA",
    "URB BAYAMON HLS",
    "URB CAMPO ALEGRE",
    "URB COUNTRY EST",
    "URB EL CORTIJO",
    "URB FOREST VIEW",
    "URB FRANCISCO OLLER",
    "URB GOLDEN HLS",
    "URB IRLANDA HTS",
    "URB LOMAS VERDE",
    "URB LOS FAROLES",
    "URB MAGNOLIA GDNS",
    "URB ROYAL PALM",
    "URB ROYAL TOWN",
    "URB SANTA JUANITA",
    "URB SUNNY HLS",
    "VALLE BELLO CHALETS",
    "VILLA CONTESSA",
    "VILLAS DE BUENA VISTA",
    "VILLAS DE SANTA JUANITA",
    "VILLAS DEL CARIBE",
    "VISTA BELLA"
  ]
}
<UrbanizationResponse xmlns="pav3.cdyne.com" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <ReturnCode>0</ReturnCode>
  <UrbanizationList xmlns:a="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <a:string>ALTS DE BAYAMON</a:string>
    <a:string>BOSQUE DE LAS FLORES</a:string>
    <a:string>BOSQUE DE LAS PALMAS</a:string>
    <a:string>BOSQUE DE LOS PINOS</a:string>
    <a:string>CIUDAD INTERAMERICANA</a:string>
    <a:string>EST DEL BOSQUE</a:string>
    <a:string>EXT CAMPO ALEGRE</a:string>
    <a:string>EXT OLLER</a:string>
    <a:string>EXT SANTA JUANITA</a:string>
    <a:string>EXT VISTA BELLA</a:string>
    <a:string>HACIENDAS EL ZORZAL</a:string>
    <a:string>JARD DE BAYAMONTE</a:string>
    <a:string>LOMAS VERDES</a:string>
    <a:string>MANS DE SIERRA TAINA</a:string>
    <a:string>URB AGUSTIN STAHL</a:string>
    <a:string>URB AVENTURA</a:string>
    <a:string>URB BAYAMON HLS</a:string>
    <a:string>URB CAMPO ALEGRE</a:string>
    <a:string>URB COUNTRY EST</a:string>
    <a:string>URB EL CORTIJO</a:string>
    <a:string>URB FOREST VIEW</a:string>
    <a:string>URB FRANCISCO OLLER</a:string>
    <a:string>URB GOLDEN HLS</a:string>
    <a:string>URB IRLANDA HTS</a:string>
    <a:string>URB LOMAS VERDE</a:string>
    <a:string>URB LOS FAROLES</a:string>
    <a:string>URB MAGNOLIA GDNS</a:string>
    <a:string>URB ROYAL PALM</a:string>
    <a:string>URB ROYAL TOWN</a:string>
    <a:string>URB SANTA JUANITA</a:string>
    <a:string>URB SUNNY HLS</a:string>
    <a:string>VALLE BELLO CHALETS</a:string>
    <a:string>VILLA CONTESSA</a:string>
    <a:string>VILLAS DE BUENA VISTA</a:string>
    <a:string>VILLAS DE SANTA JUANITA</a:string>
    <a:string>VILLAS DEL CARIBE</a:string>
    <a:string>VISTA BELLA</a:string>
  </UrbanizationList>
</UrbanizationResponse>