Viewing docs for discord 2.5.1
published on Thursday, Mar 19, 2026 by lucky3028
published on Thursday, Mar 19, 2026 by lucky3028
Viewing docs for discord 2.5.1
published on Thursday, Mar 19, 2026 by lucky3028
published on Thursday, Mar 19, 2026 by lucky3028
Fetches a member’s information from a server.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as discord from "@pulumi/discord";
const jake = discord.getMember({
serverId: "81384788765712384",
userId: "103559217914318848",
});
export const jakesUsernameAndDiscrim = Promise.all([jake, jake]).then(([jake, jake1]) => `${jake.username}#${jake1.discriminator}`);
import pulumi
import pulumi_discord as discord
jake = discord.get_member(server_id="81384788765712384",
user_id="103559217914318848")
pulumi.export("jakesUsernameAndDiscrim", f"{jake.username}#{jake.discriminator}")
package main
import (
"fmt"
"github.com/pulumi/pulumi-terraform-provider/sdks/go/discord/v2/discord"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
jake, err := discord.GetMember(ctx, &discord.GetMemberArgs{
ServerId: "81384788765712384",
UserId: pulumi.StringRef("103559217914318848"),
}, nil)
if err != nil {
return err
}
ctx.Export("jakesUsernameAndDiscrim", pulumi.Sprintf("%v#%v", jake.Username, jake.Discriminator))
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Discord = Pulumi.Discord;
return await Deployment.RunAsync(() =>
{
var jake = Discord.GetMember.Invoke(new()
{
ServerId = "81384788765712384",
UserId = "103559217914318848",
});
return new Dictionary<string, object?>
{
["jakesUsernameAndDiscrim"] = Output.Tuple(jake, jake).Apply(values =>
{
var jake = values.Item1;
var jake1 = values.Item2;
return $"{jake.Apply(getMemberResult => getMemberResult.Username)}#{jake1.Discriminator}";
}),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.discord.DiscordFunctions;
import com.pulumi.discord.inputs.GetMemberArgs;
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 jake = DiscordFunctions.getMember(GetMemberArgs.builder()
.serverId("81384788765712384")
.userId("103559217914318848")
.build());
ctx.export("jakesUsernameAndDiscrim", String.format("%s#%s", jake.username(),jake.discriminator()));
}
}
variables:
jake:
fn::invoke:
function: discord:getMember
arguments:
serverId: '81384788765712384'
userId: '103559217914318848'
outputs:
jakesUsernameAndDiscrim: ${jake.username}#${jake.discriminator}
Using getMember
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 getMember(args: GetMemberArgs, opts?: InvokeOptions): Promise<GetMemberResult>
function getMemberOutput(args: GetMemberOutputArgs, opts?: InvokeOptions): Output<GetMemberResult>def get_member(discriminator: Optional[str] = None,
server_id: Optional[str] = None,
user_id: Optional[str] = None,
username: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetMemberResult
def get_member_output(discriminator: Optional[pulumi.Input[str]] = None,
server_id: Optional[pulumi.Input[str]] = None,
user_id: Optional[pulumi.Input[str]] = None,
username: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetMemberResult]func GetMember(ctx *Context, args *GetMemberArgs, opts ...InvokeOption) (*GetMemberResult, error)
func GetMemberOutput(ctx *Context, args *GetMemberOutputArgs, opts ...InvokeOption) GetMemberResultOutput> Note: This function is named GetMember in the Go SDK.
public static class GetMember
{
public static Task<GetMemberResult> InvokeAsync(GetMemberArgs args, InvokeOptions? opts = null)
public static Output<GetMemberResult> Invoke(GetMemberInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetMemberResult> getMember(GetMemberArgs args, InvokeOptions options)
public static Output<GetMemberResult> getMember(GetMemberArgs args, InvokeOptions options)
fn::invoke:
function: discord:index/getMember:getMember
arguments:
# arguments dictionaryThe following arguments are supported:
- Server
Id string - The server ID to search for the user in.
- Discriminator string
- The discriminator to search for.
usernameis required when using this. - User
Id string - The user ID to search for. Required if not searching by
username/discriminator. - Username string
- The username to search for.
- Server
Id string - The server ID to search for the user in.
- Discriminator string
- The discriminator to search for.
usernameis required when using this. - User
Id string - The user ID to search for. Required if not searching by
username/discriminator. - Username string
- The username to search for.
- server
Id String - The server ID to search for the user in.
- discriminator String
- The discriminator to search for.
usernameis required when using this. - user
Id String - The user ID to search for. Required if not searching by
username/discriminator. - username String
- The username to search for.
- server
Id string - The server ID to search for the user in.
- discriminator string
- The discriminator to search for.
usernameis required when using this. - user
Id string - The user ID to search for. Required if not searching by
username/discriminator. - username string
- The username to search for.
- server_
id str - The server ID to search for the user in.
- discriminator str
- The discriminator to search for.
usernameis required when using this. - user_
id str - The user ID to search for. Required if not searching by
username/discriminator. - username str
- The username to search for.
- server
Id String - The server ID to search for the user in.
- discriminator String
- The discriminator to search for.
usernameis required when using this. - user
Id String - The user ID to search for. Required if not searching by
username/discriminator. - username String
- The username to search for.
getMember Result
The following output properties are available:
- Avatar string
- The avatar hash of the user.
- Id string
- The user's ID.
- In
Server bool - Whether the user is in the server.
- Joined
At string - The time at which the user joined.
- Nick string
- The current nickname of the user.
- string
- The time at which the user became premium.
- Roles List<string>
- IDs of the roles that the user has.
- Server
Id string - The server ID to search for the user in.
- Discriminator string
- The discriminator to search for.
usernameis required when using this. - User
Id string - The user ID to search for. Required if not searching by
username/discriminator. - Username string
- The username to search for.
- Avatar string
- The avatar hash of the user.
- Id string
- The user's ID.
- In
Server bool - Whether the user is in the server.
- Joined
At string - The time at which the user joined.
- Nick string
- The current nickname of the user.
- string
- The time at which the user became premium.
- Roles []string
- IDs of the roles that the user has.
- Server
Id string - The server ID to search for the user in.
- Discriminator string
- The discriminator to search for.
usernameis required when using this. - User
Id string - The user ID to search for. Required if not searching by
username/discriminator. - Username string
- The username to search for.
- avatar String
- The avatar hash of the user.
- id String
- The user's ID.
- in
Server Boolean - Whether the user is in the server.
- joined
At String - The time at which the user joined.
- nick String
- The current nickname of the user.
- String
- The time at which the user became premium.
- roles List<String>
- IDs of the roles that the user has.
- server
Id String - The server ID to search for the user in.
- discriminator String
- The discriminator to search for.
usernameis required when using this. - user
Id String - The user ID to search for. Required if not searching by
username/discriminator. - username String
- The username to search for.
- avatar string
- The avatar hash of the user.
- id string
- The user's ID.
- in
Server boolean - Whether the user is in the server.
- joined
At string - The time at which the user joined.
- nick string
- The current nickname of the user.
- string
- The time at which the user became premium.
- roles string[]
- IDs of the roles that the user has.
- server
Id string - The server ID to search for the user in.
- discriminator string
- The discriminator to search for.
usernameis required when using this. - user
Id string - The user ID to search for. Required if not searching by
username/discriminator. - username string
- The username to search for.
- avatar str
- The avatar hash of the user.
- id str
- The user's ID.
- in_
server bool - Whether the user is in the server.
- joined_
at str - The time at which the user joined.
- nick str
- The current nickname of the user.
- str
- The time at which the user became premium.
- roles Sequence[str]
- IDs of the roles that the user has.
- server_
id str - The server ID to search for the user in.
- discriminator str
- The discriminator to search for.
usernameis required when using this. - user_
id str - The user ID to search for. Required if not searching by
username/discriminator. - username str
- The username to search for.
- avatar String
- The avatar hash of the user.
- id String
- The user's ID.
- in
Server Boolean - Whether the user is in the server.
- joined
At String - The time at which the user joined.
- nick String
- The current nickname of the user.
- String
- The time at which the user became premium.
- roles List<String>
- IDs of the roles that the user has.
- server
Id String - The server ID to search for the user in.
- discriminator String
- The discriminator to search for.
usernameis required when using this. - user
Id String - The user ID to search for. Required if not searching by
username/discriminator. - username String
- The username to search for.
Package Details
- Repository
- discord lucky3028/terraform-provider-discord
- License
- Notes
- This Pulumi package is based on the
discordTerraform Provider.
Viewing docs for discord 2.5.1
published on Thursday, Mar 19, 2026 by lucky3028
published on Thursday, Mar 19, 2026 by lucky3028
