diff --git a/clients/civic_info/lib/google_api/civic_info/v2/api/elections.ex b/clients/civic_info/lib/google_api/civic_info/v2/api/elections.ex index a214e9afae..90b81be748 100644 --- a/clients/civic_info/lib/google_api/civic_info/v2/api/elections.ex +++ b/clients/civic_info/lib/google_api/civic_info/v2/api/elections.ex @@ -43,6 +43,7 @@ defmodule GoogleApi.CivicInfo.V2.Api.Elections do * `: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 @@ -67,7 +68,8 @@ defmodule GoogleApi.CivicInfo.V2.Api.Elections do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :productionDataOnly => :query } request = @@ -103,6 +105,7 @@ defmodule GoogleApi.CivicInfo.V2.Api.Elections do * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `: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 @@ -131,6 +134,7 @@ defmodule GoogleApi.CivicInfo.V2.Api.Elections do :upload_protocol => :query, :electionId => :query, :officialOnly => :query, + :productionDataOnly => :query, :returnAllAvailableData => :query } diff --git a/clients/civic_info/lib/google_api/civic_info/v2/metadata.ex b/clients/civic_info/lib/google_api/civic_info/v2/metadata.ex index 8c9556bcac..3365f4483f 100644 --- a/clients/civic_info/lib/google_api/civic_info/v2/metadata.ex +++ b/clients/civic_info/lib/google_api/civic_info/v2/metadata.ex @@ -20,7 +20,7 @@ defmodule GoogleApi.CivicInfo.V2 do API client metadata for GoogleApi.CivicInfo.V2. """ - @discovery_revision "20220516" + @discovery_revision "20240305" def discovery_revision(), do: @discovery_revision end diff --git a/clients/civic_info/lib/google_api/civic_info/v2/model/contest.ex b/clients/civic_info/lib/google_api/civic_info/v2/model/contest.ex index 58ae89b3b4..6c6cd925bd 100644 --- a/clients/civic_info/lib/google_api/civic_info/v2/model/contest.ex +++ b/clients/civic_info/lib/google_api/civic_info/v2/model/contest.ex @@ -31,7 +31,6 @@ defmodule GoogleApi.CivicInfo.V2.Model.Contest do * `numberVotingFor` (*type:* `String.t`, *default:* `nil`) - The number of candidates that a voter may vote for in this contest. * `office` (*type:* `String.t`, *default:* `nil`) - The name of the office for this contest. * `primaryParties` (*type:* `list(String.t)`, *default:* `nil`) - If this is a partisan election, the name of the party/parties it is for. - * `primaryParty` (*type:* `String.t`, *default:* `nil`) - [DEPRECATED] If this is a partisan election, the name of the party it is for. This field as deprecated in favor of the array "primaryParties", as contests may contain more than one party. * `referendumBallotResponses` (*type:* `list(String.t)`, *default:* `nil`) - The set of ballot responses for the referendum. A ballot response represents a line on the ballot. Common examples might include "yes" or "no" for referenda. This field is only populated for contests of type 'Referendum'. * `referendumBrief` (*type:* `String.t`, *default:* `nil`) - Specifies a short summary of the referendum that is typically on the ballot below the title but above the text. This field is only populated for contests of type 'Referendum'. * `referendumConStatement` (*type:* `String.t`, *default:* `nil`) - A statement in opposition to the referendum. It does not necessarily appear on the ballot. This field is only populated for contests of type 'Referendum'. @@ -61,7 +60,6 @@ defmodule GoogleApi.CivicInfo.V2.Model.Contest do :numberVotingFor => String.t() | nil, :office => String.t() | nil, :primaryParties => list(String.t()) | nil, - :primaryParty => String.t() | nil, :referendumBallotResponses => list(String.t()) | nil, :referendumBrief => String.t() | nil, :referendumConStatement => String.t() | nil, @@ -88,7 +86,6 @@ defmodule GoogleApi.CivicInfo.V2.Model.Contest do field(:numberVotingFor) field(:office) field(:primaryParties, type: :list) - field(:primaryParty) field(:referendumBallotResponses, type: :list) field(:referendumBrief) field(:referendumConStatement) diff --git a/clients/civic_info/lib/google_api/civic_info/v2/model/feature_id_proto.ex b/clients/civic_info/lib/google_api/civic_info/v2/model/feature_id_proto.ex deleted file mode 100644 index b500051420..0000000000 --- a/clients/civic_info/lib/google_api/civic_info/v2/model/feature_id_proto.ex +++ /dev/null @@ -1,52 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# NOTE: This file is auto generated by the elixir code generator program. -# Do not edit this file manually. - -defmodule GoogleApi.CivicInfo.V2.Model.FeatureIdProto do - @moduledoc """ - A globally unique identifier associated with each feature. We use 128-bit identifiers so that we have lots of bits available to distinguish between features. The feature id currently consists of a 64-bit "cell id" that **sometimes** corresponds to the approximate centroid of the feature, plus a 64-bit fingerprint of other identifying information. See more on each respective field in its comments. Feature ids are first assigned when the data is created in MapFacts. After initial creation of the feature, they are immutable. This means that the only properties that you should rely on are that they are unique, and that cell_ids often - but not always - preserve spatial locality. The degree of locality varies as the feature undergoes geometry changes, and should not in general be considered a firm guarantee of the location of any particular feature. In fact, some locationless features have randomized cell IDs! Consumers of FeatureProtos from Mapfacts are guaranteed that fprints in the id field of features will be globally unique. Using the fprint allows consumers who don't need the spatial benefit of cell ids to uniquely identify features in a 64-bit address space. This property is not guaranteed for other sources of FeatureProtos. - - ## Attributes - - * `cellId` (*type:* `String.t`, *default:* `nil`) - The S2CellId corresponding to the approximate location of this feature as of when it was first created. This can be of variable accuracy, ranging from the exact centroid of the feature at creation, a very large S2 Cell, or even being completely randomized for locationless features. Cell ids have the nice property that they follow a space-filling curve over the surface of the earth. (See s2cellid.h for details.) WARNING: Clients should only use cell IDs to perform spatial locality optimizations. There is no strict guarantee that the cell ID of a feature is related to the current geometry of the feature in any way. - * `fprint` (*type:* `String.t`, *default:* `nil`) - A 64-bit fingerprint used to identify features. Most clients should rely on MapFacts or OneRing to choose fingerprints. If creating new fprints, the strategy should be chosen so that the chance of collision is remote or non-existent, and the distribution should be reasonably uniform. For example, if the source data assigns unique ids to features, then a fingerprint of the provider name, version, and source id is sufficient. - * `temporaryData` (*type:* `GoogleApi.CivicInfo.V2.Model.MessageSet.t`, *default:* `nil`) - A place for clients to attach arbitrary data to a feature ID. Never set in MapFacts. - """ - - use GoogleApi.Gax.ModelBase - - @type t :: %__MODULE__{ - :cellId => String.t() | nil, - :fprint => String.t() | nil, - :temporaryData => GoogleApi.CivicInfo.V2.Model.MessageSet.t() | nil - } - - field(:cellId) - field(:fprint) - field(:temporaryData, as: GoogleApi.CivicInfo.V2.Model.MessageSet) -end - -defimpl Poison.Decoder, for: GoogleApi.CivicInfo.V2.Model.FeatureIdProto do - def decode(value, options) do - GoogleApi.CivicInfo.V2.Model.FeatureIdProto.decode(value, options) - end -end - -defimpl Poison.Encoder, for: GoogleApi.CivicInfo.V2.Model.FeatureIdProto do - def encode(value, options) do - GoogleApi.Gax.ModelBase.encode(value, options) - end -end diff --git a/clients/civic_info/lib/google_api/civic_info/v2/model/geocoding_summary.ex b/clients/civic_info/lib/google_api/civic_info/v2/model/geocoding_summary.ex deleted file mode 100644 index 36d947753b..0000000000 --- a/clients/civic_info/lib/google_api/civic_info/v2/model/geocoding_summary.ex +++ /dev/null @@ -1,58 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# NOTE: This file is auto generated by the elixir code generator program. -# Do not edit this file manually. - -defmodule GoogleApi.CivicInfo.V2.Model.GeocodingSummary do - @moduledoc """ - Detailed summary of the result from geocoding an address - - ## Attributes - - * `addressUnderstood` (*type:* `boolean()`, *default:* `nil`) - Represents the best estimate of whether or not the input address was fully understood and the address is correctly componentized. Mirrors the same-name field in geostore.staging.AddressLinkupScoringProto. - * `featureId` (*type:* `GoogleApi.CivicInfo.V2.Model.FeatureIdProto.t`, *default:* `nil`) - The ID of the FeatureProto returned by the geocoder - * `featureType` (*type:* `String.t`, *default:* `nil`) - The feature type for the FeatureProto returned by the geocoder - * `positionPrecisionMeters` (*type:* `float()`, *default:* `nil`) - Precision of the center point (lat/long) of the geocoded FeatureProto - * `queryString` (*type:* `String.t`, *default:* `nil`) - The query sent to the geocoder - """ - - use GoogleApi.Gax.ModelBase - - @type t :: %__MODULE__{ - :addressUnderstood => boolean() | nil, - :featureId => GoogleApi.CivicInfo.V2.Model.FeatureIdProto.t() | nil, - :featureType => String.t() | nil, - :positionPrecisionMeters => float() | nil, - :queryString => String.t() | nil - } - - field(:addressUnderstood) - field(:featureId, as: GoogleApi.CivicInfo.V2.Model.FeatureIdProto) - field(:featureType) - field(:positionPrecisionMeters) - field(:queryString) -end - -defimpl Poison.Decoder, for: GoogleApi.CivicInfo.V2.Model.GeocodingSummary do - def decode(value, options) do - GoogleApi.CivicInfo.V2.Model.GeocodingSummary.decode(value, options) - end -end - -defimpl Poison.Encoder, for: GoogleApi.CivicInfo.V2.Model.GeocodingSummary do - def encode(value, options) do - GoogleApi.Gax.ModelBase.encode(value, options) - end -end diff --git a/clients/civic_info/lib/google_api/civic_info/v2/model/message_set.ex b/clients/civic_info/lib/google_api/civic_info/v2/model/message_set.ex deleted file mode 100644 index 69af3ad045..0000000000 --- a/clients/civic_info/lib/google_api/civic_info/v2/model/message_set.ex +++ /dev/null @@ -1,41 +0,0 @@ -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# NOTE: This file is auto generated by the elixir code generator program. -# Do not edit this file manually. - -defmodule GoogleApi.CivicInfo.V2.Model.MessageSet do - @moduledoc """ - This is proto2's version of MessageSet. - - ## Attributes - - """ - - use GoogleApi.Gax.ModelBase - - @type t :: %__MODULE__{} -end - -defimpl Poison.Decoder, for: GoogleApi.CivicInfo.V2.Model.MessageSet do - def decode(value, options) do - GoogleApi.CivicInfo.V2.Model.MessageSet.decode(value, options) - end -end - -defimpl Poison.Encoder, for: GoogleApi.CivicInfo.V2.Model.MessageSet do - def encode(value, options) do - GoogleApi.Gax.ModelBase.encode(value, options) - end -end diff --git a/clients/civic_info/lib/google_api/civic_info/v2/model/official.ex b/clients/civic_info/lib/google_api/civic_info/v2/model/official.ex index 3594137aff..8d2b3ce5fb 100644 --- a/clients/civic_info/lib/google_api/civic_info/v2/model/official.ex +++ b/clients/civic_info/lib/google_api/civic_info/v2/model/official.ex @@ -24,7 +24,6 @@ defmodule GoogleApi.CivicInfo.V2.Model.Official do * `address` (*type:* `list(GoogleApi.CivicInfo.V2.Model.SimpleAddressType.t)`, *default:* `nil`) - Addresses at which to contact the official. * `channels` (*type:* `list(GoogleApi.CivicInfo.V2.Model.Channel.t)`, *default:* `nil`) - A list of known (social) media channels for this official. * `emails` (*type:* `list(String.t)`, *default:* `nil`) - The direct email addresses for the official. - * `geocodingSummaries` (*type:* `list(GoogleApi.CivicInfo.V2.Model.GeocodingSummary.t)`, *default:* `nil`) - Detailed summary about the official's address's geocoding * `name` (*type:* `String.t`, *default:* `nil`) - The official's name. * `party` (*type:* `String.t`, *default:* `nil`) - The full name of the party the official belongs to. * `phones` (*type:* `list(String.t)`, *default:* `nil`) - The official's public contact phone numbers. @@ -38,7 +37,6 @@ defmodule GoogleApi.CivicInfo.V2.Model.Official do :address => list(GoogleApi.CivicInfo.V2.Model.SimpleAddressType.t()) | nil, :channels => list(GoogleApi.CivicInfo.V2.Model.Channel.t()) | nil, :emails => list(String.t()) | nil, - :geocodingSummaries => list(GoogleApi.CivicInfo.V2.Model.GeocodingSummary.t()) | nil, :name => String.t() | nil, :party => String.t() | nil, :phones => list(String.t()) | nil, @@ -49,7 +47,6 @@ defmodule GoogleApi.CivicInfo.V2.Model.Official do field(:address, as: GoogleApi.CivicInfo.V2.Model.SimpleAddressType, type: :list) field(:channels, as: GoogleApi.CivicInfo.V2.Model.Channel, type: :list) field(:emails, type: :list) - field(:geocodingSummaries, as: GoogleApi.CivicInfo.V2.Model.GeocodingSummary, type: :list) field(:name) field(:party) field(:phones, type: :list) diff --git a/clients/civic_info/lib/google_api/civic_info/v2/model/voter_info_response.ex b/clients/civic_info/lib/google_api/civic_info/v2/model/voter_info_response.ex index 9d345fb601..f2fffb1d9e 100644 --- a/clients/civic_info/lib/google_api/civic_info/v2/model/voter_info_response.ex +++ b/clients/civic_info/lib/google_api/civic_info/v2/model/voter_info_response.ex @@ -31,7 +31,7 @@ defmodule GoogleApi.CivicInfo.V2.Model.VoterInfoResponse do * `otherElections` (*type:* `list(GoogleApi.CivicInfo.V2.Model.Election.t)`, *default:* `nil`) - When there are multiple elections for a voter address, the otherElections field is populated in the API response and there are two possibilities: 1. If the earliest election is not the intended election, specify the election ID of the desired election in a second API request using the electionId field. 2. If these elections occur on the same day, the API doesn?t return any polling location, contest, or election official information to ensure that an additional query is made. For user-facing applications, we recommend displaying these elections to the user to disambiguate. A second API request using the electionId field should be made for the election that is relevant to the user. * `pollingLocations` (*type:* `list(GoogleApi.CivicInfo.V2.Model.PollingLocation.t)`, *default:* `nil`) - Locations where the voter is eligible to vote on election day. * `precinctId` (*type:* `String.t`, *default:* `nil`) - - * `precincts` (*type:* `list(GoogleApi.CivicInfo.V2.Model.Precinct.t)`, *default:* `nil`) - The precincts that match this voter's address. Will only be returned for project IDs which have been whitelisted as "partner projects". + * `precincts` (*type:* `list(GoogleApi.CivicInfo.V2.Model.Precinct.t)`, *default:* `nil`) - The precincts that match this voter's address. Will only be returned for project IDs which have been allowlisted as "partner projects". * `state` (*type:* `list(GoogleApi.CivicInfo.V2.Model.AdministrationRegion.t)`, *default:* `nil`) - Local Election Information for the state that the voter votes in. For the US, there will only be one element in this array. """