import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Manage a Data Factory Service Principal credential resource. These resources are used by Data Factory to access data sources. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as azure from "@pulumi/azure"; * * const current = azure.core.getClientConfig({}); * const example = new azure.core.ResourceGroup("example", { * name: "example-resources", * location: "westeurope", * }); * const exampleFactory = new azure.datafactory.Factory("example", { * name: "example", * location: example.location, * resourceGroupName: example.name, * }); * const exampleKeyVault = new azure.keyvault.KeyVault("example", { * name: "example", * location: example.location, * resourceGroupName: example.name, * tenantId: current.then(current => current.tenantId), * skuName: "premium", * softDeleteRetentionDays: 7, * accessPolicies: [{ * tenantId: current.then(current => current.tenantId), * objectId: current.then(current => current.objectId), * keyPermissions: [ * "Create", * "Get", * ], * secretPermissions: [ * "Set", * "Get", * "Delete", * "Purge", * "Recover", * ], * }], * }); * const exampleSecret = new azure.keyvault.Secret("example", { * name: "example", * value: "example-secret", * keyVaultId: exampleKeyVault.id, * }); * const exampleLinkedServiceKeyVault = new azure.datafactory.LinkedServiceKeyVault("example", { * name: "example", * dataFactoryId: exampleFactory.id, * keyVaultId: exampleKeyVault.id, * }); * const exampleCredentialServicePrincipal = new azure.datafactory.CredentialServicePrincipal("example", { * name: "example", * description: "example description", * dataFactoryId: exampleFactory.id, * tenantId: current.then(current => current.tenantId), * servicePrincipalId: current.then(current => current.clientId), * servicePrincipalKey: { * linkedServiceName: exampleLinkedServiceKeyVault.name, * secretName: exampleSecret.name, * secretVersion: exampleSecret.version, * }, * annotations: [ * "1", * "2", * ], * }); * ``` * * ## API Providers * * * This resource uses the following Azure API Providers: * * * `Microsoft.DataFactory` - 2018-06-01 * * ## Import * * Data Factory Credentials can be imported using the `resource id`, e.g. * * ```sh * $ pulumi import azure:datafactory/credentialServicePrincipal:CredentialServicePrincipal example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example-resources/providers/Microsoft.DataFactory/factories/example/credentials/credential1 * ``` */ export declare class CredentialServicePrincipal extends pulumi.CustomResource { /** * Get an existing CredentialServicePrincipal 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, state?: CredentialServicePrincipalState, opts?: pulumi.CustomResourceOptions): CredentialServicePrincipal; /** * Returns true if the given object is an instance of CredentialServicePrincipal. 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 CredentialServicePrincipal; /** * List of tags that can be used for describing the Data Factory Credential. */ readonly annotations: pulumi.Output; /** * The Data Factory ID in which to associate the Credential with. Changing this forces a new resource. */ readonly dataFactoryId: pulumi.Output; /** * The description for the Data Factory Credential. */ readonly description: pulumi.Output; /** * Specifies the name of the Credential. Changing this forces a new resource to be created. */ readonly name: pulumi.Output; /** * The Client ID of the Service Principal. */ readonly servicePrincipalId: pulumi.Output; /** * A `servicePrincipalKey` block as defined below. */ readonly servicePrincipalKey: pulumi.Output; /** * The Tenant ID of the Service Principal. */ readonly tenantId: pulumi.Output; /** * Create a CredentialServicePrincipal 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: CredentialServicePrincipalArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering CredentialServicePrincipal resources. */ export interface CredentialServicePrincipalState { /** * List of tags that can be used for describing the Data Factory Credential. */ annotations?: pulumi.Input[]>; /** * The Data Factory ID in which to associate the Credential with. Changing this forces a new resource. */ dataFactoryId?: pulumi.Input; /** * The description for the Data Factory Credential. */ description?: pulumi.Input; /** * Specifies the name of the Credential. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * The Client ID of the Service Principal. */ servicePrincipalId?: pulumi.Input; /** * A `servicePrincipalKey` block as defined below. */ servicePrincipalKey?: pulumi.Input; /** * The Tenant ID of the Service Principal. */ tenantId?: pulumi.Input; } /** * The set of arguments for constructing a CredentialServicePrincipal resource. */ export interface CredentialServicePrincipalArgs { /** * List of tags that can be used for describing the Data Factory Credential. */ annotations?: pulumi.Input[]>; /** * The Data Factory ID in which to associate the Credential with. Changing this forces a new resource. */ dataFactoryId: pulumi.Input; /** * The description for the Data Factory Credential. */ description?: pulumi.Input; /** * Specifies the name of the Credential. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * The Client ID of the Service Principal. */ servicePrincipalId: pulumi.Input; /** * A `servicePrincipalKey` block as defined below. */ servicePrincipalKey?: pulumi.Input; /** * The Tenant ID of the Service Principal. */ tenantId: pulumi.Input; }