Skip to content

Commit 85ddd3e

Browse files
feat: Automated regeneration of Dialogflow client (googleapis#12743)
Auto-created at 2024-12-19 13:15:03 +0000 using the toys pull request generator.
1 parent 482a5b9 commit 85ddd3e

19 files changed

+705
-4
lines changed

clients/dialogflow/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Install this package from [Hex](https://hex.pm) by adding
1111

1212
```elixir
1313
def deps do
14-
[{:google_api_dialogflow, "~> 0.88"}]
14+
[{:google_api_dialogflow, "~> 0.89"}]
1515
end
1616
```
1717

clients/dialogflow/lib/google_api/dialogflow/v2/metadata.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ defmodule GoogleApi.Dialogflow.V2 do
2020
API client metadata for GoogleApi.Dialogflow.V2.
2121
"""
2222

23-
@discovery_revision "20241212"
23+
@discovery_revision "20241216"
2424

2525
def discovery_revision(), do: @discovery_revision
2626
end

clients/dialogflow/lib/google_api/dialogflow/v2/model/google_cloud_dialogflow_v2_conversation_event.ex

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2ConversationEvent
2424
* `conversation` (*type:* `String.t`, *default:* `nil`) - The unique identifier of the conversation this notification refers to. Format: `projects//conversations/`.
2525
* `errorStatus` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleRpcStatus.t`, *default:* `nil`) - More detailed information about an error. Only set for type UNRECOVERABLE_ERROR_IN_PHONE_CALL.
2626
* `newMessagePayload` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2Message.t`, *default:* `nil`) - Payload of NEW_MESSAGE event.
27+
* `newRecognitionResultPayload` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2StreamingRecognitionResult.t`, *default:* `nil`) - Payload of NEW_RECOGNITION_RESULT event.
2728
* `type` (*type:* `String.t`, *default:* `nil`) - The type of the event that this notification refers to.
2829
"""
2930

@@ -34,12 +35,20 @@ defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2ConversationEvent
3435
:errorStatus => GoogleApi.Dialogflow.V2.Model.GoogleRpcStatus.t() | nil,
3536
:newMessagePayload =>
3637
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2Message.t() | nil,
38+
:newRecognitionResultPayload =>
39+
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2StreamingRecognitionResult.t()
40+
| nil,
3741
:type => String.t() | nil
3842
}
3943

4044
field(:conversation)
4145
field(:errorStatus, as: GoogleApi.Dialogflow.V2.Model.GoogleRpcStatus)
4246
field(:newMessagePayload, as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2Message)
47+
48+
field(:newRecognitionResultPayload,
49+
as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2StreamingRecognitionResult
50+
)
51+
4352
field(:type)
4453
end
4554

clients/dialogflow/lib/google_api/dialogflow/v2/model/google_cloud_dialogflow_v2_conversation_profile.ex

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2ConversationProfi
3030
* `loggingConfig` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2LoggingConfig.t`, *default:* `nil`) - Configuration for logging conversation lifecycle events.
3131
* `name` (*type:* `String.t`, *default:* `nil`) - The unique identifier of this conversation profile. Format: `projects//locations//conversationProfiles/`.
3232
* `newMessageEventNotificationConfig` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig.t`, *default:* `nil`) - Configuration for publishing new message events. Event will be sent in format of ConversationEvent
33+
* `newRecognitionResultNotificationConfig` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig.t`, *default:* `nil`) - Optional. Configuration for publishing transcription intermediate results. Event will be sent in format of ConversationEvent. If configured, the following information will be populated as ConversationEvent Pub/Sub message attributes: - "participant_id" - "participant_role" - "message_id"
3334
* `notificationConfig` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig.t`, *default:* `nil`) - Configuration for publishing conversation lifecycle events.
3435
* `securitySettings` (*type:* `String.t`, *default:* `nil`) - Name of the CX SecuritySettings reference for the agent. Format: `projects//locations//securitySettings/`.
3536
* `sttConfig` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechToTextConfig.t`, *default:* `nil`) - Settings for speech transcription.
@@ -56,6 +57,8 @@ defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2ConversationProfi
5657
:name => String.t() | nil,
5758
:newMessageEventNotificationConfig =>
5859
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig.t() | nil,
60+
:newRecognitionResultNotificationConfig =>
61+
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig.t() | nil,
5962
:notificationConfig =>
6063
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig.t() | nil,
6164
:securitySettings => String.t() | nil,
@@ -90,6 +93,10 @@ defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2ConversationProfi
9093
as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig
9194
)
9295

96+
field(:newRecognitionResultNotificationConfig,
97+
as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig
98+
)
99+
93100
field(:notificationConfig,
94101
as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2NotificationConfig
95102
)
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechWordInfo do
19+
@moduledoc """
20+
Information for a word recognized by the speech recognizer.
21+
22+
## Attributes
23+
24+
* `confidence` (*type:* `number()`, *default:* `nil`) - The Speech confidence between 0.0 and 1.0 for this word. A higher number indicates an estimated greater likelihood that the recognized word is correct. The default of 0.0 is a sentinel value indicating that confidence was not set. This field is not guaranteed to be fully stable over time for the same audio input. Users should also not rely on it to always be provided.
25+
* `endOffset` (*type:* `String.t`, *default:* `nil`) - Time offset relative to the beginning of the audio that corresponds to the end of the spoken word. This is an experimental feature and the accuracy of the time offset can vary.
26+
* `startOffset` (*type:* `String.t`, *default:* `nil`) - Time offset relative to the beginning of the audio that corresponds to the start of the spoken word. This is an experimental feature and the accuracy of the time offset can vary.
27+
* `word` (*type:* `String.t`, *default:* `nil`) - The word this info is for.
28+
"""
29+
30+
use GoogleApi.Gax.ModelBase
31+
32+
@type t :: %__MODULE__{
33+
:confidence => number() | nil,
34+
:endOffset => String.t() | nil,
35+
:startOffset => String.t() | nil,
36+
:word => String.t() | nil
37+
}
38+
39+
field(:confidence)
40+
field(:endOffset)
41+
field(:startOffset)
42+
field(:word)
43+
end
44+
45+
defimpl Poison.Decoder, for: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechWordInfo do
46+
def decode(value, options) do
47+
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechWordInfo.decode(value, options)
48+
end
49+
end
50+
51+
defimpl Poison.Encoder, for: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechWordInfo do
52+
def encode(value, options) do
53+
GoogleApi.Gax.ModelBase.encode(value, options)
54+
end
55+
end
Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2StreamingRecognitionResult do
19+
@moduledoc """
20+
Contains a speech recognition result corresponding to a portion of the audio that is currently being processed or an indication that this is the end of the single requested utterance. While end-user audio is being processed, Dialogflow sends a series of results. Each result may contain a `transcript` value. A transcript represents a portion of the utterance. While the recognizer is processing audio, transcript values may be interim values or finalized values. Once a transcript is finalized, the `is_final` value is set to true and processing continues for the next transcript. If `StreamingDetectIntentRequest.query_input.audio_config.single_utterance` was true, and the recognizer has completed processing audio, the `message_type` value is set to `END_OF_SINGLE_UTTERANCE and the following (last) result contains the last finalized transcript. The complete end-user utterance is determined by concatenating the finalized transcript values received for the series of results. In the following example, single utterance is enabled. In the case where single utterance is not enabled, result 7 would not occur. ``` Num | transcript | message_type | is_final --- | ----------------------- | ----------------------- | -------- 1 | "tube" | TRANSCRIPT | false 2 | "to be a" | TRANSCRIPT | false 3 | "to be" | TRANSCRIPT | false 4 | "to be or not to be" | TRANSCRIPT | true 5 | "that's" | TRANSCRIPT | false 6 | "that is | TRANSCRIPT | false 7 | unset | END_OF_SINGLE_UTTERANCE | unset 8 | " that is the question" | TRANSCRIPT | true ``` Concatenating the finalized transcripts with `is_final` set to true, the complete utterance becomes "to be or not to be that is the question".
21+
22+
## Attributes
23+
24+
* `confidence` (*type:* `number()`, *default:* `nil`) - The Speech confidence between 0.0 and 1.0 for the current portion of audio. A higher number indicates an estimated greater likelihood that the recognized words are correct. The default of 0.0 is a sentinel value indicating that confidence was not set. This field is typically only provided if `is_final` is true and you should not rely on it being accurate or even set.
25+
* `isFinal` (*type:* `boolean()`, *default:* `nil`) - If `false`, the `StreamingRecognitionResult` represents an interim result that may change. If `true`, the recognizer will not return any further hypotheses about this piece of the audio. May only be populated for `message_type` = `TRANSCRIPT`.
26+
* `languageCode` (*type:* `String.t`, *default:* `nil`) - Detected language code for the transcript.
27+
* `messageType` (*type:* `String.t`, *default:* `nil`) - Type of the result message.
28+
* `speechEndOffset` (*type:* `String.t`, *default:* `nil`) - Time offset of the end of this Speech recognition result relative to the beginning of the audio. Only populated for `message_type` = `TRANSCRIPT`.
29+
* `speechWordInfo` (*type:* `list(GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechWordInfo.t)`, *default:* `nil`) - Word-specific information for the words recognized by Speech in transcript. Populated if and only if `message_type` = `TRANSCRIPT` and [InputAudioConfig.enable_word_info] is set.
30+
* `transcript` (*type:* `String.t`, *default:* `nil`) - Transcript text representing the words that the user spoke. Populated if and only if `message_type` = `TRANSCRIPT`.
31+
"""
32+
33+
use GoogleApi.Gax.ModelBase
34+
35+
@type t :: %__MODULE__{
36+
:confidence => number() | nil,
37+
:isFinal => boolean() | nil,
38+
:languageCode => String.t() | nil,
39+
:messageType => String.t() | nil,
40+
:speechEndOffset => String.t() | nil,
41+
:speechWordInfo =>
42+
list(GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechWordInfo.t()) | nil,
43+
:transcript => String.t() | nil
44+
}
45+
46+
field(:confidence)
47+
field(:isFinal)
48+
field(:languageCode)
49+
field(:messageType)
50+
field(:speechEndOffset)
51+
52+
field(:speechWordInfo,
53+
as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2SpeechWordInfo,
54+
type: :list
55+
)
56+
57+
field(:transcript)
58+
end
59+
60+
defimpl Poison.Decoder,
61+
for: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2StreamingRecognitionResult do
62+
def decode(value, options) do
63+
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2StreamingRecognitionResult.decode(
64+
value,
65+
options
66+
)
67+
end
68+
end
69+
70+
defimpl Poison.Encoder,
71+
for: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2StreamingRecognitionResult do
72+
def encode(value, options) do
73+
GoogleApi.Gax.ModelBase.encode(value, options)
74+
end
75+
end

clients/dialogflow/lib/google_api/dialogflow/v2/model/google_cloud_dialogflow_v2beta1_conversation_event.ex

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1Conversation
2424
* `conversation` (*type:* `String.t`, *default:* `nil`) - Required. The unique identifier of the conversation this notification refers to. Format: `projects//conversations/`.
2525
* `errorStatus` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleRpcStatus.t`, *default:* `nil`) - Optional. More detailed information about an error. Only set for type UNRECOVERABLE_ERROR_IN_PHONE_CALL.
2626
* `newMessagePayload` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1Message.t`, *default:* `nil`) - Payload of NEW_MESSAGE event.
27+
* `newRecognitionResultPayload` (*type:* `GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1StreamingRecognitionResult.t`, *default:* `nil`) - Payload of NEW_RECOGNITION_RESULT event.
2728
* `type` (*type:* `String.t`, *default:* `nil`) - Required. The type of the event that this notification refers to.
2829
"""
2930

