@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
95 lines (94 loc) • 2.7 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Use this data source to get the ARN of a topic in AWS Simple Notification
* Service (SNS). By using this data source, you can reference SNS topics
* without having to hard code the ARNs as input.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const example = aws.sns.getTopic({
* name: "an_example_topic",
* });
* ```
*/
export declare function getTopic(args: GetTopicArgs, opts?: pulumi.InvokeOptions): Promise<GetTopicResult>;
/**
* A collection of arguments for invoking getTopic.
*/
export interface GetTopicArgs {
/**
* Friendly name of the topic to match.
*/
name: string;
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
region?: string;
/**
* Map of tags for the resource.
*/
tags?: {
[key: string]: string;
};
}
/**
* A collection of values returned by getTopic.
*/
export interface GetTopicResult {
/**
* ARN of the found topic, suitable for referencing in other resources that support SNS topics.
*/
readonly arn: string;
/**
* The provider-assigned unique ID for this managed resource.
*/
readonly id: string;
readonly name: string;
readonly region: string;
/**
* Map of tags for the resource.
*/
readonly tags: {
[key: string]: string;
};
}
/**
* Use this data source to get the ARN of a topic in AWS Simple Notification
* Service (SNS). By using this data source, you can reference SNS topics
* without having to hard code the ARNs as input.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const example = aws.sns.getTopic({
* name: "an_example_topic",
* });
* ```
*/
export declare function getTopicOutput(args: GetTopicOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetTopicResult>;
/**
* A collection of arguments for invoking getTopic.
*/
export interface GetTopicOutputArgs {
/**
* Friendly name of the topic to match.
*/
name: pulumi.Input<string>;
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
region?: pulumi.Input<string>;
/**
* Map of tags for the resource.
*/
tags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
}