@pulumi/azuread
Version:
A Pulumi package for creating and managing Azure Active Directory (Azure AD) cloud resources.
126 lines (125 loc) • 5.56 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azuread from "@pulumi/azuread";
*
* const authorized = new azuread.ApplicationRegistration("authorized", {displayName: "example-authorized-app"});
* const authorizer = new azuread.Application("authorizer", {
* displayName: "example-authorizing-app",
* api: {
* oauth2PermissionScopes: [
* {
* adminConsentDescription: "Administer the application",
* adminConsentDisplayName: "Administer",
* enabled: true,
* id: "00000000-0000-0000-0000-000000000000",
* type: "Admin",
* value: "administer",
* },
* {
* adminConsentDescription: "Access the application",
* adminConsentDisplayName: "Access",
* enabled: true,
* id: "11111111-1111-1111-1111-111111111111",
* type: "User",
* userConsentDescription: "Access the application",
* userConsentDisplayName: "Access",
* value: "user_impersonation",
* },
* ],
* },
* });
* const example = new azuread.ApplicationPreAuthorized("example", {
* applicationId: authorizer.id,
* authorizedClientId: authorized.clientId,
* permissionIds: [
* "00000000-0000-0000-0000-000000000000",
* "11111111-1111-1111-1111-111111111111",
* ],
* });
* ```
*
* ## Import
*
* Pre-authorized applications can be imported using the object ID of the authorizing application and the application ID of the application being authorized, e.g.
*
* ```sh
* $ pulumi import azuread:index/applicationPreAuthorized:ApplicationPreAuthorized example 00000000-0000-0000-0000-000000000000/preAuthorizedApplication/11111111-1111-1111-1111-111111111111
* ```
*
* -> This ID format is unique to Terraform and is composed of the authorizing application's object ID, the string "preAuthorizedApplication" and the authorized application's application ID (client ID) in the format `{ObjectId}/preAuthorizedApplication/{ApplicationId}`.
*/
export declare class ApplicationPreAuthorized extends pulumi.CustomResource {
/**
* Get an existing ApplicationPreAuthorized 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?: ApplicationPreAuthorizedState, opts?: pulumi.CustomResourceOptions): ApplicationPreAuthorized;
/**
* Returns true if the given object is an instance of ApplicationPreAuthorized. 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 ApplicationPreAuthorized;
/**
* The resource ID of the application for which permissions are being authorized. Changing this field forces a new resource to be created.
*/
readonly applicationId: pulumi.Output<string>;
/**
* The client ID of the application being authorized. Changing this field forces a new resource to be created.
*/
readonly authorizedClientId: pulumi.Output<string>;
/**
* A set of permission scope IDs required by the authorized application.
*/
readonly permissionIds: pulumi.Output<string[]>;
/**
* Create a ApplicationPreAuthorized 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: ApplicationPreAuthorizedArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering ApplicationPreAuthorized resources.
*/
export interface ApplicationPreAuthorizedState {
/**
* The resource ID of the application for which permissions are being authorized. Changing this field forces a new resource to be created.
*/
applicationId?: pulumi.Input<string>;
/**
* The client ID of the application being authorized. Changing this field forces a new resource to be created.
*/
authorizedClientId?: pulumi.Input<string>;
/**
* A set of permission scope IDs required by the authorized application.
*/
permissionIds?: pulumi.Input<pulumi.Input<string>[]>;
}
/**
* The set of arguments for constructing a ApplicationPreAuthorized resource.
*/
export interface ApplicationPreAuthorizedArgs {
/**
* The resource ID of the application for which permissions are being authorized. Changing this field forces a new resource to be created.
*/
applicationId: pulumi.Input<string>;
/**
* The client ID of the application being authorized. Changing this field forces a new resource to be created.
*/
authorizedClientId: pulumi.Input<string>;
/**
* A set of permission scope IDs required by the authorized application.
*/
permissionIds: pulumi.Input<pulumi.Input<string>[]>;
}