1. Packages
  2. Azure Classic
  3. API Docs
  4. keyvault
  5. getSecrets

We recommend using Azure Native.

Azure v6.10.0 published on Tuesday, Nov 19, 2024 by Pulumi

azure.keyvault.getSecrets

Explore with Pulumi AI

azure logo

We recommend using Azure Native.

Azure v6.10.0 published on Tuesday, Nov 19, 2024 by Pulumi

    Use this data source to retrieve a list of secret names from an existing Key Vault Secret.

    Using getSecrets

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getSecrets(args: GetSecretsArgs, opts?: InvokeOptions): Promise<GetSecretsResult>
    function getSecretsOutput(args: GetSecretsOutputArgs, opts?: InvokeOptions): Output<GetSecretsResult>
    def get_secrets(key_vault_id: Optional[str] = None,
                    opts: Optional[InvokeOptions] = None) -> GetSecretsResult
    def get_secrets_output(key_vault_id: Optional[pulumi.Input[str]] = None,
                    opts: Optional[InvokeOptions] = None) -> Output[GetSecretsResult]
    func GetSecrets(ctx *Context, args *GetSecretsArgs, opts ...InvokeOption) (*GetSecretsResult, error)
    func GetSecretsOutput(ctx *Context, args *GetSecretsOutputArgs, opts ...InvokeOption) GetSecretsResultOutput

    > Note: This function is named GetSecrets in the Go SDK.

    public static class GetSecrets 
    {
        public static Task<GetSecretsResult> InvokeAsync(GetSecretsArgs args, InvokeOptions? opts = null)
        public static Output<GetSecretsResult> Invoke(GetSecretsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetSecretsResult> getSecrets(GetSecretsArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: azure:keyvault/getSecrets:getSecrets
      arguments:
        # arguments dictionary

    The following arguments are supported:

    KeyVaultId string

    Specifies the ID of the Key Vault instance to fetch secret names from, available on the azure.keyvault.KeyVault Data Source / Resource.

    NOTE: The vault must be in the same subscription as the provider. If the vault is in another subscription, you must create an aliased provider for that subscription.

    KeyVaultId string

    Specifies the ID of the Key Vault instance to fetch secret names from, available on the azure.keyvault.KeyVault Data Source / Resource.

    NOTE: The vault must be in the same subscription as the provider. If the vault is in another subscription, you must create an aliased provider for that subscription.

    keyVaultId String

    Specifies the ID of the Key Vault instance to fetch secret names from, available on the azure.keyvault.KeyVault Data Source / Resource.

    NOTE: The vault must be in the same subscription as the provider. If the vault is in another subscription, you must create an aliased provider for that subscription.

    keyVaultId string

    Specifies the ID of the Key Vault instance to fetch secret names from, available on the azure.keyvault.KeyVault Data Source / Resource.

    NOTE: The vault must be in the same subscription as the provider. If the vault is in another subscription, you must create an aliased provider for that subscription.

    key_vault_id str

    Specifies the ID of the Key Vault instance to fetch secret names from, available on the azure.keyvault.KeyVault Data Source / Resource.

    NOTE: The vault must be in the same subscription as the provider. If the vault is in another subscription, you must create an aliased provider for that subscription.

    keyVaultId String

    Specifies the ID of the Key Vault instance to fetch secret names from, available on the azure.keyvault.KeyVault Data Source / Resource.

    NOTE: The vault must be in the same subscription as the provider. If the vault is in another subscription, you must create an aliased provider for that subscription.

    getSecrets Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    KeyVaultId string
    Names List<string>
    List containing names of secrets that exist in this Key Vault.
    Secrets List<GetSecretsSecret>
    One or more secrets blocks as defined below.
    Id string
    The provider-assigned unique ID for this managed resource.
    KeyVaultId string
    Names []string
    List containing names of secrets that exist in this Key Vault.
    Secrets []GetSecretsSecret
    One or more secrets blocks as defined below.
    id String
    The provider-assigned unique ID for this managed resource.
    keyVaultId String
    names List<String>
    List containing names of secrets that exist in this Key Vault.
    secrets List<GetSecretsSecret>
    One or more secrets blocks as defined below.
    id string
    The provider-assigned unique ID for this managed resource.
    keyVaultId string
    names string[]
    List containing names of secrets that exist in this Key Vault.
    secrets GetSecretsSecret[]
    One or more secrets blocks as defined below.
    id str
    The provider-assigned unique ID for this managed resource.
    key_vault_id str
    names Sequence[str]
    List containing names of secrets that exist in this Key Vault.
    secrets Sequence[GetSecretsSecret]
    One or more secrets blocks as defined below.
    id String
    The provider-assigned unique ID for this managed resource.
    keyVaultId String
    names List<String>
    List containing names of secrets that exist in this Key Vault.
    secrets List<Property Map>
    One or more secrets blocks as defined below.

    Supporting Types

    GetSecretsSecret

    Enabled bool
    Whether this secret is enabled.
    Id string
    The ID of this secret.
    Name string
    The name of secret.
    Tags Dictionary<string, string>
    The tags of this secret.
    Enabled bool
    Whether this secret is enabled.
    Id string
    The ID of this secret.
    Name string
    The name of secret.
    Tags map[string]string
    The tags of this secret.
    enabled Boolean
    Whether this secret is enabled.
    id String
    The ID of this secret.
    name String
    The name of secret.
    tags Map<String,String>
    The tags of this secret.
    enabled boolean
    Whether this secret is enabled.
    id string
    The ID of this secret.
    name string
    The name of secret.
    tags {[key: string]: string}
    The tags of this secret.
    enabled bool
    Whether this secret is enabled.
    id str
    The ID of this secret.
    name str
    The name of secret.
    tags Mapping[str, str]
    The tags of this secret.
    enabled Boolean
    Whether this secret is enabled.
    id String
    The ID of this secret.
    name String
    The name of secret.
    tags Map<String>
    The tags of this secret.

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azurerm Terraform Provider.
    azure logo

    We recommend using Azure Native.

    Azure v6.10.0 published on Tuesday, Nov 19, 2024 by Pulumi