dropbox_sdk/generated/sync_routes/
check.rs

1// DO NOT EDIT
2// This file was @generated by Stone
3
4#![allow(
5    clippy::too_many_arguments,
6    clippy::large_enum_variant,
7    clippy::result_large_err,
8    clippy::doc_markdown,
9)]
10
11#[allow(unused_imports)]
12pub use crate::generated::types::check::*;
13
14/// This endpoint performs App Authentication, validating the supplied app key and secret, and
15/// returns the supplied string, to allow you to test your code and connection to the Dropbox API.
16/// It has no other effect. If you receive an HTTP 200 response with the supplied query, it
17/// indicates at least part of the Dropbox API infrastructure is working and that the app key and
18/// secret valid.
19///
20/// # Stability
21/// *PREVIEW*: This function may change or disappear without notice.
22#[cfg(feature = "unstable")]
23#[cfg_attr(docsrs, doc(cfg(feature = "unstable")))]
24pub fn app(
25    client: &impl crate::client_trait::AppAuthClient,
26    arg: &EchoArg,
27) -> Result<EchoResult, crate::Error<crate::NoError>> {
28    crate::client_helpers::unwrap_async(
29        crate::client_helpers::request(
30            client,
31            crate::client_trait_common::Endpoint::Api,
32            crate::client_trait_common::Style::Rpc,
33            "check/app",
34            arg,
35            None)
36    )
37}
38
39/// This endpoint performs User Authentication, validating the supplied access token, and returns
40/// the supplied string, to allow you to test your code and connection to the Dropbox API. It has no
41/// other effect. If you receive an HTTP 200 response with the supplied query, it indicates at least
42/// part of the Dropbox API infrastructure is working and that the access token is valid.
43///
44/// # Stability
45/// *PREVIEW*: This function may change or disappear without notice.
46#[cfg(feature = "unstable")]
47#[cfg_attr(docsrs, doc(cfg(feature = "unstable")))]
48pub fn user(
49    client: &impl crate::client_trait::UserAuthClient,
50    arg: &EchoArg,
51) -> Result<EchoResult, crate::Error<crate::NoError>> {
52    crate::client_helpers::unwrap_async(
53        crate::client_helpers::request(
54            client,
55            crate::client_trait_common::Endpoint::Api,
56            crate::client_trait_common::Style::Rpc,
57            "check/user",
58            arg,
59            None)
60    )
61}
62