Files
google-apis-rs/gen/cloudchannel1/src/api/utilities.rs
2024-05-16 21:23:40 +02:00

29 lines
776 B
Rust

use super::*;
/// Identifies the an OAuth2 authorization scope.
/// A scope is needed when requesting an
/// [authorization token](https://developers.google.com/youtube/v3/guides/authentication).
#[derive(PartialEq, Eq, Hash, Debug, Clone)]
pub enum Scope {
/// Manage users on your domain
AppOrder,
/// View usage reports for your G Suite domain
AppReportUsageReadonly,
}
impl AsRef<str> for Scope {
fn as_ref(&self) -> &str {
match *self {
Scope::AppOrder => "https://www.googleapis.com/auth/apps.order",
Scope::AppReportUsageReadonly => "https://www.googleapis.com/auth/apps.reports.usage.readonly",
}
}
}
impl Default for Scope {
fn default() -> Scope {
Scope::AppReportUsageReadonly
}
}