@mapped/pulumi-astra
Version:
A Pulumi package for creating and managing astra cloud resources.
93 lines (92 loc) • 3.08 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* `astra.Token` resource represents a token with a specific role assigned.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as astra from "@pulumi/astra";
*
* const example = new astra.Token("example", {
* roles: ["a8cd363d-5069-4a2b-86d8-0578139812ac"],
* });
* ```
*
* ## Import
*
* ```sh
* $ pulumi import astra:index/token:Token example client-secret
* ```
*/
export declare class Token extends pulumi.CustomResource {
/**
* Get an existing Token resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: TokenState, opts?: pulumi.CustomResourceOptions): Token;
/**
* Returns true if the given object is an instance of Token. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is Token;
/**
* Client id, use as username in cql to connect
*/
readonly clientId: pulumi.Output<string>;
/**
* List of Role IDs to be assigned to the generated token
*/
readonly roles: pulumi.Output<string[]>;
/**
* Secret, use as password in cql to connect
*/
readonly secret: pulumi.Output<string>;
/**
* Token, use as auth bearer for API calls or as password in combination with the word `token` in cql
*/
readonly token: pulumi.Output<string>;
/**
* Create a Token resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args: TokenArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering Token resources.
*/
export interface TokenState {
/**
* Client id, use as username in cql to connect
*/
clientId?: pulumi.Input<string>;
/**
* List of Role IDs to be assigned to the generated token
*/
roles?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Secret, use as password in cql to connect
*/
secret?: pulumi.Input<string>;
/**
* Token, use as auth bearer for API calls or as password in combination with the word `token` in cql
*/
token?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a Token resource.
*/
export interface TokenArgs {
/**
* List of Role IDs to be assigned to the generated token
*/
roles: pulumi.Input<pulumi.Input<string>[]>;
}