iam-floyd
Version:
AWS IAM policy statement generator with fluent interface
126 lines (125 loc) • 5.24 kB
TypeScript
import { AccessLevelList } from '../../shared/access-level';
import { PolicyStatement, Operator } from '../../shared';
/**
* Statement provider for service [bedrock-mantle](https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonbedrockpoweredbyawsmantle.html).
*
* @param sid [SID](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_sid.html) of the statement
*/
export declare class BedrockMantle extends PolicyStatement {
servicePrefix: string;
/**
* Statement provider for service [bedrock-mantle](https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonbedrockpoweredbyawsmantle.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 make API calls using bearer token authentication
*
* Access Level: List
*
* Possible conditions:
* - .ifBearerTokenType()
*/
toCallWithBearerToken(): this;
/**
* Grants permission to cancel an in-progress inference request
*
* Access Level: Write
*
* https://docs.aws.amazon.com/Bedrock/latest/UserGuide/aws-mantle.html#welcome
*/
toCancelInference(): this;
/**
* Grants permission to create a chat completion inference request
*
* Access Level: Write
*
* Possible conditions:
* - .ifServiceTier()
* - .ifModel()
*
* https://docs.aws.amazon.com/Bedrock/latest/UserGuide/aws-mantle.htmlwelcome
*/
toCreateInference(): this;
/**
* Grants permission to delete a specific inference request
*
* Access Level: Write
*
* https://docs.aws.amazon.com/Bedrock/latest/UserGuide/aws-mantle.html#welcome
*/
toDeleteInference(): this;
/**
* Grants permission to retrieve details of a specific inference request
*
* Access Level: Read
*
* https://docs.aws.amazon.com/Bedrock/latest/UserGuide/aws-mantle.html#welcome
*/
toGetInference(): this;
/**
* Grants permission to retrieve information about a specific model
*
* Access Level: Read
*
* https://docs.aws.amazon.com/Bedrock/latest/UserGuide/aws-mantle.html#welcome
*/
toGetModel(): this;
/**
* Grants permission to list all available models in a project
*
* Access Level: List
*
* https://docs.aws.amazon.com/Bedrock/latest/UserGuide/aws-mantle.html#welcome
*/
toListModels(): this;
protected accessLevelList: AccessLevelList;
/**
* Adds a resource of type project to the statement
*
* https://docs.aws.amazon.com/Bedrock/latest/UserGuide/aws-mantle.html#Project
*
* @param resourceId - Identifier for the resourceId.
* @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.
*/
onProject(resourceId: string, account?: string, region?: string, partition?: string): this;
/**
* Filters access by the Short-term or Long-term bearer tokens
*
* https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonbedrockmantle.html#amazonbedrockmantle-policy-keys
*
* Applies to actions:
* - .toCallWithBearerToken()
*
* @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`
*/
ifBearerTokenType(value: string | string[], operator?: Operator | string): this;
/**
* Filters access by the specified Model
*
* https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonbedrockmantle.html#amazonbedrockmantle-policy-keys
*
* Applies to actions:
* - .toCreateInference()
*
* @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`
*/
ifModel(value: string | string[], operator?: Operator | string): this;
/**
* Filters access by the specified ServiceTier
*
* https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonbedrockmantle.html#amazonbedrockmantle-policy-keys
*
* Applies to actions:
* - .toCreateInference()
*
* @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`
*/
ifServiceTier(value: string | string[], operator?: Operator | string): this;
}