Developer API¶
For configured accounts, the Developer API section of My TargetSmart provides the following:
- Access to provisioned services
- Access to your API key
- Web forms for exploring TargetSmart’s API services
api.targetsmart.com¶
The api.targetsmart.com platform provides low latency data access web services (HTTP), allowing developers to integrate TargetSmart data into their applications easily.
Before using the services, TargetSmart Client Services will provision an API key configured with access to one or more endpoints.account.
Contact TargetSmart Client Services or TargetSmart Sales to discuss your integration use-case.
TargetSmart provides a public uptime status dashboard.
API Endpoints¶
Each service is attached to an endpoint that identifies the context and service:
https://api.targetsmart.com/context
/service
Contexts identify the data set accessible by the service:
person
: Returns results across the voting age population (VAP)voter
: Returns results for registered votersservice
: Workflow executions, informational data or other resources
Common JSON Response Keys¶
All services return JSON records. In addition to service specific keys, each service returns the following:
input
: Mirrors the request parameterserror
: Indicates error if appropriate, or None if no errors occurred. All errors start with one of:Authorization Error:
Indicates a service is not configured for your API Key, contact TargetSmart Client ServicesValidation Error:
Indicates invalid request parameter values, review the Docs for details on accepted parameter values for each serviceQuery Error:
Indicates a malformed query sent to the databaseInternal Error
Indicates an unknown error, contact TargetSmart Client Services and provide the entire response for assistance
gateway_id
: Used internally to identify requestsfunction_id
: Used internally to identify requestsstates_updated
: (If voter records are requested) Voter file update date information represented as a JSON object where keys are two character U.S. state codes and values are dates the state voter file was last updated. The date format is YYYYMMDD.
HTTP Codes¶
200
Successful request, which may still include an error in the response400
Missing required parameters in request403
API access denied, confirm your API Key before contacting Client Services500
An internal configuration error504
The service timed out, retry or revise your request
Data Dictionary¶
Fields returned in records are configured by Client Services. See Data Dictionary and Downloads for details on available fields.