GoogleApi.CivicInfo.V2.Api.Elections (google_api_civic_info v0.26.0)
View SourceAPI calls for all endpoints tagged Elections
.
Summary
Functions
List of available elections to query.
Looks up information relevant to a voter based on the voter's registered address.
Functions
@spec civicinfo_elections_election_query(Tesla.Env.client(), keyword(), keyword()) :: {:ok, GoogleApi.CivicInfo.V2.Model.CivicinfoApiprotosV2ElectionsQueryResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
List of available elections to query.
Parameters
-
connection
(type:GoogleApi.CivicInfo.V2.Connection.t
) - Connection to server -
optional_params
(type:keyword()
) - Optional parameters-
:"$.xgafv"
(type:String.t
) - V1 error format. -
:access_token
(type:String.t
) - OAuth access token. -
:alt
(type:String.t
) - Data format for response. -
:callback
(type:String.t
) - JSONP -
:fields
(type:String.t
) - Selector specifying which fields to include in a partial response. -
:key
(type:String.t
) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token
(type:String.t
) - OAuth 2.0 token for the current user. -
:prettyPrint
(type:boolean()
) - Returns response with indentations and line breaks. -
:quotaUser
(type:String.t
) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType
(type:String.t
) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol
(type:String.t
) - Upload protocol for media (e.g. "raw", "multipart"). -
:productionDataOnly
(type:boolean()
) - Whether to include data that has not been allowlisted yet
-
-
opts
(type:keyword()
) - Call options
Returns
-
{:ok, %GoogleApi.CivicInfo.V2.Model.CivicinfoApiprotosV2ElectionsQueryResponse{}}
on success -
{:error, info}
on failure
@spec civicinfo_elections_voter_info_query(Tesla.Env.client(), keyword(), keyword()) :: {:ok, GoogleApi.CivicInfo.V2.Model.CivicinfoApiprotosV2VoterInfoResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
Looks up information relevant to a voter based on the voter's registered address.
Parameters
-
connection
(type:GoogleApi.CivicInfo.V2.Connection.t
) - Connection to server -
optional_params
(type:keyword()
) - Optional parameters-
:"$.xgafv"
(type:String.t
) - V1 error format. -
:access_token
(type:String.t
) - OAuth access token. -
:alt
(type:String.t
) - Data format for response. -
:callback
(type:String.t
) - JSONP -
:fields
(type:String.t
) - Selector specifying which fields to include in a partial response. -
:key
(type:String.t
) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token
(type:String.t
) - OAuth 2.0 token for the current user. -
:prettyPrint
(type:boolean()
) - Returns response with indentations and line breaks. -
:quotaUser
(type:String.t
) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType
(type:String.t
) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol
(type:String.t
) - Upload protocol for media (e.g. "raw", "multipart"). -
:address
(type:String.t
) - The registered address of the voter to look up. -
:electionId
(type:String.t
) - The unique ID of the election to look up. A list of election IDs can be obtained at https://www.googleapis.com/civicinfo/{version}/elections. If no election ID is specified in the query and there is more than one election with data for the given voter, the additional elections are provided in the otherElections response field. -
:officialOnly
(type:boolean()
) - If set to true, only data from official state sources will be returned. -
:productionDataOnly
(type:boolean()
) - Whether to include data that has not been vetted yet. Should only be made available to internal IPs or trusted partners. This is a non-discoverable parameter in the One Platform API config. -
:returnAllAvailableData
(type:boolean()
) - If set to true, the query will return the success code and include any partial information when it is unable to determine a matching address or unable to determine the election for electionId=0 queries.
-
-
opts
(type:keyword()
) - Call options
Returns
-
{:ok, %GoogleApi.CivicInfo.V2.Model.CivicinfoApiprotosV2VoterInfoResponse{}}
on success -
{:error, info}
on failure