Global Address Verification Packages#
Packages/Samples covers the usage of Melissa Cloud APIs using popular third party tools, platforms, and programming languages. None of these are required but they can certainly get you up and running quickly.
For installation instructions and more detailed info, visit our Package Installation Guide: Installation Guide.
NuGet and Pip#
Melissa has developed an SDK for both NuGet (C# .NET) and pip (Python). Both environments follow the same patterns and naming convention so we will group them together.
GET Request#
Example
// Initialize the Global Address Object
GlobalAddressVerification globalAddress = new GlobalAddressVerification(MELISSA_LICENSE_KEY);
// Set the parameters
globalAddress.AddressLine1 = "22382 Avenida Empresa";
globalAddress.Locality = "Rancho Santa Margarita";
globalAddress.AdministrativeArea = "CA";
globalAddress.Postal = "92688";
globalAddress.Country = "United States";
// Make the GET request
GlobalAddressVerificationResponse responseObject = globalAddress.Get<GlobalAddressVerificationResponse>();
// Access the response value
string recId = responseObject.RecordID;
# Initialize the Global Address Object
global_address = GlobalAddressVerification(MELISSA_LICENSE_KEY)
# Set the parameters
global_address.address_line_1 = "22382 Avenida Empresa"
global_address.locality = "Rancho Santa Margarita"
global_address.administrative_area = "CA"
global_address.postal = "92688"
global_address.country = "United States"
# Make the GET request
response_object = global_address.get(GlobalAddressVerificationResponse)
# Access the response value
rec_id = response_object.record_id
POST Request#
Example
// Initialize the Global Address Object
GlobalAddressVerification globalAddress = new GlobalAddressVerification(MELISSA_LICENSE_KEY);
// Create a set of requests and set their parameters
globalAddress.AddRecord(new GlobalAddressVerificationRecordRequest
{
RecordID = "1",
AddressLine1 = "22382 Avenida Empresa",
Locality = "Rancho Santa Margarita",
AdministrativeArea = "CA",
PostalCode = "92688",
Country = "US"
});
globalAddress.AddRecord(new GlobalAddressVerificationRecordRequest
{
RecordID = "2",
AddressLine1 = "30 Dunn Dr",
Locality = "Bay Bulls",
AdministrativeArea = "NL",
PostalCode = "A0A1C0",
Country = "CA"
});
// Make the POST request
GlobalAddressVerificationResponse responseObject = globalAddress.Get<GlobalAddressVerificationResponse>();
// Access the response value
string recId = responseObject.RecordID;
# Initialize the Global Address Object
global_address = GlobalAddressVerification(MELISSA_LICENSE_KEY)
# Create a set of requests and set their parameters
global_address.add_record(GlobalAddressVerificationRecordRequest(
record_id = "1",
address_line_1 = "22382 Avenida Empresa",
locality = "Rancho Santa Margarita",
administrative_area = "CA",
postal_code = "92688",
country = "US"
))
global_address.add_record(GlobalAddressVerificationRecordRequest(
record_id = "2",
address_line_1 = "30 Dunn Dr",
locality = "Bay Bulls",
administrative_area = "NL",
postal_code = "A0A1C0",
country = "CA"
))
# Make the POST request
response_object = global_address.get(GlobalAddressVerificationResponse)
# Access the response value
rec_id = response_object.record_id
For more information on the Global Address Verification Packages please click here.
To see detailed Sample Code for this package see:
OpenAPI (Swagger)#
OpenAPI is a popular specification for describing REST APIs. By providing swagger JSON documents, you can automatically generate client code and test applications.
Melissa is working on providing a swagger JSON document for our services. Please stay tuned!
Postman#
Postman is a quick and easy way to test raw HTTP requests and responses. Using our pre-made request templates, you can start testing and generating code snippets for our Cloud APIs in seconds.
Sample Code#
This sample code illustrates how to construct raw HTTP requests to Melissa’s cloud API.
Language |
Repository |
---|---|
C# .NET |
|
Python3 |