DescribeBranch

更新时间:
复制 MD 格式

Queries the details of a Supabase branch.

Operation description

Queries the detailed information of a specified Supabase branch, including basic branch attributes, parent branch information, protection status, and connection information.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

No

The region ID. This parameter is required when you create a primary branch. When you create a child branch, the region of the primary branch is inherited by default.

cn-beijing

BranchId

string

Yes

The branch ID, which uniquely identifies a Supabase branch.

br-xxxx

Response elements

Element

Type

Description

Example

object

The response object.

RequestId

string

The request ID.

ABB39CC3-4488-4857-905D-2E4A051D****

Branch

object

The branch list. Each element represents a Supabase branch.

BranchId

string

The branch ID, which uniquely identifies a Supabase branch.

br-xxxx

BranchName

string

The branch name.

dev

IsDefault

boolean

Indicates whether this is the default branch.

true

Description

string

The branch description.

test branch

ParentBranchName

string

The parent branch name. This value is empty or displayed as - for the primary branch.

main

ParentBranchId

string

The parent branch ID, which specifies the parent branch of a new branch or a query condition.

br-main

ServiceType

string

The service type.

Valid values:

  • Supabase: Supabase service.

  • Memory: Memory service.

Supabase

ProjectId

string

The Supabase project ID that corresponds to the primary branch.

spb-xxxx

CreateTime

string

The time when the branch was created, in ISO 8601 UTC format.

2026-04-08T09:11:12Z

Status

string

The branch status.

Running

Tags

array<object>

The list of branch tags.

object

The response object.

Key

string

env

Value

string

dev

ExpiresAt

string

The time when the branch expires and is automatically deleted, in ISO 8601 UTC format.

2026-10-08T09:11:12Z

InitSource

string

The initialization source of the branch.

Valid values:

  • ParentData: Copies the schema and data from the parent branch. This is the default value.

  • SchemaOnly: Copies only the schema structure.

ParentData

Protected

boolean

Indicates whether branch protection is enabled. A value of true indicates that branch protection is enabled. A value of false indicates that branch protection is disabled.

false

ParentTimestamp

string

The data synchronization point in time selected from the parent branch when this branch was created, in ISO 8601 UTC format.

Note:

  • For child branches, this value indicates the point in time of the parent branch selected during creation.

  • If no parent branch exists, the value 1970-01-01T00:00:00.000Z is returned.

2026-04-08T09:11:12Z

ParentLSN

string

The Log Sequence Number (LSN) of the parent branch at the time this branch was created.

0/3522648

ComputeEndpoint

string

The connection information of the compute node associated with the branch.

postgresql://user:password@host:5432/db

Examples

Success response

JSON format

{
  "RequestId": "ABB39CC3-4488-4857-905D-2E4A051D****",
  "Branch": {
    "BranchId": "br-xxxx",
    "BranchName": "dev",
    "IsDefault": true,
    "Description": "test branch",
    "ParentBranchName": "main",
    "ParentBranchId": "br-main",
    "ServiceType": "Supabase",
    "ProjectId": "spb-xxxx",
    "CreateTime": "2026-04-08T09:11:12Z",
    "Status": "Running",
    "Tags": [
      {
        "Key": "env",
        "Value": "dev"
      }
    ],
    "ExpiresAt": "2026-10-08T09:11:12Z",
    "InitSource": "ParentData",
    "Protected": false,
    "ParentTimestamp": "2026-04-08T09:11:12Z",
    "ParentLSN": "0/3522648",
    "ComputeEndpoint": "postgresql://user:password@host:5432/db"
  }
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.