aws_sdk_pinpointsmsvoicev2/lib.rs
1#![allow(deprecated)]
2#![allow(unknown_lints)]
3#![allow(clippy::module_inception)]
4#![allow(clippy::upper_case_acronyms)]
5#![allow(clippy::large_enum_variant)]
6#![allow(clippy::wrong_self_convention)]
7#![allow(clippy::should_implement_trait)]
8#![allow(clippy::disallowed_names)]
9#![allow(clippy::vec_init_then_push)]
10#![allow(clippy::type_complexity)]
11#![allow(clippy::needless_return)]
12#![allow(clippy::derive_partial_eq_without_eq)]
13#![allow(clippy::result_large_err)]
14#![allow(clippy::unnecessary_map_on_constructor)]
15#![allow(clippy::deprecated_semver)]
16#![allow(rustdoc::bare_urls)]
17#![allow(rustdoc::redundant_explicit_links)]
18#![allow(rustdoc::invalid_html_tags)]
19#![forbid(unsafe_code)]
20#![warn(missing_docs)]
21#![cfg_attr(docsrs, feature(doc_cfg))]
22//! Welcome to the _AWS End User Messaging SMS and Voice, version 2 API Reference_. This guide provides information about AWS End User Messaging SMS and Voice, version 2 API resources, including supported HTTP methods, parameters, and schemas.
23//!
24//! Amazon Pinpoint is an Amazon Web Services service that you can use to engage with your recipients across multiple messaging channels. The AWS End User Messaging SMS and Voice, version 2 API provides programmatic access to options that are unique to the SMS and voice channels. AWS End User Messaging SMS and Voice, version 2 resources such as phone numbers, sender IDs, and opt-out lists can be used by the Amazon Pinpoint API.
25//!
26//! If you're new to AWS End User Messaging SMS and Voice, it's also helpful to review the [AWS End User Messaging SMS User Guide](https://docs.aws.amazon.com/sms-voice/latest/userguide/what-is-service.html). The _AWS End User Messaging SMS User Guide _ provides tutorials, code samples, and procedures that demonstrate how to use AWS End User Messaging SMS and Voice features programmatically and how to integrate functionality into mobile apps and other types of applications. The guide also provides key information, such as AWS End User Messaging SMS and Voice integration with other Amazon Web Services services, and the quotas that apply to use of the service.
27//!
28//! __Regional availability__
29//!
30//! The _AWS End User Messaging SMS and Voice version 2 API Reference_ is available in several Amazon Web Services Regions and it provides an endpoint for each of these Regions. For a list of all the Regions and endpoints where the API is currently available, see [Amazon Web Services Service Endpoints](https://docs.aws.amazon.com/general/latest/gr/rande.html#pinpoint_region) and [Amazon Pinpoint endpoints and quotas](https://docs.aws.amazon.com/general/latest/gr/pinpoint.html) in the Amazon Web Services General Reference. To learn more about Amazon Web Services Regions, see [Managing Amazon Web Services Regions](https://docs.aws.amazon.com/general/latest/gr/rande-manage.html) in the Amazon Web Services General Reference.
31//!
32//! In each Region, Amazon Web Services maintains multiple Availability Zones. These Availability Zones are physically isolated from each other, but are united by private, low-latency, high-throughput, and highly redundant network connections. These Availability Zones enable us to provide very high levels of availability and redundancy, while also minimizing latency. To learn more about the number of Availability Zones that are available in each Region, see [Amazon Web Services Global Infrastructure.](https://aws.amazon.com/about-aws/global-infrastructure/)
33//!
34//! ## Getting Started
35//!
36//! > Examples are available for many services and operations, check out the
37//! > [usage examples](https://github.com/awsdocs/aws-doc-sdk-examples/tree/main/rustv1).
38//!
39//! The SDK provides one crate per AWS service. You must add [Tokio](https://crates.io/crates/tokio)
40//! as a dependency within your Rust project to execute asynchronous code. To add `aws-sdk-pinpointsmsvoicev2` to
41//! your project, add the following to your **Cargo.toml** file:
42//!
43//! ```toml
44//! [dependencies]
45//! aws-config = { version = "1.1.7", features = ["behavior-version-latest"] }
46//! aws-sdk-pinpointsmsvoicev2 = "1.93.0"
47//! tokio = { version = "1", features = ["full"] }
48//! ```
49//!
50//! Then in code, a client can be created with the following:
51//!
52//! ```rust,no_run
53//! use aws_sdk_pinpointsmsvoicev2 as pinpointsmsvoicev2;
54//!
55//! #[::tokio::main]
56//! async fn main() -> Result<(), pinpointsmsvoicev2::Error> {
57//! let config = aws_config::load_from_env().await;
58//! let client = aws_sdk_pinpointsmsvoicev2::Client::new(&config);
59//!
60//! // ... make some calls with the client
61//!
62//! Ok(())
63//! }
64//! ```
65//!
66//! See the [client documentation](https://docs.rs/aws-sdk-pinpointsmsvoicev2/latest/aws_sdk_pinpointsmsvoicev2/client/struct.Client.html)
67//! for information on what calls can be made, and the inputs and outputs for each of those calls.
68//!
69//! ## Using the SDK
70//!
71//! Until the SDK is released, we will be adding information about using the SDK to the
72//! [Developer Guide](https://docs.aws.amazon.com/sdk-for-rust/latest/dg/welcome.html). Feel free to suggest
73//! additional sections for the guide by opening an issue and describing what you are trying to do.
74//!
75//! ## Getting Help
76//!
77//! * [GitHub discussions](https://github.com/awslabs/aws-sdk-rust/discussions) - For ideas, RFCs & general questions
78//! * [GitHub issues](https://github.com/awslabs/aws-sdk-rust/issues/new/choose) - For bug reports & feature requests
79//! * [Generated Docs (latest version)](https://awslabs.github.io/aws-sdk-rust/)
80//! * [Usage examples](https://github.com/awsdocs/aws-doc-sdk-examples/tree/main/rustv1)
81//!
82//!
83//! # Crate Organization
84//!
85//! The entry point for most customers will be [`Client`], which exposes one method for each API
86//! offered by Amazon Pinpoint SMS Voice V2. The return value of each of these methods is a "fluent builder",
87//! where the different inputs for that API are added by builder-style function call chaining,
88//! followed by calling `send()` to get a [`Future`](std::future::Future) that will result in
89//! either a successful output or a [`SdkError`](crate::error::SdkError).
90//!
91//! Some of these API inputs may be structs or enums to provide more complex structured information.
92//! These structs and enums live in [`types`](crate::types). There are some simpler types for
93//! representing data such as date times or binary blobs that live in [`primitives`](crate::primitives).
94//!
95//! All types required to configure a client via the [`Config`](crate::Config) struct live
96//! in [`config`](crate::config).
97//!
98//! The [`operation`](crate::operation) module has a submodule for every API, and in each submodule
99//! is the input, output, and error type for that API, as well as builders to construct each of those.
100//!
101//! There is a top-level [`Error`](crate::Error) type that encompasses all the errors that the
102//! client can return. Any other error type can be converted to this `Error` type via the
103//! [`From`](std::convert::From) trait.
104//!
105//! The other modules within this crate are not required for normal usage.
106
107// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
108pub use error_meta::Error;
109
110#[doc(inline)]
111pub use config::Config;
112
113/// Client for calling Amazon Pinpoint SMS Voice V2.
114/// ## Constructing a `Client`
115///
116/// A [`Config`] is required to construct a client. For most use cases, the [`aws-config`]
117/// crate should be used to automatically resolve this config using
118/// [`aws_config::load_from_env()`], since this will resolve an [`SdkConfig`] which can be shared
119/// across multiple different AWS SDK clients. This config resolution process can be customized
120/// by calling [`aws_config::from_env()`] instead, which returns a [`ConfigLoader`] that uses
121/// the [builder pattern] to customize the default config.
122///
123/// In the simplest case, creating a client looks as follows:
124/// ```rust,no_run
125/// # async fn wrapper() {
126/// let config = aws_config::load_from_env().await;
127/// let client = aws_sdk_pinpointsmsvoicev2::Client::new(&config);
128/// # }
129/// ```
130///
131/// Occasionally, SDKs may have additional service-specific values that can be set on the [`Config`] that
132/// is absent from [`SdkConfig`], or slightly different settings for a specific client may be desired.
133/// The [`Builder`](crate::config::Builder) struct implements `From<&SdkConfig>`, so setting these specific settings can be
134/// done as follows:
135///
136/// ```rust,no_run
137/// # async fn wrapper() {
138/// let sdk_config = ::aws_config::load_from_env().await;
139/// let config = aws_sdk_pinpointsmsvoicev2::config::Builder::from(&sdk_config)
140/// # /*
141/// .some_service_specific_setting("value")
142/// # */
143/// .build();
144/// # }
145/// ```
146///
147/// See the [`aws-config` docs] and [`Config`] for more information on customizing configuration.
148///
149/// _Note:_ Client construction is expensive due to connection thread pool initialization, and should
150/// be done once at application start-up.
151///
152/// [`Config`]: crate::Config
153/// [`ConfigLoader`]: https://docs.rs/aws-config/*/aws_config/struct.ConfigLoader.html
154/// [`SdkConfig`]: https://docs.rs/aws-config/*/aws_config/struct.SdkConfig.html
155/// [`aws-config` docs]: https://docs.rs/aws-config/*
156/// [`aws-config`]: https://crates.io/crates/aws-config
157/// [`aws_config::from_env()`]: https://docs.rs/aws-config/*/aws_config/fn.from_env.html
158/// [`aws_config::load_from_env()`]: https://docs.rs/aws-config/*/aws_config/fn.load_from_env.html
159/// [builder pattern]: https://rust-lang.github.io/api-guidelines/type-safety.html#builders-enable-construction-of-complex-values-c-builder
160/// # Using the `Client`
161///
162/// A client has a function for every operation that can be performed by the service.
163/// For example, the [`AssociateOriginationIdentity`](crate::operation::associate_origination_identity) operation has
164/// a [`Client::associate_origination_identity`], function which returns a builder for that operation.
165/// The fluent builder ultimately has a `send()` function that returns an async future that
166/// returns a result, as illustrated below:
167///
168/// ```rust,ignore
169/// let result = client.associate_origination_identity()
170/// .pool_id("example")
171/// .send()
172/// .await;
173/// ```
174///
175/// The underlying HTTP requests that get made by this can be modified with the `customize_operation`
176/// function on the fluent builder. See the [`customize`](crate::client::customize) module for more
177/// information.
178pub mod client;
179
180/// Configuration for Amazon Pinpoint SMS Voice V2.
181pub mod config;
182
183/// Common errors and error handling utilities.
184pub mod error;
185
186mod error_meta;
187
188/// Information about this crate.
189pub mod meta;
190
191/// All operations that this crate can perform.
192pub mod operation;
193
194/// Primitives such as `Blob` or `DateTime` used by other types.
195pub mod primitives;
196
197/// Data structures used by operation inputs/outputs.
198pub mod types;
199
200pub(crate) mod client_idempotency_token;
201
202mod idempotency_token;
203
204pub(crate) mod protocol_serde;
205
206mod sdk_feature_tracker;
207
208mod serialization_settings;
209
210mod endpoint_lib;
211
212mod lens;
213
214mod serde_util;
215
216mod json_errors;
217
218#[doc(inline)]
219pub use client::Client;