@@ -34,12 +35,20 @@ defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1Conversation
3435
:errorStatus => GoogleApi.Dialogflow.V2.Model.GoogleRpcStatus.t() | nil,
3536
:newMessagePayload =>
3637
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1Message.t() | nil,
38+
:newRecognitionResultPayload =>
39+
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1StreamingRecognitionResult.t()
40+
| nil,
3741
:type => String.t() | nil
3842
}
3943

4044
field(:conversation)
4145
field(:errorStatus, as: GoogleApi.Dialogflow.V2.Model.GoogleRpcStatus)
4246
field(:newMessagePayload, as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1Message)
47+
48+
field(:newRecognitionResultPayload,
49+
as: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1StreamingRecognitionResult
50+
)
51+
4352
field(:type)
4453
end
4554

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1SpeechWordInfo do
19+
@moduledoc """
20+
Information for a word recognized by the speech recognizer.
21+
22+
## Attributes
23+
24+
* `confidence` (*type:* `number()`, *default:* `nil`) - The Speech confidence between 0.0 and 1.0 for this word. A higher number indicates an estimated greater likelihood that the recognized word is correct. The default of 0.0 is a sentinel value indicating that confidence was not set. This field is not guaranteed to be fully stable over time for the same audio input. Users should also not rely on it to always be provided.
25+
* `endOffset` (*type:* `String.t`, *default:* `nil`) - Time offset relative to the beginning of the audio that corresponds to the end of the spoken word. This is an experimental feature and the accuracy of the time offset can vary.
26+
* `startOffset` (*type:* `String.t`, *default:* `nil`) - Time offset relative to the beginning of the audio that corresponds to the start of the spoken word. This is an experimental feature and the accuracy of the time offset can vary.
27+
* `word` (*type:* `String.t`, *default:* `nil`) - The word this info is for.
28+
"""
29+
30+
use GoogleApi.Gax.ModelBase
31+
32+
@type t :: %__MODULE__{
33+
:confidence => number() | nil,
34+
:endOffset => String.t() | nil,
35+
:startOffset => String.t() | nil,
36+
:word => String.t() | nil
37+
}
38+
39+
field(:confidence)
40+
field(:endOffset)
41+
field(:startOffset)
42+
field(:word)
43+
end
44+
45+
defimpl Poison.Decoder,
46+
for: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1SpeechWordInfo do
47+
def decode(value, options) do
48+
GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1SpeechWordInfo.decode(
49+
value,
50+
options
51+
)
52+
end
53+
end
54+
55+
defimpl Poison.Encoder,
56+
for: GoogleApi.Dialogflow.V2.Model.GoogleCloudDialogflowV2beta1SpeechWordInfo do
57+
def encode(value, options) do
58+
GoogleApi.Gax.ModelBase.encode(value, options)
59+
end
60+
end

0 commit comments

Comments
 (0)