planetscale 1.0.0-rc1 published on Friday, Jan 30, 2026 by planetscale
planetscale 1.0.0-rc1 published on Friday, Jan 30, 2026 by planetscale
PostgresBranchRole DataSource
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as planetscale from "@pulumi/planetscale";
const myPostgresbranchrole = planetscale.getPostgresBranchRole({
branch: "...my_branch...",
database: "...my_database...",
id: "...my_id...",
organization: "...my_organization...",
});
import pulumi
import pulumi_planetscale as planetscale
my_postgresbranchrole = planetscale.get_postgres_branch_role(branch="...my_branch...",
database="...my_database...",
id="...my_id...",
organization="...my_organization...")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/planetscale/planetscale"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := planetscale.LookupPostgresBranchRole(ctx, &planetscale.LookupPostgresBranchRoleArgs{
Branch: "...my_branch...",
Database: "...my_database...",
Id: "...my_id...",
Organization: "...my_organization...",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Planetscale = Pulumi.Planetscale;
return await Deployment.RunAsync(() =>
{
var myPostgresbranchrole = Planetscale.GetPostgresBranchRole.Invoke(new()
{
Branch = "...my_branch...",
Database = "...my_database...",
Id = "...my_id...",
Organization = "...my_organization...",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.planetscale.PlanetscaleFunctions;
import com.pulumi.planetscale.inputs.GetPostgresBranchRoleArgs;
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 myPostgresbranchrole = PlanetscaleFunctions.getPostgresBranchRole(GetPostgresBranchRoleArgs.builder()
.branch("...my_branch...")
.database("...my_database...")
.id("...my_id...")
.organization("...my_organization...")
.build());
}
}
variables:
myPostgresbranchrole:
fn::invoke:
function: planetscale:getPostgresBranchRole
arguments:
branch: '...my_branch...'
database: '...my_database...'
id: '...my_id...'
organization: '...my_organization...'
Using getPostgresBranchRole
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 getPostgresBranchRole(args: GetPostgresBranchRoleArgs, opts?: InvokeOptions): Promise<GetPostgresBranchRoleResult>
function getPostgresBranchRoleOutput(args: GetPostgresBranchRoleOutputArgs, opts?: InvokeOptions): Output<GetPostgresBranchRoleResult>def get_postgres_branch_role(branch: Optional[str] = None,
database: Optional[str] = None,
id: Optional[str] = None,
organization: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetPostgresBranchRoleResult
def get_postgres_branch_role_output(branch: Optional[pulumi.Input[str]] = None,
database: Optional[pulumi.Input[str]] = None,
id: Optional[pulumi.Input[str]] = None,
organization: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPostgresBranchRoleResult]func LookupPostgresBranchRole(ctx *Context, args *LookupPostgresBranchRoleArgs, opts ...InvokeOption) (*LookupPostgresBranchRoleResult, error)
func LookupPostgresBranchRoleOutput(ctx *Context, args *LookupPostgresBranchRoleOutputArgs, opts ...InvokeOption) LookupPostgresBranchRoleResultOutput> Note: This function is named LookupPostgresBranchRole in the Go SDK.
public static class GetPostgresBranchRole
{
public static Task<GetPostgresBranchRoleResult> InvokeAsync(GetPostgresBranchRoleArgs args, InvokeOptions? opts = null)
public static Output<GetPostgresBranchRoleResult> Invoke(GetPostgresBranchRoleInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetPostgresBranchRoleResult> getPostgresBranchRole(GetPostgresBranchRoleArgs args, InvokeOptions options)
public static Output<GetPostgresBranchRoleResult> getPostgresBranchRole(GetPostgresBranchRoleArgs args, InvokeOptions options)
fn::invoke:
function: planetscale:index/getPostgresBranchRole:getPostgresBranchRole
arguments:
# arguments dictionaryThe following arguments are supported:
- Branch string
- The name of the branch that owns this resource
- Database string
- The name of the database that owns this resource
- Id string
- The ID of the role
- Organization string
- The name of the organization that owns this resource
- Branch string
- The name of the branch that owns this resource
- Database string
- The name of the database that owns this resource
- Id string
- The ID of the role
- Organization string
- The name of the organization that owns this resource
- branch String
- The name of the branch that owns this resource
- database String
- The name of the database that owns this resource
- id String
- The ID of the role
- organization String
- The name of the organization that owns this resource
- branch string
- The name of the branch that owns this resource
- database string
- The name of the database that owns this resource
- id string
- The ID of the role
- organization string
- The name of the organization that owns this resource
- branch str
- The name of the branch that owns this resource
- database str
- The name of the database that owns this resource
- id str
- The ID of the role
- organization str
- The name of the organization that owns this resource
- branch String
- The name of the branch that owns this resource
- database String
- The name of the database that owns this resource
- id String
- The ID of the role
- organization String
- The name of the organization that owns this resource
getPostgresBranchRole Result
The following output properties are available:
- Access
Host stringUrl - The database connection string
- Actor
Data GetPostgres Branch Role Actor Data - Branch string
- The name of the branch that owns this resource
- Branch
Data GetPostgres Branch Role Branch Data - Created
At string - When the role was created
- Database string
- The name of the database that owns this resource
- Database
Name string - The database name
- Default bool
- Whether the role is the default postgres user
- Deleted
At string - When the role was deleted
- Disabled
At string - When the role was disabled
- Drop
Failed string - Error message available when dropping the role fails
- Dropped
At string - When the role was dropped
- Expired bool
- True if the credentials are expired
- Expires
At string - When the role expires
- Id string
- The ID of the role
- Inherited
Roles List<string> - Database roles these credentials inherit
- Name string
- The name of the role
- Organization string
- The name of the organization that owns this resource
- Private
Access stringHost Url - The database connection string for private connections
- Private
Connection stringService Name - The service name to set up private connectivity
- Ttl double
- Number of seconds before the credentials expire
- Updated
At string - When the role was updated
- Username string
- The database user name
- Access
Host stringUrl - The database connection string
- Actor
Data GetPostgres Branch Role Actor Data - Branch string
- The name of the branch that owns this resource
- Branch
Data GetPostgres Branch Role Branch Data - Created
At string - When the role was created
- Database string
- The name of the database that owns this resource
- Database
Name string - The database name
- Default bool
- Whether the role is the default postgres user
- Deleted
At string - When the role was deleted
- Disabled
At string - When the role was disabled
- Drop
Failed string - Error message available when dropping the role fails
- Dropped
At string - When the role was dropped
- Expired bool
- True if the credentials are expired
- Expires
At string - When the role expires
- Id string
- The ID of the role
- Inherited
Roles []string - Database roles these credentials inherit
- Name string
- The name of the role
- Organization string
- The name of the organization that owns this resource
- Private
Access stringHost Url - The database connection string for private connections
- Private
Connection stringService Name - The service name to set up private connectivity
- Ttl float64
- Number of seconds before the credentials expire
- Updated
At string - When the role was updated
- Username string
- The database user name
- access
Host StringUrl - The database connection string
- actor
Data GetPostgres Branch Role Actor Data - branch String
- The name of the branch that owns this resource
- branch
Data GetPostgres Branch Role Branch Data - created
At String - When the role was created
- database String
- The name of the database that owns this resource
- database
Name String - The database name
- default_ Boolean
- Whether the role is the default postgres user
- deleted
At String - When the role was deleted
- disabled
At String - When the role was disabled
- drop
Failed String - Error message available when dropping the role fails
- dropped
At String - When the role was dropped
- expired Boolean
- True if the credentials are expired
- expires
At String - When the role expires
- id String
- The ID of the role
- inherited
Roles List<String> - Database roles these credentials inherit
- name String
- The name of the role
- organization String
- The name of the organization that owns this resource
- private
Access StringHost Url - The database connection string for private connections
- private
Connection StringService Name - The service name to set up private connectivity
- ttl Double
- Number of seconds before the credentials expire
- updated
At String - When the role was updated
- username String
- The database user name
- access
Host stringUrl - The database connection string
- actor
Data GetPostgres Branch Role Actor Data - branch string
- The name of the branch that owns this resource
- branch
Data GetPostgres Branch Role Branch Data - created
At string - When the role was created
- database string
- The name of the database that owns this resource
- database
Name string - The database name
- default boolean
- Whether the role is the default postgres user
- deleted
At string - When the role was deleted
- disabled
At string - When the role was disabled
- drop
Failed string - Error message available when dropping the role fails
- dropped
At string - When the role was dropped
- expired boolean
- True if the credentials are expired
- expires
At string - When the role expires
- id string
- The ID of the role
- inherited
Roles string[] - Database roles these credentials inherit
- name string
- The name of the role
- organization string
- The name of the organization that owns this resource
- private
Access stringHost Url - The database connection string for private connections
- private
Connection stringService Name - The service name to set up private connectivity
- ttl number
- Number of seconds before the credentials expire
- updated
At string - When the role was updated
- username string
- The database user name
- access_
host_ strurl - The database connection string
- actor_
data GetPostgres Branch Role Actor Data - branch str
- The name of the branch that owns this resource
- branch_
data GetPostgres Branch Role Branch Data - created_
at str - When the role was created
- database str
- The name of the database that owns this resource
- database_
name str - The database name
- default bool
- Whether the role is the default postgres user
- deleted_
at str - When the role was deleted
- disabled_
at str - When the role was disabled
- drop_
failed str - Error message available when dropping the role fails
- dropped_
at str - When the role was dropped
- expired bool
- True if the credentials are expired
- expires_
at str - When the role expires
- id str
- The ID of the role
- inherited_
roles Sequence[str] - Database roles these credentials inherit
- name str
- The name of the role
- organization str
- The name of the organization that owns this resource
- private_
access_ strhost_ url - The database connection string for private connections
- private_
connection_ strservice_ name - The service name to set up private connectivity
- ttl float
- Number of seconds before the credentials expire
- updated_
at str - When the role was updated
- username str
- The database user name
- access
Host StringUrl - The database connection string
- actor
Data Property Map - branch String
- The name of the branch that owns this resource
- branch
Data Property Map - created
At String - When the role was created
- database String
- The name of the database that owns this resource
- database
Name String - The database name
- default Boolean
- Whether the role is the default postgres user
- deleted
At String - When the role was deleted
- disabled
At String - When the role was disabled
- drop
Failed String - Error message available when dropping the role fails
- dropped
At String - When the role was dropped
- expired Boolean
- True if the credentials are expired
- expires
At String - When the role expires
- id String
- The ID of the role
- inherited
Roles List<String> - Database roles these credentials inherit
- name String
- The name of the role
- organization String
- The name of the organization that owns this resource
- private
Access StringHost Url - The database connection string for private connections
- private
Connection StringService Name - The service name to set up private connectivity
- ttl Number
- Number of seconds before the credentials expire
- updated
At String - When the role was updated
- username String
- The database user name
Supporting Types
GetPostgresBranchRoleActorData
- Avatar
Url string - The URL of the actor's avatar
- Display
Name string - The name of the actor
- Id string
- The ID of the actor
- Avatar
Url string - The URL of the actor's avatar
- Display
Name string - The name of the actor
- Id string
- The ID of the actor
- avatar
Url String - The URL of the actor's avatar
- display
Name String - The name of the actor
- id String
- The ID of the actor
- avatar
Url string - The URL of the actor's avatar
- display
Name string - The name of the actor
- id string
- The ID of the actor
- avatar_
url str - The URL of the actor's avatar
- display_
name str - The name of the actor
- id str
- The ID of the actor
- avatar
Url String - The URL of the actor's avatar
- display
Name String - The name of the actor
- id String
- The ID of the actor
GetPostgresBranchRoleBranchData
- deleted_
at str - When the resource was deleted, if deleted
- id str
- The ID for the resource
- name str
- The name for the resource
Package Details
- Repository
- planetscale planetscale/terraform-provider-planetscale
- License
- Notes
- This Pulumi package is based on the
planetscaleTerraform Provider.
planetscale 1.0.0-rc1 published on Friday, Jan 30, 2026 by planetscale
