1. Registry
  2. Packages
  3. Databricks Provider
  4. API Docs
  5. getAccountIamServicePrincipalV2
Viewing docs for Databricks v1.109.0
published on Tuesday, Sep 8, 2026 by Pulumi
databricks logo databricks logo
Viewing docs for Databricks v1.109.0
published on Tuesday, Sep 8, 2026 by Pulumi

    Public Beta

    API Documentation

    Reads a single account service principal by its internal ID.

    Example Usage

    Example usage:

    Look up an account service principal by its internal ID.

    import * as pulumi from "@pulumi/pulumi";
    import * as databricks from "@pulumi/databricks";
    
    const _this = databricks.getAccountIamServicePrincipalV2({
        servicePrincipalId: "123456789",
    });
    
    import pulumi
    import pulumi_databricks as databricks
    
    this = databricks.get_account_iam_service_principal_v2(service_principal_id="123456789")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-databricks/sdk/go/databricks"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := databricks.GetAccountIamServicePrincipalV2(ctx, &databricks.LookupAccountIamServicePrincipalV2Args{
    			ServicePrincipalId: "123456789",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Databricks = Pulumi.Databricks;
    
    return await Deployment.RunAsync(() => 
    {
        var @this = Databricks.GetAccountIamServicePrincipalV2.Invoke(new()
        {
            ServicePrincipalId = "123456789",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.databricks.DatabricksFunctions;
    import com.pulumi.databricks.inputs.GetAccountIamServicePrincipalV2Args;
    import java.util.ArrayList;
    import java.util.Arrays;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var this = DatabricksFunctions.getAccountIamServicePrincipalV2(GetAccountIamServicePrincipalV2Args.builder()
                .servicePrincipalId("123456789")
                .build());
    
        }
    }
    
    variables:
      this:
        fn::invoke:
          function: databricks:getAccountIamServicePrincipalV2
          arguments:
            servicePrincipalId: '123456789'
    
    pulumi {
      required_providers {
        databricks = {
          source = "pulumi/databricks"
        }
      }
    }
    
    data "databricks_getaccountiamserviceprincipalv2" "this" {
      service_principal_id = "123456789"
    }
    

    Using getAccountIamServicePrincipalV2

    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 getAccountIamServicePrincipalV2(args: GetAccountIamServicePrincipalV2Args, opts?: InvokeOptions): Promise<GetAccountIamServicePrincipalV2Result>
    function getAccountIamServicePrincipalV2Output(args: GetAccountIamServicePrincipalV2OutputArgs, opts?: InvokeOutputOptions): Output<GetAccountIamServicePrincipalV2Result>
    def get_account_iam_service_principal_v2(service_principal_id: Optional[str] = None,
                                             opts: Optional[InvokeOptions] = None) -> GetAccountIamServicePrincipalV2Result
    def get_account_iam_service_principal_v2_output(service_principal_id: pulumi.Input[Optional[str]] = None,
                                             opts: Optional[InvokeOutputOptions] = None) -> Output[GetAccountIamServicePrincipalV2Result]
    func LookupAccountIamServicePrincipalV2(ctx *Context, args *LookupAccountIamServicePrincipalV2Args, opts ...InvokeOption) (*LookupAccountIamServicePrincipalV2Result, error)
    func LookupAccountIamServicePrincipalV2Output(ctx *Context, args *LookupAccountIamServicePrincipalV2OutputArgs, opts ...InvokeOption) LookupAccountIamServicePrincipalV2ResultOutput

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

    public static class GetAccountIamServicePrincipalV2 
    {
        public static Task<GetAccountIamServicePrincipalV2Result> InvokeAsync(GetAccountIamServicePrincipalV2Args args, InvokeOptions? opts = null)
        public static Output<GetAccountIamServicePrincipalV2Result> Invoke(GetAccountIamServicePrincipalV2InvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetAccountIamServicePrincipalV2Result> Invoke(GetAccountIamServicePrincipalV2InvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetAccountIamServicePrincipalV2Result> getAccountIamServicePrincipalV2(GetAccountIamServicePrincipalV2Args args, InvokeOptions options)
    public static Output<GetAccountIamServicePrincipalV2Result> getAccountIamServicePrincipalV2(GetAccountIamServicePrincipalV2Args args, InvokeOptions options)
    public static Output<GetAccountIamServicePrincipalV2Result> getAccountIamServicePrincipalV2(GetAccountIamServicePrincipalV2Args args, InvokeOutputOptions options)
    
    fn::invoke:
      function: databricks:index/getAccountIamServicePrincipalV2:getAccountIamServicePrincipalV2
      arguments:
        # arguments dictionary
    data "databricks_get_account_iam_service_principal_v2" "name" {
        # arguments
    }

    The following arguments are supported:

    ServicePrincipalId string
    Internal service principal ID of the service principal in Databricks
    ServicePrincipalId string
    Internal service principal ID of the service principal in Databricks
    service_principal_id string
    Internal service principal ID of the service principal in Databricks
    servicePrincipalId String
    Internal service principal ID of the service principal in Databricks
    servicePrincipalId string
    Internal service principal ID of the service principal in Databricks
    service_principal_id str
    Internal service principal ID of the service principal in Databricks
    servicePrincipalId String
    Internal service principal ID of the service principal in Databricks

    getAccountIamServicePrincipalV2 Result

    The following output properties are available:

    AccountId string
    (string) - The parent account ID for the service principal in Databricks
    AccountSpStatus string
    (string) - The activity status of a service principal in a Databricks account. Possible values are: ACTIVE, INACTIVE
    ApplicationId string
    (string) - Application ID of the service principal. Set at creation time and cannot be changed afterwards; when omitted, the server generates one
    DisplayName string
    (string) - Display name of the service principal
    ExternalId string
    (string) - ExternalId of the service principal in the customer's IdP
    ServicePrincipalId string
    (string) - Internal service principal ID of the service principal in Databricks
    AccountId string
    (string) - The parent account ID for the service principal in Databricks
    AccountSpStatus string
    (string) - The activity status of a service principal in a Databricks account. Possible values are: ACTIVE, INACTIVE
    ApplicationId string
    (string) - Application ID of the service principal. Set at creation time and cannot be changed afterwards; when omitted, the server generates one
    DisplayName string
    (string) - Display name of the service principal
    ExternalId string
    (string) - ExternalId of the service principal in the customer's IdP
    ServicePrincipalId string
    (string) - Internal service principal ID of the service principal in Databricks
    account_id string
    (string) - The parent account ID for the service principal in Databricks
    account_sp_status string
    (string) - The activity status of a service principal in a Databricks account. Possible values are: ACTIVE, INACTIVE
    application_id string
    (string) - Application ID of the service principal. Set at creation time and cannot be changed afterwards; when omitted, the server generates one
    display_name string
    (string) - Display name of the service principal
    external_id string
    (string) - ExternalId of the service principal in the customer's IdP
    service_principal_id string
    (string) - Internal service principal ID of the service principal in Databricks
    accountId String
    (string) - The parent account ID for the service principal in Databricks
    accountSpStatus String
    (string) - The activity status of a service principal in a Databricks account. Possible values are: ACTIVE, INACTIVE
    applicationId String
    (string) - Application ID of the service principal. Set at creation time and cannot be changed afterwards; when omitted, the server generates one
    displayName String
    (string) - Display name of the service principal
    externalId String
    (string) - ExternalId of the service principal in the customer's IdP
    servicePrincipalId String
    (string) - Internal service principal ID of the service principal in Databricks
    accountId string
    (string) - The parent account ID for the service principal in Databricks
    accountSpStatus string
    (string) - The activity status of a service principal in a Databricks account. Possible values are: ACTIVE, INACTIVE
    applicationId string
    (string) - Application ID of the service principal. Set at creation time and cannot be changed afterwards; when omitted, the server generates one
    displayName string
    (string) - Display name of the service principal
    externalId string
    (string) - ExternalId of the service principal in the customer's IdP
    servicePrincipalId string
    (string) - Internal service principal ID of the service principal in Databricks
    account_id str
    (string) - The parent account ID for the service principal in Databricks
    account_sp_status str
    (string) - The activity status of a service principal in a Databricks account. Possible values are: ACTIVE, INACTIVE
    application_id str
    (string) - Application ID of the service principal. Set at creation time and cannot be changed afterwards; when omitted, the server generates one
    display_name str
    (string) - Display name of the service principal
    external_id str
    (string) - ExternalId of the service principal in the customer's IdP
    service_principal_id str
    (string) - Internal service principal ID of the service principal in Databricks
    accountId String
    (string) - The parent account ID for the service principal in Databricks
    accountSpStatus String
    (string) - The activity status of a service principal in a Databricks account. Possible values are: ACTIVE, INACTIVE
    applicationId String
    (string) - Application ID of the service principal. Set at creation time and cannot be changed afterwards; when omitted, the server generates one
    displayName String
    (string) - Display name of the service principal
    externalId String
    (string) - ExternalId of the service principal in the customer's IdP
    servicePrincipalId String
    (string) - Internal service principal ID of the service principal in Databricks

    Package Details

    Repository
    databricks pulumi/pulumi-databricks
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the databricks Terraform Provider.
    databricks logo databricks logo
    Viewing docs for Databricks v1.109.0
    published on Tuesday, Sep 8, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial