iam-floyd
Version:
AWS IAM policy statement generator with fluent interface
278 lines (277 loc) • 11.1 kB
TypeScript
import { AccessLevelList } from '../../shared/access-level';
import { PolicyStatement, Operator } from '../../shared';
/**
* Statement provider for service [deepcomposer](https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsdeepcomposer.html).
*
* @param sid [SID](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_sid.html) of the statement
*/
export declare class Deepcomposer extends PolicyStatement {
servicePrefix: string;
/**
* Statement provider for service [deepcomposer](https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsdeepcomposer.html).
*
* @param sid [SID](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_sid.html) of the statement
*/
constructor(sid?: string);
/**
* Grants permission to associate a DeepComposer coupon (or DSN) with the account associated with the sender of the request
*
* Access Level: Write
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/what-it-is-keyboard.html
*/
toAssociateCoupon(): this;
/**
* Grants permission to create an audio file by converting the midi composition into a wav or mp3 file
*
* Access Level: Write
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toCreateAudio(): this;
/**
* Grants permission to create a multi-track midi composition
*
* Access Level: Write
*
* Possible conditions:
* - .ifAwsRequestTag()
* - .ifAwsTagKeys()
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toCreateComposition(): this;
/**
* Grants permission to start creating/training a generative-model that is able to perform inference against the user-provided piano-melody to create a multi-track midi composition
*
* Access Level: Write
*
* Possible conditions:
* - .ifAwsRequestTag()
* - .ifAwsTagKeys()
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-custom-model.html
*/
toCreateModel(): this;
/**
* Grants permission to delete the composition
*
* Access Level: Write
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toDeleteComposition(): this;
/**
* Grants permission to delete the model
*
* Access Level: Write
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-custom-model.html
*/
toDeleteModel(): this;
/**
* Grants permission to get information about the composition
*
* Access Level: Read
*
* Possible conditions:
* - .ifAwsResourceTag()
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toGetComposition(): this;
/**
* Grants permission to get information about the model
*
* Access Level: Read
*
* Possible conditions:
* - .ifAwsResourceTag()
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-custom-model.html
*/
toGetModel(): this;
/**
* Grants permission to get information about the sample/pre-trained DeepComposer model
*
* Access Level: Read
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toGetSampleModel(): this;
/**
* Grants permission to list all the compositions owned by the sender of the request
*
* Access Level: List
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toListCompositions(): this;
/**
* Grants permission to list all the models owned by the sender of the request
*
* Access Level: List
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-custom-model.html
*/
toListModels(): this;
/**
* Grants permission to list all the sample/pre-trained models provided by the DeepComposer service
*
* Access Level: List
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toListSampleModels(): this;
/**
* Grants permission to list tags for a resource
*
* Access Level: List
*
* Possible conditions:
* - .ifAwsResourceTag()
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/deepcomposer-tagging.html
*/
toListTagsForResource(): this;
/**
* Grants permission to list all the training options or topic for creating/training a model
*
* Access Level: List
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-custom-model.html
*/
toListTrainingTopics(): this;
/**
* Grants permission to tag a resource
*
* Access Level: Tagging
*
* Possible conditions:
* - .ifAwsTagKeys()
* - .ifAwsRequestTag()
* - .ifAwsResourceTag()
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/deepcomposer-tagging.html
*/
toTagResource(): this;
/**
* Grants permission to untag a resource
*
* Access Level: Tagging
*
* Possible conditions:
* - .ifAwsTagKeys()
* - .ifAwsResourceTag()
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/deepcomposer-tagging.html
*/
toUntagResource(): this;
/**
* Grants permission to modify the mutable properties associated with a composition
*
* Access Level: Write
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*/
toUpdateComposition(): this;
/**
* Grants permission to to modify the mutable properties associated with a model
*
* Access Level: Write
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-custom-model.html
*/
toUpdateModel(): this;
protected accessLevelList: AccessLevelList;
/**
* Adds a resource of type model to the statement
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-custom-model.html
*
* @param modelId - Identifier for the modelId.
* @param account - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account.
* @param region - Region of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's region.
* @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition.
*
* Possible conditions:
* - .ifAwsResourceTag()
*/
onModel(modelId: string, account?: string, region?: string, partition?: string): this;
/**
* Adds a resource of type composition to the statement
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*
* @param compositionId - Identifier for the compositionId.
* @param account - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account.
* @param region - Region of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's region.
* @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition.
*
* Possible conditions:
* - .ifAwsResourceTag()
*/
onComposition(compositionId: string, account?: string, region?: string, partition?: string): this;
/**
* Adds a resource of type audio to the statement
*
* https://docs.aws.amazon.com/deepcomposer/latest/devguide/get-started-learn-from-pre-trained-models.html
*
* @param audioId - Identifier for the audioId.
* @param account - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account.
* @param region - Region of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's region.
* @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition.
*/
onAudio(audioId: string, account?: string, region?: string, partition?: string): this;
/**
* Filters access by actions based on the presence of tag key-value pairs in the request
*
* https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-requesttag
*
* Applies to actions:
* - .toCreateComposition()
* - .toCreateModel()
* - .toTagResource()
*
* @param tagKey The tag key to check
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
ifAwsRequestTag(tagKey: string, value: string | string[], operator?: Operator | string): this;
/**
* Filters access by actions based on tag key-value pairs attached to the resource
*
* https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-resourcetag
*
* Applies to actions:
* - .toGetComposition()
* - .toGetModel()
* - .toListTagsForResource()
* - .toTagResource()
* - .toUntagResource()
*
* Applies to resource types:
* - model
* - composition
*
* @param tagKey The tag key to check
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
ifAwsResourceTag(tagKey: string, value: string | string[], operator?: Operator | string): this;
/**
* Filters access by actions based on the presence of tag keys in the request
*
* https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-tagkeys
*
* Applies to actions:
* - .toCreateComposition()
* - .toCreateModel()
* - .toTagResource()
* - .toUntagResource()
*
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
ifAwsTagKeys(value: string | string[], operator?: Operator | string): this;
}