Global Address Verification:Request: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 17: | Line 17: | ||
!Field Name !! Level !! REST !! JSON/XML | !Field Name !! Level !! REST !! JSON/XML | ||
|- style="vertical-align:top;" | |- style="vertical-align:top;" | ||
|Transmission Reference||Request||t||TransmissionReference | |Transmission Reference||rowspan="3" valign="center"|Request||t||TransmissionReference | ||
|- | |- | ||
|Customer ID | |Customer ID||id||CustomerID | ||
|- | |- | ||
|Options | |Options||opt||Options | ||
|- | |- | ||
|Record ID||Record|| ||RecordID | |Record ID||rowspan="18" valign="center"|Record|| ||RecordID | ||
|- | |- | ||
|Organization | |Organization||org||Organization | ||
|- | |- | ||
|Address Line 1 | |Address Line 1||a1||AddressLine1 | ||
|- | |- | ||
|Address Line 2 | |Address Line 2||a2||AddressLine2 | ||
|- | |- | ||
|Address Line 3 | |Address Line 3||a3||AddressLine3 | ||
|- | |- | ||
|Address Line 4 | |Address Line 4||a4||AddressLine4 | ||
|- | |- | ||
|Address Line 5 | |Address Line 5||a5||AddressLine5 | ||
|- | |- | ||
|Address Line 6 | |Address Line 6||a6||AddressLine6 | ||
|- | |- | ||
|Address Line 7 | |Address Line 7||a7||AddressLine7 | ||
|- | |- | ||
|Address Line 8 | |Address Line 8||a8||AddressLine8 | ||
|- | |- | ||
|Double Dependent Locality | |Double Dependent Locality||ddeploc||DoubleDependentLocality | ||
|- | |- | ||
|Dependent Locality | |Dependent Locality||deploc||DependentLocality | ||
|- | |- | ||
|Locality | |Locality||loc||Locality | ||
|- | |- | ||
|Sub Administrative Area | |Sub Administrative Area||subadmarea||SubAdministrativeArea | ||
|- | |- | ||
|Administrative Area | |Administrative Area||admarea||AdministrativeArea | ||
|- | |- | ||
|Postal Code | |Postal Code||postal||PostalCode | ||
|- | |- | ||
|Sub National Area | |Sub National Area||subnatarea||SubNationalArea | ||
|- | |- | ||
|Country | |Country||ctry||Country | ||
|- | |- | ||
|Format||Request||format||Format | |Format||Request||format||Format |
Revision as of 20:56, 7 October 2016
Global Address Navigation | |||||||
---|---|---|---|---|---|---|---|
| |||||||
| |||||||
| |||||||
| |||||||
Sample Code |
A request consists of a protocol to make a call to the service, detailing desired elements. The minimum required elements in a request are your Customer ID and at least one address record.
Global Address Verification supports JSON, JSONP, REST, SOAP, and XML protocols.
Field Names
This is a list of the request field names and their protocol naming conventions.
Field Name | Level | REST | JSON/XML |
---|---|---|---|
Transmission Reference | Request | t | TransmissionReference |
Customer ID | id | CustomerID | |
Options | opt | Options | |
Record ID | Record | RecordID | |
Organization | org | Organization | |
Address Line 1 | a1 | AddressLine1 | |
Address Line 2 | a2 | AddressLine2 | |
Address Line 3 | a3 | AddressLine3 | |
Address Line 4 | a4 | AddressLine4 | |
Address Line 5 | a5 | AddressLine5 | |
Address Line 6 | a6 | AddressLine6 | |
Address Line 7 | a7 | AddressLine7 | |
Address Line 8 | a8 | AddressLine8 | |
Double Dependent Locality | ddeploc | DoubleDependentLocality | |
Dependent Locality | deploc | DependentLocality | |
Locality | loc | Locality | |
Sub Administrative Area | subadmarea | SubAdministrativeArea | |
Administrative Area | admarea | AdministrativeArea | |
Postal Code | postal | PostalCode | |
Sub National Area | subnatarea | SubNationalArea | |
Country | ctry | Country | |
Format | Request | format | Format |
Request Elements
The following elements set the basic options for each request. These apply to the entire request, not the individual records.
Transmission Reference
- Optional.
- This is a string value that serves as a unique identifier for this set of records. It is returned as sent.
Protocol Syntax JSON "TransmissionReference":"string"
REST ?t = string
SOAP/XML <TransmissionReference>string</TransmissionReference>
Customer ID
- Required.
- This is a string value containing the identification number issued to the customer by Melissa Data for Global Address Verification.
- If this element is absent, the Web Service will return an error. To receive a customer ID, please contact your Melissa Data sales representative at 1-800-MELISSA.
Protocol Syntax JSON "CustomerID":"string"
REST &id = string
SOAP/XML <CustomerID>string</CustomerID>
Options
- Optional.
- This is a string value containing the options set by the user.
Protocol Syntax JSON "Options":"string"
REST ?opt = string
SOAP/XML <Options>string</Options>
- List options in the following format, with multiple options delimited with a ",".
Syntax OptionName:Parameter,OptionName:Parameter
DeliveryLines
- This options allows you to specify if the Address Lines 1-8 should contain just the delivery address or the entire address.
Option Name Parameter Description DeliveryLines Off
Default. Address Lines 1-8 return the entire address. On
Address Lines 1-8 return just the street address and dependent locality. It will not contain locality, administrative area, postal code, etc.
LineSeparator
- This is the line separator used for the FormattedAddress result.
Option Name Parameter Description LineSeparator SEMICOLON
Default. A semicolon (;). PIPE
A pipe (|). CR
A carriage return. LF
A line feed. CRLF
A carriage return + line feed. TAB
A tab. BR
A line break.
OutputScript
- This is the script type used for all applicable fields.
Option Name Parameter Description OutputScript NOCHANGE
Default. Returns the same script that is sent in. LATN
Returns in the Latin script. NATIVE
Returns in the native script for the designated country.
CountryOfOrigin
- This is used to determine whether or not to include the country name as the last line in FormattedAddress.
Option Name Parameter Description CountryOfOrigin (Any valid ISO-3166-1 Alpha-2, ISO-3166-1 Alpha-3, or ISO-3166-1 Numeric code) - If blank, invalid, or the same as the destination country, then the destination country is not appended to the end of the formatted address.
- If valid and different from the destination country, then the destination country is appended to the formatted address.
- US or US Territory:
- If CountryOfOrigin and destination country being verified are both US or US Territories then the country will not be appended to FormattedAddress.
- US Territories will have "United States of America" appended if the CountryOfOrigin is not a US Territory, but the CountryName and ISO codes will be that of the territory.
- Canada is treated like any other non-US Territory.
Request Record Elements
JSON will only contain the Records element.
Protocol | Definition |
---|---|
JSON | Each email will be contained within [{}] under the Records element. |
REST | The REST interface only allows a single record per request. |
SOAP | This element is an array of object variables of the type RequestRecords. |
XML | There will be one RequestRecord element per address being submitted to the Cloud Service. |
RecordID
- Optional.
- This is a string value containing a unique identifier for the current record. Use this to match the record submitted with the record returned. It will return the input.
Protocol Syntax JSON "RecordID":"string"
SOAP/XML <RecordID>string</RecordID>
Organization
- Optional.
- The organization name associated with the address record.
Protocol Syntax JSON "Organization":"string"
REST &org = string
SOAP/XML <Organization>string</Organization>
AddressLine1
- Required.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine1":"string"
REST &a1 = string
SOAP/XML <AddressLine1>string</AddressLine1>
AddressLine2
- Optional.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine2":"string"
REST &a2 = string
SOAP/XML <AddressLine2>string</AddressLine2>
AddressLine3
- Optional.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine3":"string"
REST &a3 = string
SOAP/XML <AddressLine3>string</AddressLine3>
AddressLine4
- Optional.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine4":"string"
REST &a4 = string
SOAP/XML <AddressLine4>string</AddressLine4>
AddressLine5
- Optional.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine5":"string"
REST &a5 = string
SOAP/XML <AddressLine5>string</AddressLine5>
AddressLine6
- Optional.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine6":"string"
REST &a6 = string
SOAP/XML <AddressLine6>string</AddressLine6>
AddressLine7
- Optional.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine7":"string"
REST &a7 = string
SOAP/XML <AddressLine7>string</AddressLine7>
AddressLine8
- Optional.
- The input field for the address. This should contain the delivery address information (house number, thoroughfare, building, suite, etc.) but should not contain locality information (locality, administrative area, postal code, etc.) which have their own inputs.
Protocol Syntax JSON "AddressLine8":"string"
REST &a8 = string
SOAP/XML <AddressLine8>string</AddressLine8>
DoubleDependentLocality
- Optional.
- The smallest population center data element. This depends on the Locality and DependentLocality elements.
Protocol Syntax JSON "DoubleDependentLocality":"string"
REST &ddeploc = string
SOAP/XML <DoubleDependentLocality>string</DoubleDependentLocality>
DependentLocality
- Optional.
- The smaller population center data element. This depends on the Locality element.
- US Term: Urbanization
- In terms of US Addresses, this element applies only to Puerto Rican addresses. It is used to break ties when a ZIP Code™ is linked to multiple instances of the same address.
Protocol Syntax JSON "DependentLocality":"string"
REST &deploc = string
SOAP/XML <DependentLocality>string</DependentLocality>
Locality
- Required.
- The most common population center data element.
- US Term: City
- Canada Term: Municipality
Protocol Syntax JSON "Locality":"string"
REST &loc = string
SOAP/XML <Locality>string</Locality>
SubAdministrativeArea
- Optional.
- The smallest geographic data element.
- US Term: County
Protocol Syntax JSON "SubAdministrativeArea":"string"
REST &subadmarea = string
SOAP/XML <SubAdministrativeArea>string</SubAdministrativeArea>
AdministrativeArea
- Required.
- The most common geographic data element.
- US Term: State
- Canada Term: Province
Protocol Syntax JSON "AdministrativeArea":"string"
REST &admarea = string
SOAP/XML <AdministrativeArea>string</AdministrativeArea>
PostalCode
- Required.
- The complete postal code for a particular delivery point.
- US Term: ZIP
- Canadian Term: Postcode
- If all three elements are provided and the PostalCode is incorrect, it can be corrected from the data on the Locality and AdministrativeArea.
Protocol Syntax JSON "PostalCode":"string"
REST &postal = string
SOAP/XML <PostalCode>string</PostalCode>
SubNationalArea
- Optional.
- The administrative region within a country on an arbitrary level below that of the sovereign state.
Protocol Syntax JSON "SubNationalArea":"string"
REST &subnatarea = string
SOAP/XML <SubNationalArea>string</SubNationalArea>
Country
- Required.
- The country name, abbreviation, or code.
Protocol Syntax JSON "Country":"string"
REST &ctry = string
SOAP/XML <Country>string</Country>
Format
- Optional.
- The desired format of the response.
Protocol Syntax REST &format = string
JSON/XML HTTP Header XML application/xml
JSON application/json