1. Packages
  2. Volcengine
  3. API Docs
  4. iam
  5. Users
Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine

volcengine.iam.Users

Explore with Pulumi AI

Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine

Use this data source to query detailed information of iam users

Example Usage

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

const fooUser = new volcengine.iam.User("fooUser", {
    userName: "acc-test-user",
    description: "acc test",
    displayName: "name",
});
const fooUsers = volcengine.iam.UsersOutput({
    userNames: [fooUser.userName],
});
Copy
import pulumi
import pulumi_volcengine as volcengine

foo_user = volcengine.iam.User("fooUser",
    user_name="acc-test-user",
    description="acc test",
    display_name="name")
foo_users = volcengine.iam.users_output(user_names=[foo_user.user_name])
Copy
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/iam"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		fooUser, err := iam.NewUser(ctx, "fooUser", &iam.UserArgs{
			UserName:    pulumi.String("acc-test-user"),
			Description: pulumi.String("acc test"),
			DisplayName: pulumi.String("name"),
		})
		if err != nil {
			return err
		}
		_ = iam.UsersOutput(ctx, iam.UsersOutputArgs{
			UserNames: pulumi.StringArray{
				fooUser.UserName,
			},
		}, nil)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcengine = Pulumi.Volcengine;

return await Deployment.RunAsync(() => 
{
    var fooUser = new Volcengine.Iam.User("fooUser", new()
    {
        UserName = "acc-test-user",
        Description = "acc test",
        DisplayName = "name",
    });

    var fooUsers = Volcengine.Iam.Users.Invoke(new()
    {
        UserNames = new[]
        {
            fooUser.UserName,
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.iam.User;
import com.pulumi.volcengine.iam.UserArgs;
import com.pulumi.volcengine.iam.IamFunctions;
import com.pulumi.volcengine.iam.inputs.UsersArgs;
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) {
        var fooUser = new User("fooUser", UserArgs.builder()        
            .userName("acc-test-user")
            .description("acc test")
            .displayName("name")
            .build());

        final var fooUsers = IamFunctions.Users(UsersArgs.builder()
            .userNames(fooUser.userName())
            .build());

    }
}
Copy
resources:
  fooUser:
    type: volcengine:iam:User
    properties:
      userName: acc-test-user
      description: acc test
      displayName: name
variables:
  fooUsers:
    fn::invoke:
      Function: volcengine:iam:Users
      Arguments:
        userNames:
          - ${fooUser.userName}
Copy

Using Users

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 users(args: UsersArgs, opts?: InvokeOptions): Promise<UsersResult>
function usersOutput(args: UsersOutputArgs, opts?: InvokeOptions): Output<UsersResult>
Copy
def users(name_regex: Optional[str] = None,
          output_file: Optional[str] = None,
          user_names: Optional[Sequence[str]] = None,
          opts: Optional[InvokeOptions] = None) -> UsersResult
def users_output(name_regex: Optional[pulumi.Input[str]] = None,
          output_file: Optional[pulumi.Input[str]] = None,
          user_names: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
          opts: Optional[InvokeOptions] = None) -> Output[UsersResult]
Copy
func Users(ctx *Context, args *UsersArgs, opts ...InvokeOption) (*UsersResult, error)
func UsersOutput(ctx *Context, args *UsersOutputArgs, opts ...InvokeOption) UsersResultOutput
Copy
public static class Users 
{
    public static Task<UsersResult> InvokeAsync(UsersArgs args, InvokeOptions? opts = null)
    public static Output<UsersResult> Invoke(UsersInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<UsersResult> users(UsersArgs args, InvokeOptions options)
public static Output<UsersResult> users(UsersArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: volcengine:iam:Users
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

NameRegex string
A Name Regex of IAM.
OutputFile string
File name where to save data source results.
UserNames List<string>
A list of user names.
NameRegex string
A Name Regex of IAM.
OutputFile string
File name where to save data source results.
UserNames []string
A list of user names.
nameRegex String
A Name Regex of IAM.
outputFile String
File name where to save data source results.
userNames List<String>
A list of user names.
nameRegex string
A Name Regex of IAM.
outputFile string
File name where to save data source results.
userNames string[]
A list of user names.
name_regex str
A Name Regex of IAM.
output_file str
File name where to save data source results.
user_names Sequence[str]
A list of user names.
nameRegex String
A Name Regex of IAM.
outputFile String
File name where to save data source results.
userNames List<String>
A list of user names.

Users Result

The following output properties are available:

Id string
The provider-assigned unique ID for this managed resource.
TotalCount int
The total count of user query.
Users List<UsersUser>
The collection of user.
NameRegex string
OutputFile string
UserNames List<string>
Id string
The provider-assigned unique ID for this managed resource.
TotalCount int
The total count of user query.
Users []UsersUser
The collection of user.
NameRegex string
OutputFile string
UserNames []string
id String
The provider-assigned unique ID for this managed resource.
totalCount Integer
The total count of user query.
users List<UsersUser>
The collection of user.
nameRegex String
outputFile String
userNames List<String>
id string
The provider-assigned unique ID for this managed resource.
totalCount number
The total count of user query.
users UsersUser[]
The collection of user.
nameRegex string
outputFile string
userNames string[]
id str
The provider-assigned unique ID for this managed resource.
total_count int
The total count of user query.
users Sequence[UsersUser]
The collection of user.
name_regex str
output_file str
user_names Sequence[str]
id String
The provider-assigned unique ID for this managed resource.
totalCount Number
The total count of user query.
users List<Property Map>
The collection of user.
nameRegex String
outputFile String
userNames List<String>

Supporting Types

UsersUser

AccountId This property is required. string
Main account ID to which the sub-user belongs.
CreateDate This property is required. string
The create date of the user.
Description This property is required. string
The description of the user.
DisplayName This property is required. string
The display name of the user.
Email This property is required. string
The email of the user.
EmailIsVerify This property is required. bool
Whether the email has been verified.
MobilePhone This property is required. string
The mobile phone of the user.
MobilePhoneIsVerify This property is required. bool
Whether the phone number has been verified.
Trn This property is required. string
The trn of the user.
UpdateDate This property is required. string
The update date of the user.
UserId This property is required. string
The id of the user.
UserName This property is required. string
The name of the user.
AccountId This property is required. string
Main account ID to which the sub-user belongs.
CreateDate This property is required. string
The create date of the user.
Description This property is required. string
The description of the user.
DisplayName This property is required. string
The display name of the user.
Email This property is required. string
The email of the user.
EmailIsVerify This property is required. bool
Whether the email has been verified.
MobilePhone This property is required. string
The mobile phone of the user.
MobilePhoneIsVerify This property is required. bool
Whether the phone number has been verified.
Trn This property is required. string
The trn of the user.
UpdateDate This property is required. string
The update date of the user.
UserId This property is required. string
The id of the user.
UserName This property is required. string
The name of the user.
accountId This property is required. String
Main account ID to which the sub-user belongs.
createDate This property is required. String
The create date of the user.
description This property is required. String
The description of the user.
displayName This property is required. String
The display name of the user.
email This property is required. String
The email of the user.
emailIsVerify This property is required. Boolean
Whether the email has been verified.
mobilePhone This property is required. String
The mobile phone of the user.
mobilePhoneIsVerify This property is required. Boolean
Whether the phone number has been verified.
trn This property is required. String
The trn of the user.
updateDate This property is required. String
The update date of the user.
userId This property is required. String
The id of the user.
userName This property is required. String
The name of the user.
accountId This property is required. string
Main account ID to which the sub-user belongs.
createDate This property is required. string
The create date of the user.
description This property is required. string
The description of the user.
displayName This property is required. string
The display name of the user.
email This property is required. string
The email of the user.
emailIsVerify This property is required. boolean
Whether the email has been verified.
mobilePhone This property is required. string
The mobile phone of the user.
mobilePhoneIsVerify This property is required. boolean
Whether the phone number has been verified.
trn This property is required. string
The trn of the user.
updateDate This property is required. string
The update date of the user.
userId This property is required. string
The id of the user.
userName This property is required. string
The name of the user.
account_id This property is required. str
Main account ID to which the sub-user belongs.
create_date This property is required. str
The create date of the user.
description This property is required. str
The description of the user.
display_name This property is required. str
The display name of the user.
email This property is required. str
The email of the user.
email_is_verify This property is required. bool
Whether the email has been verified.
mobile_phone This property is required. str
The mobile phone of the user.
mobile_phone_is_verify This property is required. bool
Whether the phone number has been verified.
trn This property is required. str
The trn of the user.
update_date This property is required. str
The update date of the user.
user_id This property is required. str
The id of the user.
user_name This property is required. str
The name of the user.
accountId This property is required. String
Main account ID to which the sub-user belongs.
createDate This property is required. String
The create date of the user.
description This property is required. String
The description of the user.
displayName This property is required. String
The display name of the user.
email This property is required. String
The email of the user.
emailIsVerify This property is required. Boolean
Whether the email has been verified.
mobilePhone This property is required. String
The mobile phone of the user.
mobilePhoneIsVerify This property is required. Boolean
Whether the phone number has been verified.
trn This property is required. String
The trn of the user.
updateDate This property is required. String
The update date of the user.
userId This property is required. String
The id of the user.
userName This property is required. String
The name of the user.

Package Details

Repository
volcengine volcengine/pulumi-volcengine
License
Apache-2.0
Notes
This Pulumi package is based on the volcengine Terraform Provider.
Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine