We announced the upcoming end-of-support for AWS SDK for JavaScript v2.
We recommend that you migrate to AWS SDK for JavaScript v3. For dates, additional details, and information on how to migrate, please refer to the linked announcement.

Class: AWS.Grafana

Inherits:
AWS.Service show all
Identifier:
grafana
API Version:
2020-08-18
Defined in:
(unknown)

Overview

Constructs a service interface object. Each API operation is exposed as a function on service.

Service Description

Amazon Managed Grafana is a fully managed and secure data visualization service that you can use to instantly query, correlate, and visualize operational metrics, logs, and traces from multiple sources. Amazon Managed Grafana makes it easy to deploy, operate, and scale Grafana, a widely deployed data visualization tool that is popular for its extensible data support.

With Amazon Managed Grafana, you create logically isolated Grafana servers called workspaces. In a workspace, you can create Grafana dashboards and visualizations to analyze your metrics, logs, and traces without having to build, package, or deploy any hardware to run Grafana servers.

Sending a Request Using Grafana

var grafana = new AWS.Grafana();
grafana.associateLicense(params, function (err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Locking the API Version

In order to ensure that the Grafana object uses this specific API, you can construct the object by passing the apiVersion option to the constructor:

var grafana = new AWS.Grafana({apiVersion: '2020-08-18'});

You can also set the API version globally in AWS.config.apiVersions using the grafana service identifier:

AWS.config.apiVersions = {
  grafana: '2020-08-18',
  // other service API versions
};

var grafana = new AWS.Grafana();

Version:

  • 2020-08-18

Constructor Summary collapse

Property Summary collapse

Properties inherited from AWS.Service

apiVersions

Method Summary collapse

Methods inherited from AWS.Service

makeRequest, makeUnauthenticatedRequest, waitFor, setupRequestListeners, defineService

Constructor Details

new AWS.Grafana(options = {}) ⇒ Object

Constructs a service object. This object has one method for each API operation.

Examples:

Constructing a Grafana object

var grafana = new AWS.Grafana({apiVersion: '2020-08-18'});

Options Hash (options):

  • params (map)

    An optional map of parameters to bind to every request sent by this service object. For more information on bound parameters, see "Working with Services" in the Getting Started Guide.

  • endpoint (String|AWS.Endpoint)

    The endpoint URI to send requests to. The default endpoint is built from the configured region. The endpoint should be a string like 'https://{service}.{region}.amazonaws.com' or an Endpoint object.

  • accessKeyId (String)

    your AWS access key ID.

  • secretAccessKey (String)

    your AWS secret access key.

  • sessionToken (AWS.Credentials)

    the optional AWS session token to sign requests with.

  • credentials (AWS.Credentials)

    the AWS credentials to sign requests with. You can either specify this object, or specify the accessKeyId and secretAccessKey options directly.

  • credentialProvider (AWS.CredentialProviderChain)

    the provider chain used to resolve credentials if no static credentials property is set.

  • region (String)

    the region to send service requests to. See AWS.Grafana.region for more information.

  • maxRetries (Integer)

    the maximum amount of retries to attempt with a request. See AWS.Grafana.maxRetries for more information.

  • maxRedirects (Integer)

    the maximum amount of redirects to follow with a request. See AWS.Grafana.maxRedirects for more information.

  • sslEnabled (Boolean)

    whether to enable SSL for requests.

  • paramValidation (Boolean|map)

    whether input parameters should be validated against the operation description before sending the request. Defaults to true. Pass a map to enable any of the following specific validation features:

    • min [Boolean] — Validates that a value meets the min constraint. This is enabled by default when paramValidation is set to true.
    • max [Boolean] — Validates that a value meets the max constraint.
    • pattern [Boolean] — Validates that a string value matches a regular expression.
    • enum [Boolean] — Validates that a string value matches one of the allowable enum values.
  • computeChecksums (Boolean)

    whether to compute checksums for payload bodies when the service accepts it (currently supported in S3 only)

  • convertResponseTypes (Boolean)

    whether types are converted when parsing response data. Currently only supported for JSON based services. Turning this off may improve performance on large response payloads. Defaults to true.

  • correctClockSkew (Boolean)

    whether to apply a clock skew correction and retry requests that fail because of an skewed client clock. Defaults to false.

  • s3ForcePathStyle (Boolean)

    whether to force path style URLs for S3 objects.

  • s3BucketEndpoint (Boolean)

    whether the provided endpoint addresses an individual bucket (false if it addresses the root API endpoint). Note that setting this configuration option requires an endpoint to be provided explicitly to the service constructor.

  • s3DisableBodySigning (Boolean)

    whether S3 body signing should be disabled when using signature version v4. Body signing can only be disabled when using https. Defaults to true.

  • s3UsEast1RegionalEndpoint ('legacy'|'regional')

    when region is set to 'us-east-1', whether to send s3 request to global endpoints or 'us-east-1' regional endpoints. This config is only applicable to S3 client. Defaults to legacy

  • s3UseArnRegion (Boolean)

    whether to override the request region with the region inferred from requested resource's ARN. Only available for S3 buckets Defaults to true

  • retryDelayOptions (map)

    A set of options to configure the retry delay on retryable errors. Currently supported options are:

    • base [Integer] — The base number of milliseconds to use in the exponential backoff for operation retries. Defaults to 100 ms for all services except DynamoDB, where it defaults to 50ms.
    • customBackoff [function] — A custom function that accepts a retry count and error and returns the amount of time to delay in milliseconds. If the result is a non-zero negative value, no further retry attempts will be made. The base option will be ignored if this option is supplied. The function is only called for retryable errors.
  • httpOptions (map)

    A set of options to pass to the low-level HTTP request. Currently supported options are:

    • proxy [String] — the URL to proxy requests through
    • agent [http.Agent, https.Agent] — the Agent object to perform HTTP requests with. Used for connection pooling. Defaults to the global agent (http.globalAgent) for non-SSL connections. Note that for SSL connections, a special Agent object is used in order to enable peer certificate verification. This feature is only available in the Node.js environment.
    • connectTimeout [Integer] — Sets the socket to timeout after failing to establish a connection with the server after connectTimeout milliseconds. This timeout has no effect once a socket connection has been established.
    • timeout [Integer] — Sets the socket to timeout after timeout milliseconds of inactivity on the socket. Defaults to two minutes (120000).
    • xhrAsync [Boolean] — Whether the SDK will send asynchronous HTTP requests. Used in the browser environment only. Set to false to send requests synchronously. Defaults to true (async on).
    • xhrWithCredentials [Boolean] — Sets the "withCredentials" property of an XMLHttpRequest object. Used in the browser environment only. Defaults to false.
  • apiVersion (String, Date)

    a String in YYYY-MM-DD format (or a date) that represents the latest possible API version that can be used in all services (unless overridden by apiVersions). Specify 'latest' to use the latest possible version.

  • apiVersions (map<String, String|Date>)

    a map of service identifiers (the lowercase service class name) with the API version to use when instantiating a service. Specify 'latest' for each individual that can use the latest available version.

  • logger (#write, #log)

    an object that responds to .write() (like a stream) or .log() (like the console object) in order to log information about requests

  • systemClockOffset (Number)

    an offset value in milliseconds to apply to all signing times. Use this to compensate for clock skew when your system may be out of sync with the service time. Note that this configuration option can only be applied to the global AWS.config object and cannot be overridden in service-specific configuration. Defaults to 0 milliseconds.

  • signatureVersion (String)

    the signature version to sign requests with (overriding the API configuration). Possible values are: 'v2', 'v3', 'v4'.

  • signatureCache (Boolean)

    whether the signature to sign requests with (overriding the API configuration) is cached. Only applies to the signature version 'v4'. Defaults to true.

  • dynamoDbCrc32 (Boolean)

    whether to validate the CRC32 checksum of HTTP response bodies returned by DynamoDB. Default: true.

  • useAccelerateEndpoint (Boolean)

    Whether to use the S3 Transfer Acceleration endpoint with the S3 service. Default: false.

  • clientSideMonitoring (Boolean)

    whether to collect and publish this client's performance metrics of all its API requests.

  • endpointDiscoveryEnabled (Boolean|undefined)

    whether to call operations with endpoints given by service dynamically. Setting this

  • endpointCacheSize (Number)

    the size of the global cache storing endpoints from endpoint discovery operations. Once endpoint cache is created, updating this setting cannot change existing cache size. Defaults to 1000

  • hostPrefixEnabled (Boolean)

    whether to marshal request parameters to the prefix of hostname. Defaults to true.

  • stsRegionalEndpoints ('legacy'|'regional')

    whether to send sts request to global endpoints or regional endpoints. Defaults to 'legacy'.

  • useFipsEndpoint (Boolean)

    Enables FIPS compatible endpoints. Defaults to false.

  • useDualstackEndpoint (Boolean)

    Enables IPv6 dualstack endpoint. Defaults to false.

Property Details

endpointAWS.Endpoint (readwrite)

Returns an Endpoint object representing the endpoint URL for service requests.

Returns:

  • (AWS.Endpoint)

    an Endpoint object representing the endpoint URL for service requests.

Method Details

associateLicense(params = {}, callback) ⇒ AWS.Request

Assigns a Grafana Enterprise license to a workspace. To upgrade, you must use ENTERPRISE for the licenseType, and pass in a valid Grafana Labs token for the grafanaToken. Upgrading to Grafana Enterprise incurs additional fees. For more information, see Upgrade a workspace to Grafana Enterprise.

Service Reference:

Examples:

Calling the associateLicense operation

var params = {
  licenseType: ENTERPRISE | ENTERPRISE_FREE_TRIAL, /* required */
  workspaceId: 'STRING_VALUE', /* required */
  grafanaToken: 'STRING_VALUE'
};
grafana.associateLicense(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • grafanaToken — (String)

      A token from Grafana Labs that ties your Amazon Web Services account with a Grafana Labs account. For more information, see Link your account with Grafana Labs.

    • licenseType — (String)

      The type of license to associate with the workspace.

      Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
      Possible values include:
      • "ENTERPRISE"
      • "ENTERPRISE_FREE_TRIAL"
    • workspaceId — (String)

      The ID of the workspace to associate the license with.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • workspace — (map)

        A structure containing data about the workspace.

        • accountAccessType — (String)

          Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which organizational units the workspace can access.

          Possible values include:
          • "CURRENT_ACCOUNT"
          • "ORGANIZATION"
        • authenticationrequired — (map)

          A structure that describes whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • providersrequired — (Array<String>)

            Specifies whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • samlConfigurationStatus — (String)

            Specifies whether the workplace's user authentication method is fully configured.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"
        • createdrequired — (Date)

          The date that the workspace was created.

        • dataSourcesrequired — (Array<String>)

          Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources.

          This list is only used when the workspace was created through the Amazon Web Services console, and the permissionType is SERVICE_MANAGED.

        • description — (String)

          The user-defined description of the workspace.

        • endpointrequired — (String)

          The URL that users can use to access the Grafana console in the workspace.

        • freeTrialConsumed — (Boolean)

          Specifies whether this workspace has already fully used its free trial for Grafana Enterprise.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • freeTrialExpiration — (Date)

          If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when that free trial ends.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • grafanaToken — (String)

          The token that ties this workspace to a Grafana Labs account. For more information, see Link your account with Grafana Labs.

        • grafanaVersionrequired — (String)

          The version of Grafana supported in this workspace.

        • idrequired — (String)

          The unique ID of this workspace.

        • licenseExpiration — (Date)

          If this workspace has a full Grafana Enterprise license purchased through Amazon Web Services Marketplace, this specifies when the license ends and will need to be renewed. Purchasing the Enterprise plugins option through Amazon Managed Grafana does not have an expiration. It is valid until the license is removed.

        • licenseType — (String)

          Specifies whether this workspace has a full Grafana Enterprise license.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
          Possible values include:
          • "ENTERPRISE"
          • "ENTERPRISE_FREE_TRIAL"
        • modifiedrequired — (Date)

          The most recent date that the workspace was modified.

        • name — (String)

          The name of the workspace.

        • networkAccessControl — (map)

          The configuration settings for network access to your workspace.

          • prefixListIdsrequired — (Array<String>)

            An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

            Prefix list IDs have the format pl-1a2b3c4d .

            For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

          • vpceIdsrequired — (Array<String>)

            An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

            VPC endpoint IDs have the format vpce-1a2b3c4d .

            For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

            Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
        • notificationDestinations — (Array<String>)

          The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

        • organizationRoleName — (String)

          The name of the IAM role that is used to access resources through Organizations.

        • organizationalUnits — (Array<String>)

          Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

        • permissionType — (String)

          If this is SERVICE_MANAGED, and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification channels.

          If this is CUSTOMER_MANAGED, you must manage those roles and permissions yourself.

          If you are working with a workspace in a member account of an organization and that account is not a delegated administrator account, and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, this parameter must be set to CUSTOMER_MANAGED.

          For more information about converting between customer and service managed, see Managing permissions for data sources and notification channels. For more information about the roles and permissions that must be managed for customer managed workspaces, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels

          Possible values include:
          • "CUSTOMER_MANAGED"
          • "SERVICE_MANAGED"
        • stackSetName — (String)

          The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

        • statusrequired — (String)

          The current status of the workspace.

          Possible values include:
          • "ACTIVE"
          • "CREATING"
          • "DELETING"
          • "FAILED"
          • "UPDATING"
          • "UPGRADING"
          • "DELETION_FAILED"
          • "CREATION_FAILED"
          • "UPDATE_FAILED"
          • "UPGRADE_FAILED"
          • "LICENSE_REMOVAL_FAILED"
          • "VERSION_UPDATING"
          • "VERSION_UPDATE_FAILED"
        • tags — (map<String>)

          The list of tags associated with the workspace.

        • vpcConfiguration — (map)

          The configuration for connecting to data sources in a private VPC (Amazon Virtual Private Cloud).

          • securityGroupIdsrequired — (Array<String>)

            The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

          • subnetIdsrequired — (Array<String>)

            The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

        • workspaceRoleArn — (String)

          The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from. This role must already exist.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

createWorkspace(params = {}, callback) ⇒ AWS.Request

Creates a workspace. In a workspace, you can create Grafana dashboards and visualizations to analyze your metrics, logs, and traces. You don't have to build, package, or deploy any hardware to run the Grafana server.

Don't use CreateWorkspace to modify an existing workspace. Instead, use UpdateWorkspace.

Service Reference:

Examples:

Calling the createWorkspace operation

var params = {
  accountAccessType: CURRENT_ACCOUNT | ORGANIZATION, /* required */
  authenticationProviders: [ /* required */
    AWS_SSO | SAML,
    /* more items */
  ],
  permissionType: CUSTOMER_MANAGED | SERVICE_MANAGED, /* required */
  clientToken: 'STRING_VALUE',
  configuration: any /* This value will be JSON encoded on your behalf with JSON.stringify() */,
  grafanaVersion: 'STRING_VALUE',
  networkAccessControl: {
    prefixListIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ],
    vpceIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ]
  },
  organizationRoleName: 'STRING_VALUE',
  stackSetName: 'STRING_VALUE',
  tags: {
    '<TagKey>': 'STRING_VALUE',
    /* '<TagKey>': ... */
  },
  vpcConfiguration: {
    securityGroupIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ],
    subnetIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ]
  },
  workspaceDataSources: [
    AMAZON_OPENSEARCH_SERVICE | CLOUDWATCH | PROMETHEUS | XRAY | TIMESTREAM | SITEWISE | ATHENA | REDSHIFT | TWINMAKER,
    /* more items */
  ],
  workspaceDescription: 'STRING_VALUE',
  workspaceName: 'STRING_VALUE',
  workspaceNotificationDestinations: [
    SNS,
    /* more items */
  ],
  workspaceOrganizationalUnits: [
    'STRING_VALUE',
    /* more items */
  ],
  workspaceRoleArn: 'STRING_VALUE'
};
grafana.createWorkspace(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • accountAccessType — (String)

      Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If you specify ORGANIZATION, you must specify which organizational units the workspace can access in the workspaceOrganizationalUnits parameter.

      Possible values include:
      • "CURRENT_ACCOUNT"
      • "ORGANIZATION"
    • authenticationProviders — (Array<String>)

      Specifies whether this workspace uses SAML 2.0, IAM Identity Center, or both to authenticate users for using the Grafana console within a workspace. For more information, see User authentication in Amazon Managed Grafana.

    • clientToken — (String)

      A unique, case-sensitive, user-provided identifier to ensure the idempotency of the request.

      If a token is not provided, the SDK will use a version 4 UUID.
    • configuration — (String)

      The configuration string for the workspace that you create. For more information about the format and configuration options available, see Working in your Grafana workspace.

    • grafanaVersion — (String)

      Specifies the version of Grafana to support in the new workspace. If not specified, defaults to the latest version (for example, 10.4).

      To get a list of supported versions, use the ListVersions operation.

    • networkAccessControl — (map)

      Configuration for network access to your workspace.

      When this is configured, only listed IP addresses and VPC endpoints will be able to access your workspace. Standard Grafana authentication and authorization will still be required.

      If this is not configured, or is removed, then all IP addresses and VPC endpoints will be allowed. Standard Grafana authentication and authorization will still be required.

      • prefixListIdsrequired — (Array<String>)

        An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

        Prefix list IDs have the format pl-1a2b3c4d .

        For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

      • vpceIdsrequired — (Array<String>)

        An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

        VPC endpoint IDs have the format vpce-1a2b3c4d .

        For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

        Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
    • organizationRoleName — (String)

      The name of an IAM role that already exists to use with Organizations to access Amazon Web Services data sources and notification channels in other accounts in an organization.

    • permissionType — (String)

      When creating a workspace through the Amazon Web Services API, CLI or Amazon Web Services CloudFormation, you must manage IAM roles and provision the permissions that the workspace needs to use Amazon Web Services data sources and notification channels.

      You must also specify a workspaceRoleArn for a role that you will manage for the workspace to use when accessing those datasources and notification channels.

      The ability for Amazon Managed Grafana to create and update IAM roles on behalf of the user is supported only in the Amazon Managed Grafana console, where this value may be set to SERVICE_MANAGED.

      Note: Use only the CUSTOMER_MANAGED permission type when creating a workspace with the API, CLI or Amazon Web Services CloudFormation.

      For more information, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels.

      Possible values include:
      • "CUSTOMER_MANAGED"
      • "SERVICE_MANAGED"
    • stackSetName — (String)

      The name of the CloudFormation stack set to use to generate IAM roles to be used for this workspace.

    • tags — (map<String>)

      The list of tags associated with the workspace.

    • vpcConfiguration — (map)

      The configuration settings for an Amazon VPC that contains data sources for your Grafana workspace to connect to.

      Note: Connecting to a private VPC is not yet available in the Asia Pacific (Seoul) Region (ap-northeast-2).
      • securityGroupIdsrequired — (Array<String>)

        The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

      • subnetIdsrequired — (Array<String>)

        The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

    • workspaceDataSources — (Array<String>)

      This parameter is for internal use only, and should not be used.

    • workspaceDescription — (String)

      A description for the workspace. This is used only to help you identify this workspace.

      Pattern: ^[\p{L}\p{Z}\p{N}\p{P}]{0,2048}$

    • workspaceName — (String)

      The name for the workspace. It does not have to be unique.

    • workspaceNotificationDestinations — (Array<String>)

      Specify the Amazon Web Services notification channels that you plan to use in this workspace. Specifying these data sources here enables Amazon Managed Grafana to create IAM roles and permissions that allow Amazon Managed Grafana to use these channels.

    • workspaceOrganizationalUnits — (Array<String>)

      Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

    • workspaceRoleArn — (String)

      Specified the IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from, including both data sources and notification channels. You are responsible for managing the permissions for this role as new data sources or notification channels are added.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • workspace — (map)

        A structure containing data about the workspace that was created.

        • accountAccessType — (String)

          Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which organizational units the workspace can access.

          Possible values include:
          • "CURRENT_ACCOUNT"
          • "ORGANIZATION"
        • authenticationrequired — (map)

          A structure that describes whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • providersrequired — (Array<String>)

            Specifies whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • samlConfigurationStatus — (String)

            Specifies whether the workplace's user authentication method is fully configured.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"
        • createdrequired — (Date)

          The date that the workspace was created.

        • dataSourcesrequired — (Array<String>)

          Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources.

          This list is only used when the workspace was created through the Amazon Web Services console, and the permissionType is SERVICE_MANAGED.

        • description — (String)

          The user-defined description of the workspace.

        • endpointrequired — (String)

          The URL that users can use to access the Grafana console in the workspace.

        • freeTrialConsumed — (Boolean)

          Specifies whether this workspace has already fully used its free trial for Grafana Enterprise.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • freeTrialExpiration — (Date)

          If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when that free trial ends.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • grafanaToken — (String)

          The token that ties this workspace to a Grafana Labs account. For more information, see Link your account with Grafana Labs.

        • grafanaVersionrequired — (String)

          The version of Grafana supported in this workspace.

        • idrequired — (String)

          The unique ID of this workspace.

        • licenseExpiration — (Date)

          If this workspace has a full Grafana Enterprise license purchased through Amazon Web Services Marketplace, this specifies when the license ends and will need to be renewed. Purchasing the Enterprise plugins option through Amazon Managed Grafana does not have an expiration. It is valid until the license is removed.

        • licenseType — (String)

          Specifies whether this workspace has a full Grafana Enterprise license.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
          Possible values include:
          • "ENTERPRISE"
          • "ENTERPRISE_FREE_TRIAL"
        • modifiedrequired — (Date)

          The most recent date that the workspace was modified.

        • name — (String)

          The name of the workspace.

        • networkAccessControl — (map)

          The configuration settings for network access to your workspace.

          • prefixListIdsrequired — (Array<String>)

            An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

            Prefix list IDs have the format pl-1a2b3c4d .

            For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

          • vpceIdsrequired — (Array<String>)

            An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

            VPC endpoint IDs have the format vpce-1a2b3c4d .

            For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

            Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
        • notificationDestinations — (Array<String>)

          The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

        • organizationRoleName — (String)

          The name of the IAM role that is used to access resources through Organizations.

        • organizationalUnits — (Array<String>)

          Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

        • permissionType — (String)

          If this is SERVICE_MANAGED, and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification channels.

          If this is CUSTOMER_MANAGED, you must manage those roles and permissions yourself.

          If you are working with a workspace in a member account of an organization and that account is not a delegated administrator account, and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, this parameter must be set to CUSTOMER_MANAGED.

          For more information about converting between customer and service managed, see Managing permissions for data sources and notification channels. For more information about the roles and permissions that must be managed for customer managed workspaces, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels

          Possible values include:
          • "CUSTOMER_MANAGED"
          • "SERVICE_MANAGED"
        • stackSetName — (String)

          The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

        • statusrequired — (String)

          The current status of the workspace.

          Possible values include:
          • "ACTIVE"
          • "CREATING"
          • "DELETING"
          • "FAILED"
          • "UPDATING"
          • "UPGRADING"
          • "DELETION_FAILED"
          • "CREATION_FAILED"
          • "UPDATE_FAILED"
          • "UPGRADE_FAILED"
          • "LICENSE_REMOVAL_FAILED"
          • "VERSION_UPDATING"
          • "VERSION_UPDATE_FAILED"
        • tags — (map<String>)

          The list of tags associated with the workspace.

        • vpcConfiguration — (map)

          The configuration for connecting to data sources in a private VPC (Amazon Virtual Private Cloud).

          • securityGroupIdsrequired — (Array<String>)

            The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

          • subnetIdsrequired — (Array<String>)

            The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

        • workspaceRoleArn — (String)

          The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from. This role must already exist.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

createWorkspaceApiKey(params = {}, callback) ⇒ AWS.Request

Creates a Grafana API key for the workspace. This key can be used to authenticate requests sent to the workspace's HTTP API. See https://docs.aws.amazon.com/grafana/latest/userguide/Using-Grafana-APIs.html for available APIs and example requests.

Note: In workspaces compatible with Grafana version 9 or above, use workspace service accounts instead of API keys. API keys will be removed in a future release.

Service Reference:

Examples:

Calling the createWorkspaceApiKey operation

var params = {
  keyName: 'STRING_VALUE', /* required */
  keyRole: 'STRING_VALUE', /* required */
  secondsToLive: 'NUMBER_VALUE', /* required */
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.createWorkspaceApiKey(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • keyName — (String)

      Specifies the name of the key. Keynames must be unique to the workspace.

    • keyRole — (String)

      Specifies the permission level of the key.

      Valid values: ADMIN|EDITOR|VIEWER

    • secondsToLive — (Integer)

      Specifies the time in seconds until the key expires. Keys can be valid for up to 30 days.

    • workspaceId — (String)

      The ID of the workspace to create an API key.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • key — (String)

        The key token. Use this value as a bearer token to authenticate HTTP requests to the workspace.

      • keyName — (String)

        The name of the key that was created.

      • workspaceId — (String)

        The ID of the workspace that the key is valid for.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

createWorkspaceServiceAccount(params = {}, callback) ⇒ AWS.Request

Creates a service account for the workspace. A service account can be used to call Grafana HTTP APIs, and run automated workloads. After creating the service account with the correct GrafanaRole for your use case, use CreateWorkspaceServiceAccountToken to create a token that can be used to authenticate and authorize Grafana HTTP API calls.

You can only create service accounts for workspaces that are compatible with Grafana version 9 and above.

Note: For more information about service accounts, see Service accounts in the Amazon Managed Grafana User Guide. For more information about the Grafana HTTP APIs, see Using Grafana HTTP APIs in the Amazon Managed Grafana User Guide.

Service Reference:

Examples:

Calling the createWorkspaceServiceAccount operation

var params = {
  grafanaRole: ADMIN | EDITOR | VIEWER, /* required */
  name: 'STRING_VALUE', /* required */
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.createWorkspaceServiceAccount(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • grafanaRole — (String)

      The permission level to use for this service account.

      Note: For more information about the roles and the permissions each has, see User roles in the Amazon Managed Grafana User Guide.
      Possible values include:
      • "ADMIN"
      • "EDITOR"
      • "VIEWER"
    • name — (String)

      A name for the service account. The name must be unique within the workspace, as it determines the ID associated with the service account.

    • workspaceId — (String)

      The ID of the workspace within which to create the service account.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • grafanaRole — (String)

        The permission level given to the service account.

        Possible values include:
        • "ADMIN"
        • "EDITOR"
        • "VIEWER"
      • id — (String)

        The ID of the service account.

      • name — (String)

        The name of the service account.

      • workspaceId — (String)

        The workspace with which the service account is associated.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

createWorkspaceServiceAccountToken(params = {}, callback) ⇒ AWS.Request

Creates a token that can be used to authenticate and authorize Grafana HTTP API operations for the given workspace service account. The service account acts as a user for the API operations, and defines the permissions that are used by the API.

When you create the service account token, you will receive a key that is used when calling Grafana APIs. Do not lose this key, as it will not be retrievable again.

If you do lose the key, you can delete the token and recreate it to receive a new key. This will disable the initial key.

Service accounts are only available for workspaces that are compatible with Grafana version 9 and above.

Examples:

Calling the createWorkspaceServiceAccountToken operation

var params = {
  name: 'STRING_VALUE', /* required */
  secondsToLive: 'NUMBER_VALUE', /* required */
  serviceAccountId: 'STRING_VALUE', /* required */
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.createWorkspaceServiceAccountToken(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • name — (String)

      A name for the token to create.

    • secondsToLive — (Integer)

      Sets how long the token will be valid, in seconds. You can set the time up to 30 days in the future.

    • serviceAccountId — (String)

      The ID of the service account for which to create a token.

    • workspaceId — (String)

      The ID of the workspace the service account resides within.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • serviceAccountId — (String)

        The ID of the service account where the token was created.

      • serviceAccountToken — (map)

        Information about the created token, including the key. Be sure to store the key securely.

        • idrequired — (String)

          The unique ID of the service account token.

        • keyrequired — (String)

          The key for the service account token. Used when making calls to the Grafana HTTP APIs to authenticate and authorize the requests.

        • namerequired — (String)

          The name of the service account token.

      • workspaceId — (String)

        The ID of the workspace where the token was created.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

deleteWorkspace(params = {}, callback) ⇒ AWS.Request

Deletes an Amazon Managed Grafana workspace.

Service Reference:

Examples:

Calling the deleteWorkspace operation

var params = {
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.deleteWorkspace(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • workspaceId — (String)

      The ID of the workspace to delete.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • workspace — (map)

        A structure containing information about the workspace that was deleted.

        • accountAccessType — (String)

          Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which organizational units the workspace can access.

          Possible values include:
          • "CURRENT_ACCOUNT"
          • "ORGANIZATION"
        • authenticationrequired — (map)

          A structure that describes whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • providersrequired — (Array<String>)

            Specifies whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • samlConfigurationStatus — (String)

            Specifies whether the workplace's user authentication method is fully configured.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"
        • createdrequired — (Date)

          The date that the workspace was created.

        • dataSourcesrequired — (Array<String>)

          Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources.

          This list is only used when the workspace was created through the Amazon Web Services console, and the permissionType is SERVICE_MANAGED.

        • description — (String)

          The user-defined description of the workspace.

        • endpointrequired — (String)

          The URL that users can use to access the Grafana console in the workspace.

        • freeTrialConsumed — (Boolean)

          Specifies whether this workspace has already fully used its free trial for Grafana Enterprise.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • freeTrialExpiration — (Date)

          If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when that free trial ends.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • grafanaToken — (String)

          The token that ties this workspace to a Grafana Labs account. For more information, see Link your account with Grafana Labs.

        • grafanaVersionrequired — (String)

          The version of Grafana supported in this workspace.

        • idrequired — (String)

          The unique ID of this workspace.

        • licenseExpiration — (Date)

          If this workspace has a full Grafana Enterprise license purchased through Amazon Web Services Marketplace, this specifies when the license ends and will need to be renewed. Purchasing the Enterprise plugins option through Amazon Managed Grafana does not have an expiration. It is valid until the license is removed.

        • licenseType — (String)

          Specifies whether this workspace has a full Grafana Enterprise license.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
          Possible values include:
          • "ENTERPRISE"
          • "ENTERPRISE_FREE_TRIAL"
        • modifiedrequired — (Date)

          The most recent date that the workspace was modified.

        • name — (String)

          The name of the workspace.

        • networkAccessControl — (map)

          The configuration settings for network access to your workspace.

          • prefixListIdsrequired — (Array<String>)

            An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

            Prefix list IDs have the format pl-1a2b3c4d .

            For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

          • vpceIdsrequired — (Array<String>)

            An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

            VPC endpoint IDs have the format vpce-1a2b3c4d .

            For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

            Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
        • notificationDestinations — (Array<String>)

          The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

        • organizationRoleName — (String)

          The name of the IAM role that is used to access resources through Organizations.

        • organizationalUnits — (Array<String>)

          Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

        • permissionType — (String)

          If this is SERVICE_MANAGED, and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification channels.

          If this is CUSTOMER_MANAGED, you must manage those roles and permissions yourself.

          If you are working with a workspace in a member account of an organization and that account is not a delegated administrator account, and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, this parameter must be set to CUSTOMER_MANAGED.

          For more information about converting between customer and service managed, see Managing permissions for data sources and notification channels. For more information about the roles and permissions that must be managed for customer managed workspaces, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels

          Possible values include:
          • "CUSTOMER_MANAGED"
          • "SERVICE_MANAGED"
        • stackSetName — (String)

          The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

        • statusrequired — (String)

          The current status of the workspace.

          Possible values include:
          • "ACTIVE"
          • "CREATING"
          • "DELETING"
          • "FAILED"
          • "UPDATING"
          • "UPGRADING"
          • "DELETION_FAILED"
          • "CREATION_FAILED"
          • "UPDATE_FAILED"
          • "UPGRADE_FAILED"
          • "LICENSE_REMOVAL_FAILED"
          • "VERSION_UPDATING"
          • "VERSION_UPDATE_FAILED"
        • tags — (map<String>)

          The list of tags associated with the workspace.

        • vpcConfiguration — (map)

          The configuration for connecting to data sources in a private VPC (Amazon Virtual Private Cloud).

          • securityGroupIdsrequired — (Array<String>)

            The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

          • subnetIdsrequired — (Array<String>)

            The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

        • workspaceRoleArn — (String)

          The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from. This role must already exist.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

deleteWorkspaceApiKey(params = {}, callback) ⇒ AWS.Request

Deletes a Grafana API key for the workspace.

Note: In workspaces compatible with Grafana version 9 or above, use workspace service accounts instead of API keys. API keys will be removed in a future release.

Service Reference:

Examples:

Calling the deleteWorkspaceApiKey operation

var params = {
  keyName: 'STRING_VALUE', /* required */
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.deleteWorkspaceApiKey(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • keyName — (String)

      The name of the API key to delete.

    • workspaceId — (String)

      The ID of the workspace to delete.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • keyName — (String)

        The name of the key that was deleted.

      • workspaceId — (String)

        The ID of the workspace where the key was deleted.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

deleteWorkspaceServiceAccount(params = {}, callback) ⇒ AWS.Request

Deletes a workspace service account from the workspace.

This will delete any tokens created for the service account, as well. If the tokens are currently in use, the will fail to authenticate / authorize after they are deleted.

Service accounts are only available for workspaces that are compatible with Grafana version 9 and above.

Service Reference:

Examples:

Calling the deleteWorkspaceServiceAccount operation

var params = {
  serviceAccountId: 'STRING_VALUE', /* required */
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.deleteWorkspaceServiceAccount(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • serviceAccountId — (String)

      The ID of the service account to delete.

    • workspaceId — (String)

      The ID of the workspace where the service account resides.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • serviceAccountId — (String)

        The ID of the service account deleted.

      • workspaceId — (String)

        The ID of the workspace where the service account was deleted.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

deleteWorkspaceServiceAccountToken(params = {}, callback) ⇒ AWS.Request

Deletes a token for the workspace service account.

This will disable the key associated with the token. If any automation is currently using the key, it will no longer be authenticated or authorized to perform actions with the Grafana HTTP APIs.

Service accounts are only available for workspaces that are compatible with Grafana version 9 and above.

Examples:

Calling the deleteWorkspaceServiceAccountToken operation

var params = {
  serviceAccountId: 'STRING_VALUE', /* required */
  tokenId: 'STRING_VALUE', /* required */
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.deleteWorkspaceServiceAccountToken(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • serviceAccountId — (String)

      The ID of the service account from which to delete the token.

    • tokenId — (String)

      The ID of the token to delete.

    • workspaceId — (String)

      The ID of the workspace from which to delete the token.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • serviceAccountId — (String)

        The ID of the service account where the token was deleted.

      • tokenId — (String)

        The ID of the token that was deleted.

      • workspaceId — (String)

        The ID of the workspace where the token was deleted.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

describeWorkspace(params = {}, callback) ⇒ AWS.Request

Displays information about one Amazon Managed Grafana workspace.

Service Reference:

Examples:

Calling the describeWorkspace operation

var params = {
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.describeWorkspace(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • workspaceId — (String)

      The ID of the workspace to display information about.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • workspace — (map)

        A structure containing information about the workspace.

        • accountAccessType — (String)

          Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which organizational units the workspace can access.

          Possible values include:
          • "CURRENT_ACCOUNT"
          • "ORGANIZATION"
        • authenticationrequired — (map)

          A structure that describes whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • providersrequired — (Array<String>)

            Specifies whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • samlConfigurationStatus — (String)

            Specifies whether the workplace's user authentication method is fully configured.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"
        • createdrequired — (Date)

          The date that the workspace was created.

        • dataSourcesrequired — (Array<String>)

          Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources.

          This list is only used when the workspace was created through the Amazon Web Services console, and the permissionType is SERVICE_MANAGED.

        • description — (String)

          The user-defined description of the workspace.

        • endpointrequired — (String)

          The URL that users can use to access the Grafana console in the workspace.

        • freeTrialConsumed — (Boolean)

          Specifies whether this workspace has already fully used its free trial for Grafana Enterprise.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • freeTrialExpiration — (Date)

          If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when that free trial ends.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • grafanaToken — (String)

          The token that ties this workspace to a Grafana Labs account. For more information, see Link your account with Grafana Labs.

        • grafanaVersionrequired — (String)

          The version of Grafana supported in this workspace.

        • idrequired — (String)

          The unique ID of this workspace.

        • licenseExpiration — (Date)

          If this workspace has a full Grafana Enterprise license purchased through Amazon Web Services Marketplace, this specifies when the license ends and will need to be renewed. Purchasing the Enterprise plugins option through Amazon Managed Grafana does not have an expiration. It is valid until the license is removed.

        • licenseType — (String)

          Specifies whether this workspace has a full Grafana Enterprise license.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
          Possible values include:
          • "ENTERPRISE"
          • "ENTERPRISE_FREE_TRIAL"
        • modifiedrequired — (Date)

          The most recent date that the workspace was modified.

        • name — (String)

          The name of the workspace.

        • networkAccessControl — (map)

          The configuration settings for network access to your workspace.

          • prefixListIdsrequired — (Array<String>)

            An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

            Prefix list IDs have the format pl-1a2b3c4d .

            For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

          • vpceIdsrequired — (Array<String>)

            An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

            VPC endpoint IDs have the format vpce-1a2b3c4d .

            For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

            Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
        • notificationDestinations — (Array<String>)

          The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

        • organizationRoleName — (String)

          The name of the IAM role that is used to access resources through Organizations.

        • organizationalUnits — (Array<String>)

          Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

        • permissionType — (String)

          If this is SERVICE_MANAGED, and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification channels.

          If this is CUSTOMER_MANAGED, you must manage those roles and permissions yourself.

          If you are working with a workspace in a member account of an organization and that account is not a delegated administrator account, and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, this parameter must be set to CUSTOMER_MANAGED.

          For more information about converting between customer and service managed, see Managing permissions for data sources and notification channels. For more information about the roles and permissions that must be managed for customer managed workspaces, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels

          Possible values include:
          • "CUSTOMER_MANAGED"
          • "SERVICE_MANAGED"
        • stackSetName — (String)

          The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

        • statusrequired — (String)

          The current status of the workspace.

          Possible values include:
          • "ACTIVE"
          • "CREATING"
          • "DELETING"
          • "FAILED"
          • "UPDATING"
          • "UPGRADING"
          • "DELETION_FAILED"
          • "CREATION_FAILED"
          • "UPDATE_FAILED"
          • "UPGRADE_FAILED"
          • "LICENSE_REMOVAL_FAILED"
          • "VERSION_UPDATING"
          • "VERSION_UPDATE_FAILED"
        • tags — (map<String>)

          The list of tags associated with the workspace.

        • vpcConfiguration — (map)

          The configuration for connecting to data sources in a private VPC (Amazon Virtual Private Cloud).

          • securityGroupIdsrequired — (Array<String>)

            The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

          • subnetIdsrequired — (Array<String>)

            The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

        • workspaceRoleArn — (String)

          The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from. This role must already exist.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

describeWorkspaceAuthentication(params = {}, callback) ⇒ AWS.Request

Displays information about the authentication methods used in one Amazon Managed Grafana workspace.

Service Reference:

Examples:

Calling the describeWorkspaceAuthentication operation

var params = {
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.describeWorkspaceAuthentication(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • workspaceId — (String)

      The ID of the workspace to return authentication information about.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • authentication — (map)

        A structure containing information about the authentication methods used in the workspace.

        • awsSso — (map)

          A structure containing information about how this workspace works with IAM Identity Center.

          • ssoClientId — (String)

            The ID of the IAM Identity Center-managed application that is created by Amazon Managed Grafana.

        • providersrequired — (Array<String>)

          Specifies whether this workspace uses IAM Identity Center, SAML, or both methods to authenticate users to use the Grafana console in the Amazon Managed Grafana workspace.

        • saml — (map)

          A structure containing information about how this workspace works with SAML, including what attributes within the assertion are to be mapped to user information in the workspace.

          • configuration — (map)

            A structure containing details about how this workspace works with SAML.

            • allowedOrganizations — (Array<String>)

              Lists which organizations defined in the SAML assertion are allowed to use the Amazon Managed Grafana workspace. If this is empty, all organizations in the assertion attribute have access.

            • assertionAttributes — (map)

              A structure that defines which attributes in the SAML assertion are to be used to define information about the users authenticated by that IdP to use the workspace.

              • email — (String)

                The name of the attribute within the SAML assertion to use as the email names for SAML users.

              • groups — (String)

                The name of the attribute within the SAML assertion to use as the user full "friendly" names for user groups.

              • login — (String)

                The name of the attribute within the SAML assertion to use as the login names for SAML users.

              • name — (String)

                The name of the attribute within the SAML assertion to use as the user full "friendly" names for SAML users.

              • org — (String)

                The name of the attribute within the SAML assertion to use as the user full "friendly" names for the users' organizations.

              • role — (String)

                The name of the attribute within the SAML assertion to use as the user roles.

            • idpMetadatarequired — (map)

              A structure containing the identity provider (IdP) metadata used to integrate the identity provider with this workspace.

              • url — (String)

                The URL of the location containing the IdP metadata.

              • xml — (String)

                The full IdP metadata, in XML format.

            • loginValidityDuration — (Integer)

              How long a sign-on session by a SAML user is valid, before the user has to sign on again.

            • roleValues — (map)

              A structure containing arrays that map group names in the SAML assertion to the Grafana Admin and Editor roles in the workspace.

              • admin — (Array<String>)

                A list of groups from the SAML assertion attribute to grant the Grafana Admin role to.

              • editor — (Array<String>)

                A list of groups from the SAML assertion attribute to grant the Grafana Editor role to.

          • statusrequired — (String)

            Specifies whether the workspace's SAML configuration is complete.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

describeWorkspaceConfiguration(params = {}, callback) ⇒ AWS.Request

Gets the current configuration string for the given workspace.

Service Reference:

Examples:

Calling the describeWorkspaceConfiguration operation

var params = {
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.describeWorkspaceConfiguration(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • workspaceId — (String)

      The ID of the workspace to get configuration information for.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • configuration — (String)

        The configuration string for the workspace that you requested. For more information about the format and configuration options available, see Working in your Grafana workspace.

      • grafanaVersion — (String)

        The supported Grafana version for the workspace.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

disassociateLicense(params = {}, callback) ⇒ AWS.Request

Removes the Grafana Enterprise license from a workspace.

Service Reference:

Examples:

Calling the disassociateLicense operation

var params = {
  licenseType: ENTERPRISE | ENTERPRISE_FREE_TRIAL, /* required */
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.disassociateLicense(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • licenseType — (String)

      The type of license to remove from the workspace.

      Possible values include:
      • "ENTERPRISE"
      • "ENTERPRISE_FREE_TRIAL"
    • workspaceId — (String)

      The ID of the workspace to remove the Grafana Enterprise license from.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • workspace — (map)

        A structure containing information about the workspace.

        • accountAccessType — (String)

          Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which organizational units the workspace can access.

          Possible values include:
          • "CURRENT_ACCOUNT"
          • "ORGANIZATION"
        • authenticationrequired — (map)

          A structure that describes whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • providersrequired — (Array<String>)

            Specifies whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • samlConfigurationStatus — (String)

            Specifies whether the workplace's user authentication method is fully configured.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"
        • createdrequired — (Date)

          The date that the workspace was created.

        • dataSourcesrequired — (Array<String>)

          Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources.

          This list is only used when the workspace was created through the Amazon Web Services console, and the permissionType is SERVICE_MANAGED.

        • description — (String)

          The user-defined description of the workspace.

        • endpointrequired — (String)

          The URL that users can use to access the Grafana console in the workspace.

        • freeTrialConsumed — (Boolean)

          Specifies whether this workspace has already fully used its free trial for Grafana Enterprise.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • freeTrialExpiration — (Date)

          If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when that free trial ends.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • grafanaToken — (String)

          The token that ties this workspace to a Grafana Labs account. For more information, see Link your account with Grafana Labs.

        • grafanaVersionrequired — (String)

          The version of Grafana supported in this workspace.

        • idrequired — (String)

          The unique ID of this workspace.

        • licenseExpiration — (Date)

          If this workspace has a full Grafana Enterprise license purchased through Amazon Web Services Marketplace, this specifies when the license ends and will need to be renewed. Purchasing the Enterprise plugins option through Amazon Managed Grafana does not have an expiration. It is valid until the license is removed.

        • licenseType — (String)

          Specifies whether this workspace has a full Grafana Enterprise license.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
          Possible values include:
          • "ENTERPRISE"
          • "ENTERPRISE_FREE_TRIAL"
        • modifiedrequired — (Date)

          The most recent date that the workspace was modified.

        • name — (String)

          The name of the workspace.

        • networkAccessControl — (map)

          The configuration settings for network access to your workspace.

          • prefixListIdsrequired — (Array<String>)

            An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

            Prefix list IDs have the format pl-1a2b3c4d .

            For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

          • vpceIdsrequired — (Array<String>)

            An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

            VPC endpoint IDs have the format vpce-1a2b3c4d .

            For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

            Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
        • notificationDestinations — (Array<String>)

          The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

        • organizationRoleName — (String)

          The name of the IAM role that is used to access resources through Organizations.

        • organizationalUnits — (Array<String>)

          Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

        • permissionType — (String)

          If this is SERVICE_MANAGED, and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification channels.

          If this is CUSTOMER_MANAGED, you must manage those roles and permissions yourself.

          If you are working with a workspace in a member account of an organization and that account is not a delegated administrator account, and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, this parameter must be set to CUSTOMER_MANAGED.

          For more information about converting between customer and service managed, see Managing permissions for data sources and notification channels. For more information about the roles and permissions that must be managed for customer managed workspaces, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels

          Possible values include:
          • "CUSTOMER_MANAGED"
          • "SERVICE_MANAGED"
        • stackSetName — (String)

          The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

        • statusrequired — (String)

          The current status of the workspace.

          Possible values include:
          • "ACTIVE"
          • "CREATING"
          • "DELETING"
          • "FAILED"
          • "UPDATING"
          • "UPGRADING"
          • "DELETION_FAILED"
          • "CREATION_FAILED"
          • "UPDATE_FAILED"
          • "UPGRADE_FAILED"
          • "LICENSE_REMOVAL_FAILED"
          • "VERSION_UPDATING"
          • "VERSION_UPDATE_FAILED"
        • tags — (map<String>)

          The list of tags associated with the workspace.

        • vpcConfiguration — (map)

          The configuration for connecting to data sources in a private VPC (Amazon Virtual Private Cloud).

          • securityGroupIdsrequired — (Array<String>)

            The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

          • subnetIdsrequired — (Array<String>)

            The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

        • workspaceRoleArn — (String)

          The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from. This role must already exist.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

listPermissions(params = {}, callback) ⇒ AWS.Request

Lists the users and groups who have the Grafana Admin and Editor roles in this workspace. If you use this operation without specifying userId or groupId, the operation returns the roles of all users and groups. If you specify a userId or a groupId, only the roles for that user or group are returned. If you do this, you can specify only one userId or one groupId.

Service Reference:

Examples:

Calling the listPermissions operation

var params = {
  workspaceId: 'STRING_VALUE', /* required */
  groupId: 'STRING_VALUE',
  maxResults: 'NUMBER_VALUE',
  nextToken: 'STRING_VALUE',
  userId: 'STRING_VALUE',
  userType: SSO_USER | SSO_GROUP
};
grafana.listPermissions(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • groupId — (String)

      (Optional) Limits the results to only the group that matches this ID.

    • maxResults — (Integer)

      The maximum number of results to include in the response.

    • nextToken — (String)

      The token to use when requesting the next set of results. You received this token from a previous ListPermissions operation.

    • userId — (String)

      (Optional) Limits the results to only the user that matches this ID.

    • userType — (String)

      (Optional) If you specify SSO_USER, then only the permissions of IAM Identity Center users are returned. If you specify SSO_GROUP, only the permissions of IAM Identity Center groups are returned.

      Possible values include:
      • "SSO_USER"
      • "SSO_GROUP"
    • workspaceId — (String)

      The ID of the workspace to list permissions for. This parameter is required.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • nextToken — (String)

        The token to use in a subsequent ListPermissions operation to return the next set of results.

      • permissions — (Array<map>)

        The permissions returned by the operation.

        • rolerequired — (String)

          Specifies whether the user or group has the Admin, Editor, or Viewer role.

          Possible values include:
          • "ADMIN"
          • "EDITOR"
          • "VIEWER"
        • userrequired — (map)

          A structure with the ID of the user or group with this role.

          • idrequired — (String)

            The ID of the user or group.

            Pattern: ^([0-9a-fA-F]{10}-|)[A-Fa-f0-9]{8}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{12}$

          • typerequired — (String)

            Specifies whether this is a single user or a group.

            Possible values include:
            • "SSO_USER"
            • "SSO_GROUP"

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

listTagsForResource(params = {}, callback) ⇒ AWS.Request

The ListTagsForResource operation returns the tags that are associated with the Amazon Managed Service for Grafana resource specified by the resourceArn. Currently, the only resource that can be tagged is a workspace.

Service Reference:

Examples:

Calling the listTagsForResource operation

var params = {
  resourceArn: 'STRING_VALUE' /* required */
};
grafana.listTagsForResource(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • resourceArn — (String)

      The ARN of the resource the list of tags are associated with.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • tags — (map<String>)

        The list of tags that are associated with the resource.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

listVersions(params = {}, callback) ⇒ AWS.Request

Lists available versions of Grafana. These are available when calling CreateWorkspace. Optionally, include a workspace to list the versions to which it can be upgraded.

Service Reference:

Examples:

Calling the listVersions operation

var params = {
  maxResults: 'NUMBER_VALUE',
  nextToken: 'STRING_VALUE',
  workspaceId: 'STRING_VALUE'
};
grafana.listVersions(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • maxResults — (Integer)

      The maximum number of results to include in the response.

    • nextToken — (String)

      The token to use when requesting the next set of results. You receive this token from a previous ListVersions operation.

    • workspaceId — (String)

      The ID of the workspace to list the available upgrade versions. If not included, lists all versions of Grafana that are supported for CreateWorkspace.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • grafanaVersions — (Array<String>)

        The Grafana versions available to create. If a workspace ID is included in the request, the Grafana versions to which this workspace can be upgraded.

      • nextToken — (String)

        The token to use in a subsequent ListVersions operation to return the next set of results.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

listWorkspaces(params = {}, callback) ⇒ AWS.Request

Returns a list of Amazon Managed Grafana workspaces in the account, with some information about each workspace. For more complete information about one workspace, use DescribeWorkspace.

Service Reference:

Examples:

Calling the listWorkspaces operation

var params = {
  maxResults: 'NUMBER_VALUE',
  nextToken: 'STRING_VALUE'
};
grafana.listWorkspaces(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • maxResults — (Integer)

      The maximum number of workspaces to include in the results.

    • nextToken — (String)

      The token for the next set of workspaces to return. (You receive this token from a previous ListWorkspaces operation.)

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • nextToken — (String)

        The token to use when requesting the next set of workspaces.

      • workspaces — (Array<map>)

        An array of structures that contain some information about the workspaces in the account.

        • authenticationrequired — (map)

          A structure containing information about the authentication methods used in the workspace.

          • providersrequired — (Array<String>)

            Specifies whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • samlConfigurationStatus — (String)

            Specifies whether the workplace's user authentication method is fully configured.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"
        • createdrequired — (Date)

          The date that the workspace was created.

        • description — (String)

          The customer-entered description of the workspace.

        • endpointrequired — (String)

          The URL endpoint to use to access the Grafana console in the workspace.

        • grafanaToken — (String)

          The token that ties this workspace to a Grafana Labs account. For more information, see Link your account with Grafana Labs.

        • grafanaVersionrequired — (String)

          The Grafana version that the workspace is running.

        • idrequired — (String)

          The unique ID of the workspace.

        • licenseType — (String)

          Specifies whether this workspace has a full Grafana Enterprise license.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
          Possible values include:
          • "ENTERPRISE"
          • "ENTERPRISE_FREE_TRIAL"
        • modifiedrequired — (Date)

          The most recent date that the workspace was modified.

        • name — (String)

          The name of the workspace.

        • notificationDestinations — (Array<String>)

          The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, which allows Amazon Managed Grafana to use these channels.

        • statusrequired — (String)

          The current status of the workspace.

          Possible values include:
          • "ACTIVE"
          • "CREATING"
          • "DELETING"
          • "FAILED"
          • "UPDATING"
          • "UPGRADING"
          • "DELETION_FAILED"
          • "CREATION_FAILED"
          • "UPDATE_FAILED"
          • "UPGRADE_FAILED"
          • "LICENSE_REMOVAL_FAILED"
          • "VERSION_UPDATING"
          • "VERSION_UPDATE_FAILED"
        • tags — (map<String>)

          The list of tags associated with the workspace.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

listWorkspaceServiceAccounts(params = {}, callback) ⇒ AWS.Request

Returns a list of service accounts for a workspace.

Service accounts are only available for workspaces that are compatible with Grafana version 9 and above.

Service Reference:

Examples:

Calling the listWorkspaceServiceAccounts operation

var params = {
  workspaceId: 'STRING_VALUE', /* required */
  maxResults: 'NUMBER_VALUE',
  nextToken: 'STRING_VALUE'
};
grafana.listWorkspaceServiceAccounts(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • maxResults — (Integer)

      The maximum number of service accounts to include in the results.

    • nextToken — (String)

      The token for the next set of service accounts to return. (You receive this token from a previous ListWorkspaceServiceAccounts operation.)

    • workspaceId — (String)

      The workspace for which to list service accounts.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • nextToken — (String)

        The token to use when requesting the next set of service accounts.

      • serviceAccounts — (Array<map>)

        An array of structures containing information about the service accounts.

        • grafanaRolerequired — (String)

          The role of the service account, which sets the permission level used when calling Grafana APIs.

          Possible values include:
          • "ADMIN"
          • "EDITOR"
          • "VIEWER"
        • idrequired — (String)

          The unique ID of the service account.

        • isDisabledrequired — (String)

          Returns true if the service account is disabled. Service accounts can be disabled and enabled in the Amazon Managed Grafana console.

        • namerequired — (String)

          The name of the service account.

      • workspaceId — (String)

        The workspace to which the service accounts are associated.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

listWorkspaceServiceAccountTokens(params = {}, callback) ⇒ AWS.Request

Returns a list of tokens for a workspace service account.

Note: This does not return the key for each token. You cannot access keys after they are created. To create a new key, delete the token and recreate it.

Service accounts are only available for workspaces that are compatible with Grafana version 9 and above.

Examples:

Calling the listWorkspaceServiceAccountTokens operation

var params = {
  serviceAccountId: 'STRING_VALUE', /* required */
  workspaceId: 'STRING_VALUE', /* required */
  maxResults: 'NUMBER_VALUE',
  nextToken: 'STRING_VALUE'
};
grafana.listWorkspaceServiceAccountTokens(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • maxResults — (Integer)

      The maximum number of tokens to include in the results.

    • nextToken — (String)

      The token for the next set of service accounts to return. (You receive this token from a previous ListWorkspaceServiceAccountTokens operation.)

    • serviceAccountId — (String)

      The ID of the service account for which to return tokens.

    • workspaceId — (String)

      The ID of the workspace for which to return tokens.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • nextToken — (String)

        The token to use when requesting the next set of service accounts.

      • serviceAccountId — (String)

        The ID of the service account where the tokens reside.

      • serviceAccountTokens — (Array<map>)

        An array of structures containing information about the tokens.

        • createdAtrequired — (Date)

          When the service account token was created.

        • expiresAtrequired — (Date)

          When the service account token will expire.

        • idrequired — (String)

          The unique ID of the service account token.

        • lastUsedAt — (Date)

          The last time the token was used to authorize a Grafana HTTP API.

        • namerequired — (String)

          The name of the service account token.

      • workspaceId — (String)

        The ID of the workspace where the tokens reside.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

tagResource(params = {}, callback) ⇒ AWS.Request

The TagResource operation associates tags with an Amazon Managed Grafana resource. Currently, the only resource that can be tagged is workspaces.

If you specify a new tag key for the resource, this tag is appended to the list of tags associated with the resource. If you specify a tag key that is already associated with the resource, the new tag value that you specify replaces the previous value for that tag.

Service Reference:

Examples:

Calling the tagResource operation

var params = {
  resourceArn: 'STRING_VALUE', /* required */
  tags: { /* required */
    '<TagKey>': 'STRING_VALUE',
    /* '<TagKey>': ... */
  }
};
grafana.tagResource(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • resourceArn — (String)

      The ARN of the resource the tag is associated with.

    • tags — (map<String>)

      The list of tag keys and values to associate with the resource. You can associate tag keys only, tags (key and values) only or a combination of tag keys and tags.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

untagResource(params = {}, callback) ⇒ AWS.Request

The UntagResource operation removes the association of the tag with the Amazon Managed Grafana resource.

Service Reference:

Examples:

Calling the untagResource operation

var params = {
  resourceArn: 'STRING_VALUE', /* required */
  tagKeys: [ /* required */
    'STRING_VALUE',
    /* more items */
  ]
};
grafana.untagResource(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • resourceArn — (String)

      The ARN of the resource the tag association is removed from.

    • tagKeys — (Array<String>)

      The key values of the tag to be removed from the resource.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

updatePermissions(params = {}, callback) ⇒ AWS.Request

Updates which users in a workspace have the Grafana Admin or Editor roles.

Service Reference:

Examples:

Calling the updatePermissions operation

var params = {
  updateInstructionBatch: [ /* required */
    {
      action: ADD | REVOKE, /* required */
      role: ADMIN | EDITOR | VIEWER, /* required */
      users: [ /* required */
        {
          id: 'STRING_VALUE', /* required */
          type: SSO_USER | SSO_GROUP /* required */
        },
        /* more items */
      ]
    },
    /* more items */
  ],
  workspaceId: 'STRING_VALUE' /* required */
};
grafana.updatePermissions(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • updateInstructionBatch — (Array<map>)

      An array of structures that contain the permission updates to make.

      • actionrequired — (String)

        Specifies whether this update is to add or revoke role permissions.

        Possible values include:
        • "ADD"
        • "REVOKE"
      • rolerequired — (String)

        The role to add or revoke for the user or the group specified in users.

        Possible values include:
        • "ADMIN"
        • "EDITOR"
        • "VIEWER"
      • usersrequired — (Array<map>)

        A structure that specifies the user or group to add or revoke the role for.

        • idrequired — (String)

          The ID of the user or group.

          Pattern: ^([0-9a-fA-F]{10}-|)[A-Fa-f0-9]{8}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{12}$

        • typerequired — (String)

          Specifies whether this is a single user or a group.

          Possible values include:
          • "SSO_USER"
          • "SSO_GROUP"
    • workspaceId — (String)

      The ID of the workspace to update.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • errors — (Array<map>)

        An array of structures that contain the errors from the operation, if any.

        • causedByrequired — (map)

          Specifies which permission update caused the error.

          • actionrequired — (String)

            Specifies whether this update is to add or revoke role permissions.

            Possible values include:
            • "ADD"
            • "REVOKE"
          • rolerequired — (String)

            The role to add or revoke for the user or the group specified in users.

            Possible values include:
            • "ADMIN"
            • "EDITOR"
            • "VIEWER"
          • usersrequired — (Array<map>)

            A structure that specifies the user or group to add or revoke the role for.

            • idrequired — (String)

              The ID of the user or group.

              Pattern: ^([0-9a-fA-F]{10}-|)[A-Fa-f0-9]{8}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{4}-[A-Fa-f0-9]{12}$

            • typerequired — (String)

              Specifies whether this is a single user or a group.

              Possible values include:
              • "SSO_USER"
              • "SSO_GROUP"
        • coderequired — (Integer)

          The error code.

        • messagerequired — (String)

          The message for this error.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

updateWorkspace(params = {}, callback) ⇒ AWS.Request

Modifies an existing Amazon Managed Grafana workspace. If you use this operation and omit any optional parameters, the existing values of those parameters are not changed.

To modify the user authentication methods that the workspace uses, such as SAML or IAM Identity Center, use UpdateWorkspaceAuthentication.

To modify which users in the workspace have the Admin and Editor Grafana roles, use UpdatePermissions.

Service Reference:

Examples:

Calling the updateWorkspace operation

var params = {
  workspaceId: 'STRING_VALUE', /* required */
  accountAccessType: CURRENT_ACCOUNT | ORGANIZATION,
  networkAccessControl: {
    prefixListIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ],
    vpceIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ]
  },
  organizationRoleName: 'STRING_VALUE',
  permissionType: CUSTOMER_MANAGED | SERVICE_MANAGED,
  removeNetworkAccessConfiguration: true || false,
  removeVpcConfiguration: true || false,
  stackSetName: 'STRING_VALUE',
  vpcConfiguration: {
    securityGroupIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ],
    subnetIds: [ /* required */
      'STRING_VALUE',
      /* more items */
    ]
  },
  workspaceDataSources: [
    AMAZON_OPENSEARCH_SERVICE | CLOUDWATCH | PROMETHEUS | XRAY | TIMESTREAM | SITEWISE | ATHENA | REDSHIFT | TWINMAKER,
    /* more items */
  ],
  workspaceDescription: 'STRING_VALUE',
  workspaceName: 'STRING_VALUE',
  workspaceNotificationDestinations: [
    SNS,
    /* more items */
  ],
  workspaceOrganizationalUnits: [
    'STRING_VALUE',
    /* more items */
  ],
  workspaceRoleArn: 'STRING_VALUE'
};
grafana.updateWorkspace(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • accountAccessType — (String)

      Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If you specify ORGANIZATION, you must specify which organizational units the workspace can access in the workspaceOrganizationalUnits parameter.

      Possible values include:
      • "CURRENT_ACCOUNT"
      • "ORGANIZATION"
    • networkAccessControl — (map)

      The configuration settings for network access to your workspace.

      When this is configured, only listed IP addresses and VPC endpoints will be able to access your workspace. Standard Grafana authentication and authorization will still be required.

      If this is not configured, or is removed, then all IP addresses and VPC endpoints will be allowed. Standard Grafana authentication and authorization will still be required.

      • prefixListIdsrequired — (Array<String>)

        An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

        Prefix list IDs have the format pl-1a2b3c4d .

        For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

      • vpceIdsrequired — (Array<String>)

        An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

        VPC endpoint IDs have the format vpce-1a2b3c4d .

        For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

        Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
    • organizationRoleName — (String)

      The name of an IAM role that already exists to use to access resources through Organizations. This can only be used with a workspace that has the permissionType set to CUSTOMER_MANAGED.

    • permissionType — (String)

      Use this parameter if you want to change a workspace from SERVICE_MANAGED to CUSTOMER_MANAGED. This allows you to manage the permissions that the workspace uses to access datasources and notification channels. If the workspace is in a member Amazon Web Services account of an organization, and that account is not a delegated administrator account, and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, you must choose CUSTOMER_MANAGED.

      If you specify this as CUSTOMER_MANAGED, you must also specify a workspaceRoleArn that the workspace will use for accessing Amazon Web Services resources.

      For more information on the role and permissions needed, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels

      Note: Do not use this to convert a CUSTOMER_MANAGED workspace to SERVICE_MANAGED. Do not include this parameter if you want to leave the workspace as SERVICE_MANAGED. You can convert a CUSTOMER_MANAGED workspace to SERVICE_MANAGED using the Amazon Managed Grafana console. For more information, see Managing permissions for data sources and notification channels.
      Possible values include:
      • "CUSTOMER_MANAGED"
      • "SERVICE_MANAGED"
    • removeNetworkAccessConfiguration — (Boolean)

      Whether to remove the network access configuration from the workspace.

      Setting this to true and providing a networkAccessControl to set will return an error.

      If you remove this configuration by setting this to true, then all IP addresses and VPC endpoints will be allowed. Standard Grafana authentication and authorization will still be required.

    • removeVpcConfiguration — (Boolean)

      Whether to remove the VPC configuration from the workspace.

      Setting this to true and providing a vpcConfiguration to set will return an error.

    • stackSetName — (String)

      The name of the CloudFormation stack set to use to generate IAM roles to be used for this workspace.

    • vpcConfiguration — (map)

      The configuration settings for an Amazon VPC that contains data sources for your Grafana workspace to connect to.

      • securityGroupIdsrequired — (Array<String>)

        The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

      • subnetIdsrequired — (Array<String>)

        The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

    • workspaceDataSources — (Array<String>)

      This parameter is for internal use only, and should not be used.

    • workspaceDescription — (String)

      A description for the workspace. This is used only to help you identify this workspace.

    • workspaceId — (String)

      The ID of the workspace to update.

    • workspaceName — (String)

      A new name for the workspace to update.

    • workspaceNotificationDestinations — (Array<String>)

      Specify the Amazon Web Services notification channels that you plan to use in this workspace. Specifying these data sources here enables Amazon Managed Grafana to create IAM roles and permissions that allow Amazon Managed Grafana to use these channels.

    • workspaceOrganizationalUnits — (Array<String>)

      Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

    • workspaceRoleArn — (String)

      Specifies an IAM role that grants permissions to Amazon Web Services resources that the workspace accesses, such as data sources and notification channels. If this workspace has permissionType CUSTOMER_MANAGED, then this role is required.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • workspace — (map)

        A structure containing data about the workspace that was created.

        • accountAccessType — (String)

          Specifies whether the workspace can access Amazon Web Services resources in this Amazon Web Services account only, or whether it can also access Amazon Web Services resources in other accounts in the same organization. If this is ORGANIZATION, the workspaceOrganizationalUnits parameter specifies which organizational units the workspace can access.

          Possible values include:
          • "CURRENT_ACCOUNT"
          • "ORGANIZATION"
        • authenticationrequired — (map)

          A structure that describes whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • providersrequired — (Array<String>)

            Specifies whether the workspace uses SAML, IAM Identity Center, or both methods for user authentication.

          • samlConfigurationStatus — (String)

            Specifies whether the workplace's user authentication method is fully configured.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"
        • createdrequired — (Date)

          The date that the workspace was created.

        • dataSourcesrequired — (Array<String>)

          Specifies the Amazon Web Services data sources that have been configured to have IAM roles and permissions created to allow Amazon Managed Grafana to read data from these sources.

          This list is only used when the workspace was created through the Amazon Web Services console, and the permissionType is SERVICE_MANAGED.

        • description — (String)

          The user-defined description of the workspace.

        • endpointrequired — (String)

          The URL that users can use to access the Grafana console in the workspace.

        • freeTrialConsumed — (Boolean)

          Specifies whether this workspace has already fully used its free trial for Grafana Enterprise.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • freeTrialExpiration — (Date)

          If this workspace is currently in the free trial period for Grafana Enterprise, this value specifies when that free trial ends.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
        • grafanaToken — (String)

          The token that ties this workspace to a Grafana Labs account. For more information, see Link your account with Grafana Labs.

        • grafanaVersionrequired — (String)

          The version of Grafana supported in this workspace.

        • idrequired — (String)

          The unique ID of this workspace.

        • licenseExpiration — (Date)

          If this workspace has a full Grafana Enterprise license purchased through Amazon Web Services Marketplace, this specifies when the license ends and will need to be renewed. Purchasing the Enterprise plugins option through Amazon Managed Grafana does not have an expiration. It is valid until the license is removed.

        • licenseType — (String)

          Specifies whether this workspace has a full Grafana Enterprise license.

          Note: Amazon Managed Grafana workspaces no longer support Grafana Enterprise free trials.
          Possible values include:
          • "ENTERPRISE"
          • "ENTERPRISE_FREE_TRIAL"
        • modifiedrequired — (Date)

          The most recent date that the workspace was modified.

        • name — (String)

          The name of the workspace.

        • networkAccessControl — (map)

          The configuration settings for network access to your workspace.

          • prefixListIdsrequired — (Array<String>)

            An array of prefix list IDs. A prefix list is a list of CIDR ranges of IP addresses. The IP addresses specified are allowed to access your workspace. If the list is not included in the configuration (passed an empty array) then no IP addresses are allowed to access the workspace. You create a prefix list using the Amazon VPC console.

            Prefix list IDs have the format pl-1a2b3c4d .

            For more information about prefix lists, see Group CIDR blocks using managed prefix listsin the Amazon Virtual Private Cloud User Guide.

          • vpceIdsrequired — (Array<String>)

            An array of Amazon VPC endpoint IDs for the workspace. You can create VPC endpoints to your Amazon Managed Grafana workspace for access from within a VPC. If a NetworkAccessConfiguration is specified then only VPC endpoints specified here are allowed to access the workspace. If you pass in an empty array of strings, then no VPCs are allowed to access the workspace.

            VPC endpoint IDs have the format vpce-1a2b3c4d .

            For more information about creating an interface VPC endpoint, see Interface VPC endpoints in the Amazon Managed Grafana User Guide.

            Note: The only VPC endpoints that can be specified here are interface VPC endpoints for Grafana workspaces (using the com.amazonaws.[region].grafana-workspace service endpoint). Other VPC endpoints are ignored.
        • notificationDestinations — (Array<String>)

          The Amazon Web Services notification channels that Amazon Managed Grafana can automatically create IAM roles and permissions for, to allow Amazon Managed Grafana to use these channels.

        • organizationRoleName — (String)

          The name of the IAM role that is used to access resources through Organizations.

        • organizationalUnits — (Array<String>)

          Specifies the organizational units that this workspace is allowed to use data sources from, if this workspace is in an account that is part of an organization.

        • permissionType — (String)

          If this is SERVICE_MANAGED, and the workplace was created through the Amazon Managed Grafana console, then Amazon Managed Grafana automatically creates the IAM roles and provisions the permissions that the workspace needs to use Amazon Web Services data sources and notification channels.

          If this is CUSTOMER_MANAGED, you must manage those roles and permissions yourself.

          If you are working with a workspace in a member account of an organization and that account is not a delegated administrator account, and you want the workspace to access data sources in other Amazon Web Services accounts in the organization, this parameter must be set to CUSTOMER_MANAGED.

          For more information about converting between customer and service managed, see Managing permissions for data sources and notification channels. For more information about the roles and permissions that must be managed for customer managed workspaces, see Amazon Managed Grafana permissions and policies for Amazon Web Services data sources and notification channels

          Possible values include:
          • "CUSTOMER_MANAGED"
          • "SERVICE_MANAGED"
        • stackSetName — (String)

          The name of the CloudFormation stack set that is used to generate IAM roles to be used for this workspace.

        • statusrequired — (String)

          The current status of the workspace.

          Possible values include:
          • "ACTIVE"
          • "CREATING"
          • "DELETING"
          • "FAILED"
          • "UPDATING"
          • "UPGRADING"
          • "DELETION_FAILED"
          • "CREATION_FAILED"
          • "UPDATE_FAILED"
          • "UPGRADE_FAILED"
          • "LICENSE_REMOVAL_FAILED"
          • "VERSION_UPDATING"
          • "VERSION_UPDATE_FAILED"
        • tags — (map<String>)

          The list of tags associated with the workspace.

        • vpcConfiguration — (map)

          The configuration for connecting to data sources in a private VPC (Amazon Virtual Private Cloud).

          • securityGroupIdsrequired — (Array<String>)

            The list of Amazon EC2 security group IDs attached to the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

          • subnetIdsrequired — (Array<String>)

            The list of Amazon EC2 subnet IDs created in the Amazon VPC for your Grafana workspace to connect. Duplicates not allowed.

        • workspaceRoleArn — (String)

          The IAM role that grants permissions to the Amazon Web Services resources that the workspace will view data from. This role must already exist.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

updateWorkspaceAuthentication(params = {}, callback) ⇒ AWS.Request

Use this operation to define the identity provider (IdP) that this workspace authenticates users from, using SAML. You can also map SAML assertion attributes to workspace user information and define which groups in the assertion attribute are to have the Admin and Editor roles in the workspace.

Note: Changes to the authentication method for a workspace may take a few minutes to take effect.

Service Reference:

Examples:

Calling the updateWorkspaceAuthentication operation

var params = {
  authenticationProviders: [ /* required */
    AWS_SSO | SAML,
    /* more items */
  ],
  workspaceId: 'STRING_VALUE', /* required */
  samlConfiguration: {
    idpMetadata: { /* required */
      url: 'STRING_VALUE',
      xml: 'STRING_VALUE'
    },
    allowedOrganizations: [
      'STRING_VALUE',
      /* more items */
    ],
    assertionAttributes: {
      email: 'STRING_VALUE',
      groups: 'STRING_VALUE',
      login: 'STRING_VALUE',
      name: 'STRING_VALUE',
      org: 'STRING_VALUE',
      role: 'STRING_VALUE'
    },
    loginValidityDuration: 'NUMBER_VALUE',
    roleValues: {
      admin: [
        'STRING_VALUE',
        /* more items */
      ],
      editor: [
        'STRING_VALUE',
        /* more items */
      ]
    }
  }
};
grafana.updateWorkspaceAuthentication(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • authenticationProviders — (Array<String>)

      Specifies whether this workspace uses SAML 2.0, IAM Identity Center, or both to authenticate users for using the Grafana console within a workspace. For more information, see User authentication in Amazon Managed Grafana.

    • samlConfiguration — (map)

      If the workspace uses SAML, use this structure to map SAML assertion attributes to workspace user information and define which groups in the assertion attribute are to have the Admin and Editor roles in the workspace.

      • allowedOrganizations — (Array<String>)

        Lists which organizations defined in the SAML assertion are allowed to use the Amazon Managed Grafana workspace. If this is empty, all organizations in the assertion attribute have access.

      • assertionAttributes — (map)

        A structure that defines which attributes in the SAML assertion are to be used to define information about the users authenticated by that IdP to use the workspace.

        • email — (String)

          The name of the attribute within the SAML assertion to use as the email names for SAML users.

        • groups — (String)

          The name of the attribute within the SAML assertion to use as the user full "friendly" names for user groups.

        • login — (String)

          The name of the attribute within the SAML assertion to use as the login names for SAML users.

        • name — (String)

          The name of the attribute within the SAML assertion to use as the user full "friendly" names for SAML users.

        • org — (String)

          The name of the attribute within the SAML assertion to use as the user full "friendly" names for the users' organizations.

        • role — (String)

          The name of the attribute within the SAML assertion to use as the user roles.

      • idpMetadatarequired — (map)

        A structure containing the identity provider (IdP) metadata used to integrate the identity provider with this workspace.

        • url — (String)

          The URL of the location containing the IdP metadata.

        • xml — (String)

          The full IdP metadata, in XML format.

      • loginValidityDuration — (Integer)

        How long a sign-on session by a SAML user is valid, before the user has to sign on again.

      • roleValues — (map)

        A structure containing arrays that map group names in the SAML assertion to the Grafana Admin and Editor roles in the workspace.

        • admin — (Array<String>)

          A list of groups from the SAML assertion attribute to grant the Grafana Admin role to.

        • editor — (Array<String>)

          A list of groups from the SAML assertion attribute to grant the Grafana Editor role to.

    • workspaceId — (String)

      The ID of the workspace to update the authentication for.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs. The data object has the following properties:

      • authentication — (map)

        A structure that describes the user authentication for this workspace after the update is made.

        • awsSso — (map)

          A structure containing information about how this workspace works with IAM Identity Center.

          • ssoClientId — (String)

            The ID of the IAM Identity Center-managed application that is created by Amazon Managed Grafana.

        • providersrequired — (Array<String>)

          Specifies whether this workspace uses IAM Identity Center, SAML, or both methods to authenticate users to use the Grafana console in the Amazon Managed Grafana workspace.

        • saml — (map)

          A structure containing information about how this workspace works with SAML, including what attributes within the assertion are to be mapped to user information in the workspace.

          • configuration — (map)

            A structure containing details about how this workspace works with SAML.

            • allowedOrganizations — (Array<String>)

              Lists which organizations defined in the SAML assertion are allowed to use the Amazon Managed Grafana workspace. If this is empty, all organizations in the assertion attribute have access.

            • assertionAttributes — (map)

              A structure that defines which attributes in the SAML assertion are to be used to define information about the users authenticated by that IdP to use the workspace.

              • email — (String)

                The name of the attribute within the SAML assertion to use as the email names for SAML users.

              • groups — (String)

                The name of the attribute within the SAML assertion to use as the user full "friendly" names for user groups.

              • login — (String)

                The name of the attribute within the SAML assertion to use as the login names for SAML users.

              • name — (String)

                The name of the attribute within the SAML assertion to use as the user full "friendly" names for SAML users.

              • org — (String)

                The name of the attribute within the SAML assertion to use as the user full "friendly" names for the users' organizations.

              • role — (String)

                The name of the attribute within the SAML assertion to use as the user roles.

            • idpMetadatarequired — (map)

              A structure containing the identity provider (IdP) metadata used to integrate the identity provider with this workspace.

              • url — (String)

                The URL of the location containing the IdP metadata.

              • xml — (String)

                The full IdP metadata, in XML format.

            • loginValidityDuration — (Integer)

              How long a sign-on session by a SAML user is valid, before the user has to sign on again.

            • roleValues — (map)

              A structure containing arrays that map group names in the SAML assertion to the Grafana Admin and Editor roles in the workspace.

              • admin — (Array<String>)

                A list of groups from the SAML assertion attribute to grant the Grafana Admin role to.

              • editor — (Array<String>)

                A list of groups from the SAML assertion attribute to grant the Grafana Editor role to.

          • statusrequired — (String)

            Specifies whether the workspace's SAML configuration is complete.

            Possible values include:
            • "CONFIGURED"
            • "NOT_CONFIGURED"

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.

updateWorkspaceConfiguration(params = {}, callback) ⇒ AWS.Request

Updates the configuration string for the given workspace

Service Reference:

Examples:

Calling the updateWorkspaceConfiguration operation

var params = {
  configuration: any /* This value will be JSON encoded on your behalf with JSON.stringify() */, /* required */
  workspaceId: 'STRING_VALUE', /* required */
  grafanaVersion: 'STRING_VALUE'
};
grafana.updateWorkspaceConfiguration(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

Parameters:

  • params (Object) (defaults to: {})
    • configuration — (String)

      The new configuration string for the workspace. For more information about the format and configuration options available, see Working in your Grafana workspace.

    • grafanaVersion — (String)

      Specifies the version of Grafana to support in the workspace. If not specified, keeps the current version of the workspace.

      Can only be used to upgrade (for example, from 8.4 to 9.4), not downgrade (for example, from 9.4 to 8.4).

      To know what versions are available to upgrade to for a specific workspace, see the ListVersions operation.

    • workspaceId — (String)

      The ID of the workspace to update.

Callback (callback):

  • function(err, data) { ... }

    Called when a response from the service is returned. If a callback is not supplied, you must call AWS.Request.send() on the returned request object to initiate the request.

    Context (this):

    • (AWS.Response)

      the response object containing error, data properties, and the original request object.

    Parameters:

    • err (Error)

      the error object returned from the request. Set to null if the request is successful.

    • data (Object)

      the de-serialized data returned from the request. Set to null if a request error occurs.

Returns:

  • (AWS.Request)

    a handle to the operation request for subsequent event callback registration.