Viewing docs for discord 2.7.0
published on Monday, May 18, 2026 by lucky3028
published on Monday, May 18, 2026 by lucky3028
Discord Provider
I want to use the Pulumi discord package (discord) in my project.
## Provider details
- Package: discord
- Version: 2.7.0
- Publisher: lucky3028
- Source: opentofu
- Repository: https://github.com/lucky3028/terraform-provider-discord
## Documentation
The Pulumi Cloud Registry API serves canonical, up-to-date docs for this package — including private packages and every published version. Send the "Accept: text/markdown" header for clean readable content, or "application/json" for structured data.
Start at the navigation tree, which cross-links to the readme, installation guide, and per-resource docs URL template:
- https://api.pulumi.com/api/registry/packages/opentofu/lucky3028/discord/versions/latest/nav
Returns a summary by default. The full tree can be hundreds of kB for large providers, so prefer targeted search: append "?q=<query>&depth=full" to filter by resource/function title or token (for example "?q=bucket&depth=full"). Only request the full nav without a query if you actually need to enumerate every resource.
Other endpoints:
- Overview and getting started: https://api.pulumi.com/api/registry/packages/opentofu/lucky3028/discord/versions/latest/readme
- Installation and configuration: https://api.pulumi.com/api/registry/packages/opentofu/lucky3028/discord/versions/latest/installation
- Per-resource/function docs: https://api.pulumi.com/api/registry/packages/opentofu/lucky3028/discord/versions/latest/docs/{token}?lang={lang}
Replace {token} with the percent-encoded token from the nav response (for example aws:s3/bucket:Bucket).
Replace {lang} with typescript, python, go, csharp, java, or yaml.
Fetch the installation endpoint above for the correct setup steps — install instructions vary between native providers, bridged Terraform providers, and component packages.
Help me get started using this provider. Show me a complete Pulumi program that provisions a common resource, including all necessary configuration and imports.
Viewing docs for discord 2.7.0
published on Monday, May 18, 2026 by lucky3028
published on Monday, May 18, 2026 by lucky3028
Generate Provider
The Discord provider must be installed as a Local Package by following the instructions for Any Terraform Provider:
pulumi package add terraform-provider lucky3028/discord
Overview
This is a fork of Chaotic-Logic/pulumi-provider-discord.
The Discord provider is used to interact with the Discord API. It requires proper credentials before it can be used.
Use the navigation on the left to read more about the resources and functions.
Example Usage
# Pulumi.yaml provider configuration file
name: configuration-example
runtime: nodejs
config:
discord:token:
value: 'TODO: var.discord_token'
import * as pulumi from "@pulumi/pulumi";
import * as discord from "@pulumi/discord";
const logo = discord.getLocalImage({
file: "logo.png",
});
const myServer = new discord.Server("my_server", {
name: "My Awesome Server",
region: "us-west",
defaultMessageNotifications: 0,
iconDataUri: logo.then(logo => logo.dataUri),
});
# Pulumi.yaml provider configuration file
name: configuration-example
runtime: python
config:
discord:token:
value: 'TODO: var.discord_token'
import pulumi
import pulumi_discord as discord
logo = discord.get_local_image(file="logo.png")
my_server = discord.Server("my_server",
name="My Awesome Server",
region="us-west",
default_message_notifications=0,
icon_data_uri=logo.data_uri)
# Pulumi.yaml provider configuration file
name: configuration-example
runtime: dotnet
config:
discord:token:
value: 'TODO: var.discord_token'
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Discord = Pulumi.Discord;
return await Deployment.RunAsync(() =>
{
var logo = Discord.GetLocalImage.Invoke(new()
{
File = "logo.png",
});
var myServer = new Discord.Server("my_server", new()
{
Name = "My Awesome Server",
Region = "us-west",
DefaultMessageNotifications = 0,
IconDataUri = logo.Apply(getLocalImageResult => getLocalImageResult.DataUri),
});
});
# Pulumi.yaml provider configuration file
name: configuration-example
runtime: go
config:
discord:token:
value: 'TODO: var.discord_token'
package main
import (
"github.com/pulumi/pulumi-pulumi-provider/sdks/go/discord/v2/discord"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
logo, err := discord.GetLocalImage(ctx, &discord.GetLocalImageArgs{
File: "logo.png",
}, nil)
if err != nil {
return err
}
_, err = discord.NewServer(ctx, "my_server", &discord.ServerArgs{
Name: pulumi.String("My Awesome Server"),
Region: pulumi.String("us-west"),
DefaultMessageNotifications: pulumi.Float64(0),
IconDataUri: pulumi.String(logo.DataUri),
})
if err != nil {
return err
}
return nil
})
}
# Pulumi.yaml provider configuration file
name: configuration-example
runtime: yaml
config:
discord:token:
value: 'TODO: var.discord_token'
resources:
myServer:
type: discord:Server
name: my_server
properties:
name: My Awesome Server
region: us-west
defaultMessageNotifications: 0
iconDataUri: ${logo.dataUri}
variables:
logo:
fn::invoke:
function: discord:getLocalImage
arguments:
file: logo.png
# Pulumi.yaml provider configuration file
name: configuration-example
runtime: java
config:
discord:token:
value: 'TODO: var.discord_token'
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.GetLocalImageArgs;
import com.pulumi.discord.Server;
import com.pulumi.discord.ServerArgs;
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 logo = DiscordFunctions.getLocalImage(GetLocalImageArgs.builder()
.file("logo.png")
.build());
var myServer = new Server("myServer", ServerArgs.builder()
.name("My Awesome Server")
.region("us-west")
.defaultMessageNotifications(0.0)
.iconDataUri(logo.dataUri())
.build());
}
}
Configuration Reference
clientId(String) OAuth app client ID. Currently unused.secret(String) OAuth app secret. Currently unused.token(String) Discord API token, without theBotprefix. This can be found in the Discord Developer Portal. This can also be set via theDISCORD_TOKENenvironment variable.
Viewing docs for discord 2.7.0
published on Monday, May 18, 2026 by lucky3028
published on Monday, May 18, 2026 by lucky3028