
com.pulumi.awsnative.sns.kotlin.SnsFunctions.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.sns.kotlin
import com.pulumi.awsnative.sns.SnsFunctions.getTopicInlinePolicyPlain
import com.pulumi.awsnative.sns.SnsFunctions.getTopicPlain
import com.pulumi.awsnative.sns.SnsFunctions.getTopicPolicyPlain
import com.pulumi.awsnative.sns.kotlin.inputs.GetTopicInlinePolicyPlainArgs
import com.pulumi.awsnative.sns.kotlin.inputs.GetTopicInlinePolicyPlainArgsBuilder
import com.pulumi.awsnative.sns.kotlin.inputs.GetTopicPlainArgs
import com.pulumi.awsnative.sns.kotlin.inputs.GetTopicPlainArgsBuilder
import com.pulumi.awsnative.sns.kotlin.inputs.GetTopicPolicyPlainArgs
import com.pulumi.awsnative.sns.kotlin.inputs.GetTopicPolicyPlainArgsBuilder
import com.pulumi.awsnative.sns.kotlin.outputs.GetTopicInlinePolicyResult
import com.pulumi.awsnative.sns.kotlin.outputs.GetTopicPolicyResult
import com.pulumi.awsnative.sns.kotlin.outputs.GetTopicResult
import kotlinx.coroutines.future.await
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import com.pulumi.awsnative.sns.kotlin.outputs.GetTopicInlinePolicyResult.Companion.toKotlin as getTopicInlinePolicyResultToKotlin
import com.pulumi.awsnative.sns.kotlin.outputs.GetTopicPolicyResult.Companion.toKotlin as getTopicPolicyResultToKotlin
import com.pulumi.awsnative.sns.kotlin.outputs.GetTopicResult.Companion.toKotlin as getTopicResultToKotlin
public object SnsFunctions {
/**
* The ``AWS::SNS::Topic`` resource creates a topic to which notifications can be published.
* One account can create a maximum of 100,000 standard topics and 1,000 FIFO topics. For more information, see [endpoints and quotas](https://docs.aws.amazon.com/general/latest/gr/sns.html) in the *General Reference*.
* The structure of ``AUTHPARAMS`` depends on the .signature of the API request. For more information, see [Examples of the complete Signature Version 4 signing process](https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html) in the *General Reference*.
* @param argument null
* @return null
*/
public suspend fun getTopic(argument: GetTopicPlainArgs): GetTopicResult =
getTopicResultToKotlin(getTopicPlain(argument.toJava()).await())
/**
* @see [getTopic].
* @param topicArn Returns the ARN of an Amazon SNS topic.
* @return null
*/
public suspend fun getTopic(topicArn: String): GetTopicResult {
val argument = GetTopicPlainArgs(
topicArn = topicArn,
)
return getTopicResultToKotlin(getTopicPlain(argument.toJava()).await())
}
/**
* @see [getTopic].
* @param argument Builder for [com.pulumi.awsnative.sns.kotlin.inputs.GetTopicPlainArgs].
* @return null
*/
public suspend fun getTopic(argument: suspend GetTopicPlainArgsBuilder.() -> Unit): GetTopicResult {
val builder = GetTopicPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getTopicResultToKotlin(getTopicPlain(builtArgument.toJava()).await())
}
/**
* Schema for AWS::SNS::TopicInlinePolicy
* @param argument null
* @return null
*/
public suspend fun getTopicInlinePolicy(argument: GetTopicInlinePolicyPlainArgs): GetTopicInlinePolicyResult =
getTopicInlinePolicyResultToKotlin(getTopicInlinePolicyPlain(argument.toJava()).await())
/**
* @see [getTopicInlinePolicy].
* @param topicArn The Amazon Resource Name (ARN) of the topic to which you want to add the policy.
* @return null
*/
public suspend fun getTopicInlinePolicy(topicArn: String): GetTopicInlinePolicyResult {
val argument = GetTopicInlinePolicyPlainArgs(
topicArn = topicArn,
)
return getTopicInlinePolicyResultToKotlin(getTopicInlinePolicyPlain(argument.toJava()).await())
}
/**
* @see [getTopicInlinePolicy].
* @param argument Builder for [com.pulumi.awsnative.sns.kotlin.inputs.GetTopicInlinePolicyPlainArgs].
* @return null
*/
public suspend fun getTopicInlinePolicy(argument: suspend GetTopicInlinePolicyPlainArgsBuilder.() -> Unit): GetTopicInlinePolicyResult {
val builder = GetTopicInlinePolicyPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getTopicInlinePolicyResultToKotlin(getTopicInlinePolicyPlain(builtArgument.toJava()).await())
}
/**
* The ``AWS::SNS::TopicPolicy`` resource associates SNS topics with a policy. For an example snippet, see [Declaring an policy](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/quickref-iam.html#scenario-sns-policy) in the *User Guide*.
* @param argument null
* @return null
*/
public suspend fun getTopicPolicy(argument: GetTopicPolicyPlainArgs): GetTopicPolicyResult =
getTopicPolicyResultToKotlin(getTopicPolicyPlain(argument.toJava()).await())
/**
* @see [getTopicPolicy].
* @param id The provider-assigned unique ID for this managed resource.
* @return null
*/
public suspend fun getTopicPolicy(id: String): GetTopicPolicyResult {
val argument = GetTopicPolicyPlainArgs(
id = id,
)
return getTopicPolicyResultToKotlin(getTopicPolicyPlain(argument.toJava()).await())
}
/**
* @see [getTopicPolicy].
* @param argument Builder for [com.pulumi.awsnative.sns.kotlin.inputs.GetTopicPolicyPlainArgs].
* @return null
*/
public suspend fun getTopicPolicy(argument: suspend GetTopicPolicyPlainArgsBuilder.() -> Unit): GetTopicPolicyResult {
val builder = GetTopicPolicyPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getTopicPolicyResultToKotlin(getTopicPolicyPlain(builtArgument.toJava()).await())
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy