Field Squared API Services

<back to all web services

Geocode

Represents a DTO for a geocode request/response in a workspace. Usage is as follows
/Geocode?street=1514 Blake St&city=Denver&state=CO&zip=80209

The following routes are available for this service:
GET/{Workspace}/Geocode
import java.math.*;
import java.util.*;
import net.servicestack.client.*;

public class dtos
{

    /**
    * Represents a DTO for a geocode request/response in a workspace.  Usage is as follows  /Geocode?street=1514 Blake St&city=Denver&state=CO&zip=80209
    */
    public static class Geocode
    {
        public String Workspace = null;
        public ArrayList<Address> Addresses = null;
        
        public String getWorkspace() { return Workspace; }
        public Geocode setWorkspace(String value) { this.Workspace = value; return this; }
        public ArrayList<Address> getAddresses() { return Addresses; }
        public Geocode setAddresses(ArrayList<Address> value) { this.Addresses = value; return this; }
    }

    public static class Address
    {
        public String Street = null;
        public String Unit = null;
        public String City = null;
        public String State = null;
        public String Zip = null;
        public String ContactTitle = null;
        public String ContactName = null;
        public String ContactPhone = null;
        public String ContactEmail = null;
        public Location Location = null;
        public String SiteName = null;
        public Boolean GeocodeFailed = null;
        public String Country = null;
        
        public String getStreet() { return Street; }
        public Address setStreet(String value) { this.Street = value; return this; }
        public String getUnit() { return Unit; }
        public Address setUnit(String value) { this.Unit = value; return this; }
        public String getCity() { return City; }
        public Address setCity(String value) { this.City = value; return this; }
        public String getState() { return State; }
        public Address setState(String value) { this.State = value; return this; }
        public String getZip() { return Zip; }
        public Address setZip(String value) { this.Zip = value; return this; }
        public String getContactTitle() { return ContactTitle; }
        public Address setContactTitle(String value) { this.ContactTitle = value; return this; }
        public String getContactName() { return ContactName; }
        public Address setContactName(String value) { this.ContactName = value; return this; }
        public String getContactPhone() { return ContactPhone; }
        public Address setContactPhone(String value) { this.ContactPhone = value; return this; }
        public String getContactEmail() { return ContactEmail; }
        public Address setContactEmail(String value) { this.ContactEmail = value; return this; }
        public Location getLocation() { return Location; }
        public Address setLocation(Location value) { this.Location = value; return this; }
        public String getSiteName() { return SiteName; }
        public Address setSiteName(String value) { this.SiteName = value; return this; }
        public Boolean isGeocodeFailed() { return GeocodeFailed; }
        public Address setGeocodeFailed(Boolean value) { this.GeocodeFailed = value; return this; }
        public String getCountry() { return Country; }
        public Address setCountry(String value) { this.Country = value; return this; }
    }

    public static class Location
    {
        public Double y = null;
        public Double x = null;
        
        public Double getY() { return y; }
        public Location setY(Double value) { this.y = value; return this; }
        public Double getX() { return x; }
        public Location setX(Double value) { this.x = value; return this; }
    }

}

Java Geocode DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv

HTTP + JSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /{Workspace}/Geocode HTTP/1.1 
Host: dev.fieldsquared.com 
Accept: text/jsv