aws_sdk_grafana/client/
create_workspace_service_account.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`CreateWorkspaceServiceAccount`](crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`name(impl Into<String>)`](crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder::name) / [`set_name(Option<String>)`](crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder::set_name):<br>required: **true**<br><p>A name for the service account. The name must be unique within the workspace, as it determines the ID associated with the service account.</p><br>
7    ///   - [`grafana_role(Role)`](crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder::grafana_role) / [`set_grafana_role(Option<Role>)`](crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder::set_grafana_role):<br>required: **true**<br><p>The permission level to use for this service account.</p><note>  <p>For more information about the roles and the permissions each has, see <a href="https://docs.aws.amazon.com/grafana/latest/userguide/Grafana-user-roles.html">User roles</a> in the <i>Amazon Managed Grafana User Guide</i>.</p> </note><br>
8    ///   - [`workspace_id(impl Into<String>)`](crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder::workspace_id) / [`set_workspace_id(Option<String>)`](crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder::set_workspace_id):<br>required: **true**<br><p>The ID of the workspace within which to create the service account.</p><br>
9    /// - On success, responds with [`CreateWorkspaceServiceAccountOutput`](crate::operation::create_workspace_service_account::CreateWorkspaceServiceAccountOutput) with field(s):
10    ///   - [`id(String)`](crate::operation::create_workspace_service_account::CreateWorkspaceServiceAccountOutput::id): <p>The ID of the service account.</p>
11    ///   - [`name(String)`](crate::operation::create_workspace_service_account::CreateWorkspaceServiceAccountOutput::name): <p>The name of the service account.</p>
12    ///   - [`grafana_role(Role)`](crate::operation::create_workspace_service_account::CreateWorkspaceServiceAccountOutput::grafana_role): <p>The permission level given to the service account.</p>
13    ///   - [`workspace_id(String)`](crate::operation::create_workspace_service_account::CreateWorkspaceServiceAccountOutput::workspace_id): <p>The workspace with which the service account is associated.</p>
14    /// - On failure, responds with [`SdkError<CreateWorkspaceServiceAccountError>`](crate::operation::create_workspace_service_account::CreateWorkspaceServiceAccountError)
15    pub fn create_workspace_service_account(
16        &self,
17    ) -> crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder {
18        crate::operation::create_workspace_service_account::builders::CreateWorkspaceServiceAccountFluentBuilder::new(self.handle.clone())
19    }
20}