googleapis/swift-google-cloud-dialogflow-cx-v3
Builds conversational interfaces (for example, chatbots, and voice-powered
Overview
The following types provide methods to make RPCs. They are a good starting point to learn about this library.
AgentsClient: Service for managing Agents. (enabled by theAgentstrait)ChangelogsClient: Service for managing Changelogs. (enabled by theChangelogstrait)DeploymentsClient: Service for managing Deployments. (enabled by theDeploymentstrait)EntityTypesClient: Service for managing EntityTypes. (enabled by theEntityTypestrait)EnvironmentsClient: Service for managing Environments. (enabled by theEnvironmentstrait)ExamplesClient: Service for managing Examples. (enabled by theExamplestrait)ExperimentsClient: Service for managing Experiments. (enabled by theExperimentstrait)FlowsClient: Service for managing Flows. (enabled by theFlowstrait)GeneratorsClient: Service for managing Generators. (enabled by theGeneratorstrait)IntentsClient: Service for managing Intents. (enabled by theIntentstrait)PagesClient: Service for managing Pages. (enabled by thePagestrait)PlaybooksClient: Service for managing Playbooks. (enabled by thePlaybookstrait)SecuritySettingsServiceClient: Service for managing security settings for Dialogflow. (enabled by theSecuritySettingsServicetrait)SessionsClient: A session represents an interaction with a user. (enabled by theSessionstrait)SessionEntityTypesClient: Service for managing SessionEntityTypes. (enabled by theSessionEntityTypestrait)TestCasesClient: Service for managing Test Cases and Test Case Results. (enabled by theTestCasestrait)ToolsClient: Service for managing Tools. (enabled by theToolstrait)TransitionRouteGroupsClient: Service for managing TransitionRouteGroups. (enabled by theTransitionRouteGroupstrait)VersionsClient: Service for managing Versions. (enabled by theVersionstrait)WebhooksClient: Service for managing Webhooks. (enabled by theWebhookstrait)
Quickstart
The following example demonstrates using AgentsClient:
import Foundation
import GoogleCloudDialogflowCXV3
import GoogleCloudLocation
import GoogleLongRunning
import GoogleWKT
func sample(projectId: String, locationId: String, ) async throws {
let client = try GoogleCloudDialogflowCXV3.AgentsClient()
let items = client.listAgentsByItems(
request: ListAgentsRequest()
.with {
$0.parent = "projects/\(projectId)/locations/\(locationId)"
}
)
for try await item in items {
print(" \(item)")
}
}Requirements
For the minimum supported Swift version and platform requirements, see the Requirements section in the google-cloud-swift repository.
Installation
Add swift-google-cloud-dialogflow-cx-v3 as a package dependency:
swift package add-dependency https://github.com/googleapis/swift-google-cloud-dialogflow-cx-v3.git --from 0.6.0Then add GoogleCloudDialogflowCXV3 to your target's dependencies:
swift package add-target-dependency GoogleCloudDialogflowCXV3 <target-name> --package swift-google-cloud-dialogflow-cx-v3Package Traits
This package uses Swift package traits to conditionally compile individual service clients and their associated types. Enabling a trait enables the corresponding client and all the request, response, and model types needed to use that client.
The following traits are enabled by default:
Agents
To enable additional traits alongside the defaults, specify them in Package.swift:
.package(url: "https://github.com/googleapis/swift-google-cloud-dialogflow-cx-v3.git", from: "0.6.0", traits: [".defaults", "<TraitName>"])| Trait | Default | Enabled Client | |---|:---:|---| | Agents | Yes | AgentsClient | | Changelogs | No | ChangelogsClient | | Deployments | No | DeploymentsClient | | EntityTypes | No | EntityTypesClient | | Environments | No | EnvironmentsClient | | Examples | No | ExamplesClient | | Experiments | No | ExperimentsClient | | Flows | No | FlowsClient | | Generators | No | GeneratorsClient | | Intents | No | IntentsClient | | Pages | No | PagesClient | | Playbooks | No | PlaybooksClient | | SecuritySettingsService | No | SecuritySettingsServiceClient | | SessionEntityTypes | No | SessionEntityTypesClient | | Sessions | No | SessionsClient | | TestCases | No | TestCasesClient | | Tools | No | ToolsClient | | TransitionRouteGroups | No | TransitionRouteGroupsClient | | Versions | No | VersionsClient | | Webhooks | No | WebhooksClient |
Troubleshooting
For questions, bug reports, or feature requests, please open an issue in the google-cloud-swift repository.
Contributing
Contributions to this library are always welcome and highly encouraged.
All development, issues, and pull requests are managed in the google-cloud-swift monorepo. See CONTRIBUTING.md for details on getting started.
License
Apache 2.0 - See LICENSE for more information.
Package Metadata
Repository: googleapis/swift-google-cloud-dialogflow-cx-v3
Default branch: main
README: README.md