1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. resourcemanager
  5. getDelegatedAdministrators
Alibaba Cloud v3.75.0 published on Friday, Mar 7, 2025 by Pulumi

alicloud.resourcemanager.getDelegatedAdministrators

Explore with Pulumi AI

This data source provides the Resource Manager Delegated Administrators of the current Alibaba Cloud user.

NOTE: Available in v1.181.0+.

Example Usage

Basic Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const ids = alicloud.resourcemanager.getDelegatedAdministrators({
    ids: ["example_value"],
});
export const resourceManagerDelegatedAdministratorId1 = ids.then(ids => ids.administrators?.[0]?.id);
Copy
import pulumi
import pulumi_alicloud as alicloud

ids = alicloud.resourcemanager.get_delegated_administrators(ids=["example_value"])
pulumi.export("resourceManagerDelegatedAdministratorId1", ids.administrators[0].id)
Copy
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/resourcemanager"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		ids, err := resourcemanager.GetDelegatedAdministrators(ctx, &resourcemanager.GetDelegatedAdministratorsArgs{
			Ids: []string{
				"example_value",
			},
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("resourceManagerDelegatedAdministratorId1", ids.Administrators[0].Id)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var ids = AliCloud.ResourceManager.GetDelegatedAdministrators.Invoke(new()
    {
        Ids = new[]
        {
            "example_value",
        },
    });

    return new Dictionary<string, object?>
    {
        ["resourceManagerDelegatedAdministratorId1"] = ids.Apply(getDelegatedAdministratorsResult => getDelegatedAdministratorsResult.Administrators[0]?.Id),
    };
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.resourcemanager.ResourcemanagerFunctions;
import com.pulumi.alicloud.resourcemanager.inputs.GetDelegatedAdministratorsArgs;
import java.util.List;
import java.util.ArrayList;
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 ids = ResourcemanagerFunctions.getDelegatedAdministrators(GetDelegatedAdministratorsArgs.builder()
            .ids("example_value")
            .build());

        ctx.export("resourceManagerDelegatedAdministratorId1", ids.applyValue(getDelegatedAdministratorsResult -> getDelegatedAdministratorsResult.administrators()[0].id()));
    }
}
Copy
variables:
  ids:
    fn::invoke:
      function: alicloud:resourcemanager:getDelegatedAdministrators
      arguments:
        ids:
          - example_value
outputs:
  resourceManagerDelegatedAdministratorId1: ${ids.administrators[0].id}
Copy

Using getDelegatedAdministrators

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 getDelegatedAdministrators(args: GetDelegatedAdministratorsArgs, opts?: InvokeOptions): Promise<GetDelegatedAdministratorsResult>
function getDelegatedAdministratorsOutput(args: GetDelegatedAdministratorsOutputArgs, opts?: InvokeOptions): Output<GetDelegatedAdministratorsResult>
Copy
def get_delegated_administrators(ids: Optional[Sequence[str]] = None,
                                 output_file: Optional[str] = None,
                                 page_number: Optional[int] = None,
                                 page_size: Optional[int] = None,
                                 service_principal: Optional[str] = None,
                                 opts: Optional[InvokeOptions] = None) -> GetDelegatedAdministratorsResult
def get_delegated_administrators_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                                 output_file: Optional[pulumi.Input[str]] = None,
                                 page_number: Optional[pulumi.Input[int]] = None,
                                 page_size: Optional[pulumi.Input[int]] = None,
                                 service_principal: Optional[pulumi.Input[str]] = None,
                                 opts: Optional[InvokeOptions] = None) -> Output[GetDelegatedAdministratorsResult]
Copy
func GetDelegatedAdministrators(ctx *Context, args *GetDelegatedAdministratorsArgs, opts ...InvokeOption) (*GetDelegatedAdministratorsResult, error)
func GetDelegatedAdministratorsOutput(ctx *Context, args *GetDelegatedAdministratorsOutputArgs, opts ...InvokeOption) GetDelegatedAdministratorsResultOutput
Copy

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

