Quick Start

Make your first StreetVerify API call in under 2 minutes. Assumes you already have an API key.

Get up and running with StreetVerify in less than 2 minutes. This guide assumes you already have an account and API key. If not, see our Getting Started guide.

Your First API Call

Verify an Address

curl -X GET "https://core.streetverify.com/api/v1/verify-address?address=1600%20Amphitheatre%20Parkway%2C%20Mountain%20View%2C%20CA" \
  -H "Authorization: Bearer YOUR_API_KEY"

Response:

{
  "verified_address": "1600 AMPHITHEATRE PARKWAY, MOUNTAIN VIEW CA 94043-1351",
  "status": "valid"
}

That’s it! You’ve just verified your first address.

Common Integration Examples

JavaScript/Node.js

const STREETVERIFY_API_KEY = 'YOUR_API_KEY';
const BASE_URL = 'https://core.streetverify.com/api/v1';

// Geocode an address
async function geocodeAddress(address) {
  const response = await fetch(
    `${BASE_URL}/geocode?address=${encodeURIComponent(address)}`,
    {
      headers: {
        'Authorization': `Bearer ${STREETVERIFY_API_KEY}`
      }
    }
  );
  
  return response.json();
}

// Example usage
const result = await geocodeAddress('1600 Amphitheatre Parkway, Mountain View, CA');
console.log(result.coordinates); // { lat: 37.4224764, lng: -122.0842499 }

Python

import requests

STREETVERIFY_API_KEY = 'YOUR_API_KEY'
BASE_URL = 'https://core.streetverify.com/api/v1'

def verify_address(address):
    response = requests.get(
        f'{BASE_URL}/verify-address',
        params={'address': address},
        headers={'Authorization': f'Bearer {STREETVERIFY_API_KEY}'}
    )
    return response.json()

# Example usage
result = verify_address('1600 Amphitheatre Parkway, Mountain View, CA')
print(result['verified_address'])

PHP

<?php
$apiKey = 'YOUR_API_KEY';
$address = '1600 Amphitheatre Parkway, Mountain View, CA';

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://core.streetverify.com/api/v1/verify-address?' . 
    http_build_query(['address' => $address]));
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'Authorization: Bearer ' . $apiKey
]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$response = curl_exec($ch);
$data = json_decode($response, true);

echo $data['verified_address'];
?>

All Available Endpoints

1. Address Verification

GET /api/v1/verify-address?address={address}

2. Geocoding

GET /api/v1/geocode?address={address}

3. Reverse Geocoding

GET /api/v1/reverse-geocode?lat={latitude}&lng={longitude}

4. Autocomplete

GET /api/v1/autocomplete?query={partial_address}

Quick Examples

Autocomplete for Better UX

// As user types in address field
async function handleAddressInput(partialAddress) {
  const response = await fetch(
    `https://core.streetverify.com/api/v1/autocomplete?query=${encodeURIComponent(partialAddress)}`,
    {
      headers: { 'Authorization': `Bearer ${STREETVERIFY_API_KEY}` }
    }
  );
  
  const data = await response.json();
  return data.predictions; // Array of address suggestions
}

Batch Processing

addresses = [
    "1600 Amphitheatre Parkway, Mountain View, CA",
    "1 Infinite Loop, Cupertino, CA",
    "1 Microsoft Way, Redmond, WA"
]

results = []
for address in addresses:
    result = verify_address(address)
    results.append(result)
    
# Process all verified addresses
for verified in results:
    print(f"Verified: {verified['verified_address']}")
    print("---")

Error Handling

Always check the response status:

const response = await fetch(url, options);

if (!response.ok) {
  const error = await response.json();
  console.error('API Error:', error.error);
  // Handle error appropriately
} else {
  const data = await response.json();
  // Process successful response
  console.log('Result:', data);
}

Response Headers

Monitor rate limits and usage:

X-RateLimit-Limit: 100
X-RateLimit-Remaining: 99
X-RateLimit-Reset: 1627849200

Testing Your Integration

Health Check

curl -X GET "https://core.streetverify.com/health" \
  -H "Authorization: Bearer YOUR_API_KEY"

Test Addresses

Use these addresses for testing different scenarios:

AddressPurpose
1600 Amphitheatre Parkway, Mountain View, CAValid business address
123 Main St, Anytown, USAGeneric test address
1 Infinite Loop, Cupertino, CA 95014Address with ZIP code
37.4224764,-122.0842499Coordinates for reverse geocoding

Pro Tips

  1. Cache Results: Save API calls by caching verified addresses
  2. Use Autocomplete: Reduce verification errors with address suggestions
  3. Handle Timeouts: Set reasonable timeouts (5-10 seconds)
  4. Log Errors: Track failed requests for debugging

What’s Next?


Need an API key? Create your account to get started.