com.pulumi.awsnative.ssm.kotlin.SsmFunctions.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-native-kotlin Show documentation
Show all versions of pulumi-aws-native-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.ssm.kotlin
import com.pulumi.awsnative.ssm.SsmFunctions.getAssociationPlain
import com.pulumi.awsnative.ssm.SsmFunctions.getDocumentPlain
import com.pulumi.awsnative.ssm.SsmFunctions.getParameterPlain
import com.pulumi.awsnative.ssm.SsmFunctions.getPatchBaselinePlain
import com.pulumi.awsnative.ssm.SsmFunctions.getResourceDataSyncPlain
import com.pulumi.awsnative.ssm.SsmFunctions.getResourcePolicyPlain
import com.pulumi.awsnative.ssm.kotlin.inputs.GetAssociationPlainArgs
import com.pulumi.awsnative.ssm.kotlin.inputs.GetAssociationPlainArgsBuilder
import com.pulumi.awsnative.ssm.kotlin.inputs.GetDocumentPlainArgs
import com.pulumi.awsnative.ssm.kotlin.inputs.GetDocumentPlainArgsBuilder
import com.pulumi.awsnative.ssm.kotlin.inputs.GetParameterPlainArgs
import com.pulumi.awsnative.ssm.kotlin.inputs.GetParameterPlainArgsBuilder
import com.pulumi.awsnative.ssm.kotlin.inputs.GetPatchBaselinePlainArgs
import com.pulumi.awsnative.ssm.kotlin.inputs.GetPatchBaselinePlainArgsBuilder
import com.pulumi.awsnative.ssm.kotlin.inputs.GetResourceDataSyncPlainArgs
import com.pulumi.awsnative.ssm.kotlin.inputs.GetResourceDataSyncPlainArgsBuilder
import com.pulumi.awsnative.ssm.kotlin.inputs.GetResourcePolicyPlainArgs
import com.pulumi.awsnative.ssm.kotlin.inputs.GetResourcePolicyPlainArgsBuilder
import com.pulumi.awsnative.ssm.kotlin.outputs.GetAssociationResult
import com.pulumi.awsnative.ssm.kotlin.outputs.GetDocumentResult
import com.pulumi.awsnative.ssm.kotlin.outputs.GetParameterResult
import com.pulumi.awsnative.ssm.kotlin.outputs.GetPatchBaselineResult
import com.pulumi.awsnative.ssm.kotlin.outputs.GetResourceDataSyncResult
import com.pulumi.awsnative.ssm.kotlin.outputs.GetResourcePolicyResult
import kotlinx.coroutines.future.await
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import com.pulumi.awsnative.ssm.kotlin.outputs.GetAssociationResult.Companion.toKotlin as getAssociationResultToKotlin
import com.pulumi.awsnative.ssm.kotlin.outputs.GetDocumentResult.Companion.toKotlin as getDocumentResultToKotlin
import com.pulumi.awsnative.ssm.kotlin.outputs.GetParameterResult.Companion.toKotlin as getParameterResultToKotlin
import com.pulumi.awsnative.ssm.kotlin.outputs.GetPatchBaselineResult.Companion.toKotlin as getPatchBaselineResultToKotlin
import com.pulumi.awsnative.ssm.kotlin.outputs.GetResourceDataSyncResult.Companion.toKotlin as getResourceDataSyncResultToKotlin
import com.pulumi.awsnative.ssm.kotlin.outputs.GetResourcePolicyResult.Companion.toKotlin as getResourcePolicyResultToKotlin
public object SsmFunctions {
/**
* The AWS::SSM::Association resource associates an SSM document in AWS Systems Manager with EC2 instances that contain a configuration agent to process the document.
* @param argument null
* @return null
*/
public suspend fun getAssociation(argument: GetAssociationPlainArgs): GetAssociationResult =
getAssociationResultToKotlin(getAssociationPlain(argument.toJava()).await())
/**
* @see [getAssociation].
* @param associationId Unique identifier of the association.
* @return null
*/
public suspend fun getAssociation(associationId: String): GetAssociationResult {
val argument = GetAssociationPlainArgs(
associationId = associationId,
)
return getAssociationResultToKotlin(getAssociationPlain(argument.toJava()).await())
}
/**
* @see [getAssociation].
* @param argument Builder for [com.pulumi.awsnative.ssm.kotlin.inputs.GetAssociationPlainArgs].
* @return null
*/
public suspend fun getAssociation(argument: suspend GetAssociationPlainArgsBuilder.() -> Unit): GetAssociationResult {
val builder = GetAssociationPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getAssociationResultToKotlin(getAssociationPlain(builtArgument.toJava()).await())
}
/**
* The AWS::SSM::Document resource is an SSM document in AWS Systems Manager that defines the actions that Systems Manager performs, which can be used to set up and run commands on your instances.
* @param argument null
* @return null
*/
public suspend fun getDocument(argument: GetDocumentPlainArgs): GetDocumentResult =
getDocumentResultToKotlin(getDocumentPlain(argument.toJava()).await())
/**
* @see [getDocument].
* @param name A name for the Systems Manager document.
* @return null
*/
public suspend fun getDocument(name: String): GetDocumentResult {
val argument = GetDocumentPlainArgs(
name = name,
)
return getDocumentResultToKotlin(getDocumentPlain(argument.toJava()).await())
}
/**
* @see [getDocument].
* @param argument Builder for [com.pulumi.awsnative.ssm.kotlin.inputs.GetDocumentPlainArgs].
* @return null
*/
public suspend fun getDocument(argument: suspend GetDocumentPlainArgsBuilder.() -> Unit): GetDocumentResult {
val builder = GetDocumentPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getDocumentResultToKotlin(getDocumentPlain(builtArgument.toJava()).await())
}
/**
* The ``AWS::SSM::Parameter`` resource creates an SSM parameter in SYSlong Parameter Store.
* To create an SSM parameter, you must have the IAMlong (IAM) permissions ``ssm:PutParameter`` and ``ssm:AddTagsToResource``. On stack creation, CFNlong adds the following three tags to the parameter: ``aws:cloudformation:stack-name``, ``aws:cloudformation:logical-id``, and ``aws:cloudformation:stack-id``, in addition to any custom tags you specify.
* To add, update, or remove tags during stack update, you must have IAM permissions for both ``ssm:AddTagsToResource`` and ``ssm:RemoveTagsFromResource``. For more information, see [Managing Access Using Policies](https://docs.aws.amazon.com/systems-manager/latest/userguide/security-iam.html#security_iam_access-manage) in the *User Guide*.
* For information about valid values for parameters, see [About requirements and constraints for parameter names](https://docs.aws.amazon.com/systems-manager/latest/userguide/sysman-paramstore-su-create.html#sysman-parameter-name-constraints) in the *User Guide* and [PutParameter](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_PutParameter.html) in the *API Reference*.
* @param argument null
* @return null
*/
public suspend fun getParameter(argument: GetParameterPlainArgs): GetParameterResult =
getParameterResultToKotlin(getParameterPlain(argument.toJava()).await())
/**
* @see [getParameter].
* @param name The name of the parameter.
* The maximum length constraint listed below includes capacity for additional system attributes that aren't part of the name. The maximum length for a parameter name, including the full length of the parameter Amazon Resource Name (ARN), is 1011 characters. For example, the length of the following parameter name is 65 characters, not 20 characters: ``arn:aws:ssm:us-east-2:111222333444:parameter/ExampleParameterName``
* @return null
*/
public suspend fun getParameter(name: String): GetParameterResult {
val argument = GetParameterPlainArgs(
name = name,
)
return getParameterResultToKotlin(getParameterPlain(argument.toJava()).await())
}
/**
* @see [getParameter].
* @param argument Builder for [com.pulumi.awsnative.ssm.kotlin.inputs.GetParameterPlainArgs].
* @return null
*/
public suspend fun getParameter(argument: suspend GetParameterPlainArgsBuilder.() -> Unit): GetParameterResult {
val builder = GetParameterPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getParameterResultToKotlin(getParameterPlain(builtArgument.toJava()).await())
}
/**
* Resource Type definition for AWS::SSM::PatchBaseline
* @param argument null
* @return null
*/
public suspend fun getPatchBaseline(argument: GetPatchBaselinePlainArgs): GetPatchBaselineResult =
getPatchBaselineResultToKotlin(getPatchBaselinePlain(argument.toJava()).await())
/**
* @see [getPatchBaseline].
* @param id The ID of the patch baseline.
* @return null
*/
public suspend fun getPatchBaseline(id: String): GetPatchBaselineResult {
val argument = GetPatchBaselinePlainArgs(
id = id,
)
return getPatchBaselineResultToKotlin(getPatchBaselinePlain(argument.toJava()).await())
}
/**
* @see [getPatchBaseline].
* @param argument Builder for [com.pulumi.awsnative.ssm.kotlin.inputs.GetPatchBaselinePlainArgs].
* @return null
*/
public suspend fun getPatchBaseline(argument: suspend GetPatchBaselinePlainArgsBuilder.() -> Unit): GetPatchBaselineResult {
val builder = GetPatchBaselinePlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getPatchBaselineResultToKotlin(getPatchBaselinePlain(builtArgument.toJava()).await())
}
/**
* Resource Type definition for AWS::SSM::ResourceDataSync
* @param argument null
* @return null
*/
public suspend fun getResourceDataSync(argument: GetResourceDataSyncPlainArgs): GetResourceDataSyncResult =
getResourceDataSyncResultToKotlin(getResourceDataSyncPlain(argument.toJava()).await())
/**
* @see [getResourceDataSync].
* @param syncName A name for the resource data sync.
* @return null
*/
public suspend fun getResourceDataSync(syncName: String): GetResourceDataSyncResult {
val argument = GetResourceDataSyncPlainArgs(
syncName = syncName,
)
return getResourceDataSyncResultToKotlin(getResourceDataSyncPlain(argument.toJava()).await())
}
/**
* @see [getResourceDataSync].
* @param argument Builder for [com.pulumi.awsnative.ssm.kotlin.inputs.GetResourceDataSyncPlainArgs].
* @return null
*/
public suspend fun getResourceDataSync(argument: suspend GetResourceDataSyncPlainArgsBuilder.() -> Unit): GetResourceDataSyncResult {
val builder = GetResourceDataSyncPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getResourceDataSyncResultToKotlin(getResourceDataSyncPlain(builtArgument.toJava()).await())
}
/**
* Resource Type definition for AWS::SSM::ResourcePolicy
* @param argument null
* @return null
*/
public suspend fun getResourcePolicy(argument: GetResourcePolicyPlainArgs): GetResourcePolicyResult =
getResourcePolicyResultToKotlin(getResourcePolicyPlain(argument.toJava()).await())
/**
* @see [getResourcePolicy].
* @param policyId An unique identifier within the policies of a resource.
* @param resourceArn Arn of OpsItemGroup etc.
* @return null
*/
public suspend fun getResourcePolicy(policyId: String, resourceArn: String): GetResourcePolicyResult {
val argument = GetResourcePolicyPlainArgs(
policyId = policyId,
resourceArn = resourceArn,
)
return getResourcePolicyResultToKotlin(getResourcePolicyPlain(argument.toJava()).await())
}
/**
* @see [getResourcePolicy].
* @param argument Builder for [com.pulumi.awsnative.ssm.kotlin.inputs.GetResourcePolicyPlainArgs].
* @return null
*/
public suspend fun getResourcePolicy(argument: suspend GetResourcePolicyPlainArgsBuilder.() -> Unit): GetResourcePolicyResult {
val builder = GetResourcePolicyPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getResourcePolicyResultToKotlin(getResourcePolicyPlain(builtArgument.toJava()).await())
}
}