public static class GetDelegatedAdministrators 
{
    public static Task<GetDelegatedAdministratorsResult> InvokeAsync(GetDelegatedAdministratorsArgs args, InvokeOptions? opts = null)
    public static Output<GetDelegatedAdministratorsResult> Invoke(GetDelegatedAdministratorsInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetDelegatedAdministratorsResult> getDelegatedAdministrators(GetDelegatedAdministratorsArgs args, InvokeOptions options)
public static Output<GetDelegatedAdministratorsResult> getDelegatedAdministrators(GetDelegatedAdministratorsArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: alicloud:resourcemanager/getDelegatedAdministrators:getDelegatedAdministrators
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Ids Changes to this property will trigger replacement. List<string>
A list of Delegated Administrator IDs.
OutputFile string
File name where to save data source results (after running pulumi preview).
PageNumber int
PageSize int
ServicePrincipal Changes to this property will trigger replacement. string
The identification of the trusted service.
Ids Changes to this property will trigger replacement. []string
A list of Delegated Administrator IDs.
OutputFile string
File name where to save data source results (after running pulumi preview).
PageNumber int
PageSize int
ServicePrincipal Changes to this property will trigger replacement. string
The identification of the trusted service.
ids Changes to this property will trigger replacement. List<String>
A list of Delegated Administrator IDs.
outputFile String
File name where to save data source results (after running pulumi preview).
pageNumber Integer
pageSize Integer
servicePrincipal Changes to this property will trigger replacement. String
The identification of the trusted service.
ids Changes to this property will trigger replacement. string[]
A list of Delegated Administrator IDs.
outputFile string
File name where to save data source results (after running pulumi preview).
pageNumber number
pageSize number
servicePrincipal Changes to this property will trigger replacement. string
The identification of the trusted service.
ids Changes to this property will trigger replacement. Sequence[str]
A list of Delegated Administrator IDs.
output_file str
File name where to save data source results (after running pulumi preview).
page_number int
page_size int
service_principal Changes to this property will trigger replacement. str
The identification of the trusted service.
ids Changes to this property will trigger replacement. List<String>
A list of Delegated Administrator IDs.
outputFile String
File name where to save data source results (after running pulumi preview).
pageNumber Number
pageSize Number
servicePrincipal Changes to this property will trigger replacement. String
The identification of the trusted service.

getDelegatedAdministrators Result

The following output properties are available:

Administrators List<Pulumi.AliCloud.ResourceManager.Outputs.GetDelegatedAdministratorsAdministrator>
Id string
The provider-assigned unique ID for this managed resource.
Ids List<string>
OutputFile string
PageNumber int
PageSize int
ServicePrincipal string
Administrators []GetDelegatedAdministratorsAdministrator
Id string
The provider-assigned unique ID for this managed resource.
Ids []string
OutputFile string
PageNumber int
PageSize int
ServicePrincipal string
administrators List<GetDelegatedAdministratorsAdministrator>
id String
The provider-assigned unique ID for this managed resource.
ids List<String>
outputFile String
pageNumber Integer
pageSize Integer
servicePrincipal String
administrators GetDelegatedAdministratorsAdministrator[]
id string
The provider-assigned unique ID for this managed resource.
ids string[]
outputFile string
pageNumber number
pageSize number
servicePrincipal string
administrators Sequence[GetDelegatedAdministratorsAdministrator]
id str
The provider-assigned unique ID for this managed resource.
ids Sequence[str]
output_file str
page_number int
page_size int
service_principal str
administrators List<Property Map>
id String
The provider-assigned unique ID for this managed resource.
ids List<String>
outputFile String
pageNumber Number
pageSize Number
servicePrincipal String

Supporting Types

GetDelegatedAdministratorsAdministrator

AccountId This property is required. string
The ID of the member account.
DelegationEnabledTime This property is required. string
The time when the member was specified as a delegated administrator account.
Id This property is required. string
The ID of the Delegated Administrator.
ServicePrincipal This property is required. string
The identity of the trusted service.
AccountId This property is required. string
The ID of the member account.
DelegationEnabledTime This property is required. string
The time when the member was specified as a delegated administrator account.
Id This property is required. string
The ID of the Delegated Administrator.
ServicePrincipal This property is required. string
The identity of the trusted service.
accountId This property is required. String
The ID of the member account.
delegationEnabledTime This property is required. String
The time when the member was specified as a delegated administrator account.
id This property is required. String
The ID of the Delegated Administrator.
servicePrincipal This property is required. String
The identity of the trusted service.
accountId This property is required. string
The ID of the member account.
delegationEnabledTime This property is required. string
The time when the member was specified as a delegated administrator account.
id This property is required. string
The ID of the Delegated Administrator.
servicePrincipal This property is required. string
The identity of the trusted service.
account_id This property is required. str
The ID of the member account.
delegation_enabled_time This property is required. str
The time when the member was specified as a delegated administrator account.
id This property is required. str
The ID of the Delegated Administrator.
service_principal This property is required. str
The identity of the trusted service.
accountId This property is required. String
The ID of the member account.
delegationEnabledTime This property is required. String
The time when the member was specified as a delegated administrator account.
id This property is required. String
The ID of the Delegated Administrator.
servicePrincipal This property is required. String
The identity of the trusted service.

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.