// Code generated by sidekick. DO NOT EDIT.
//
// Copyright 2026 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
//
//     https://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.

#if Conversations || Participants
  import Foundation
  import GoogleCloudWkt

  /// Represents the parameters of human assist query.
  public struct AssistQueryParameters: Codable, Equatable, GoogleCloudWkt._AnyPackable,
    Sendable
  {
    /// Key-value filters on the metadata of documents returned by article
    /// suggestion. If specified, article suggestion only returns suggested
    /// documents that match all filters in their
    /// [Document.metadata][google.cloud.dialogflow.v2.Document.metadata]. Multiple
    /// values for a metadata key should be concatenated by comma. For example,
    /// filters to match all documents that have 'US' or 'CA' in their market
    /// metadata values and 'agent' in their user metadata values will be
    /// ```
    /// documents_metadata_filters {
    ///   key: "market"
    ///   value: "US,CA"
    /// }
    /// documents_metadata_filters {
    ///   key: "user"
    ///   value: "agent"
    /// }
    /// ```
    ///
    /// [google.cloud.dialogflow.v2.Document.metadata]: <doc:Document/metadata>
    public var documentsMetadataFilters: [Swift.String: Swift.String] = [:]

    /// Initialize a new instance of `AssistQueryParameters`.
    public init() {}

    /// Use `config` to return a new instance of this object, with some fields updated.
    ///
    /// Commonly used to initialize the value, for example:
    ///
    /// ```
    /// let value = AssistQueryParameters().with { $0.documentsMetadataFilters = ... }
    /// ```
    public func with(_ config: (inout Self) throws -> Swift.Void) rethrows -> Self {
      var copy = self
      try config(&copy)
      return copy
    }

    public static var _anyTypeUrl: Swift.String {
      return "type.googleapis.com/google.cloud.dialogflow.v2.AssistQueryParameters"
    }
    public init(fromAny any: GoogleCloudWkt.`Any`) throws {
      self = try GoogleCloudWkt._slowAnyDeserialize(Self.self, from: any)
    }
    public func _pack() throws -> GoogleCloudWkt.Struct {
      return try GoogleCloudWkt._slowAnySerialize(message: self)
    }
  }
#endif
