Skip to main content
POST
/
cloud
/
v1
/
dbaas
/
postgres
/
clusters
/
{project_id}
/
{region_id}
/
{cluster_name}
/
users
/
{username}
/
credentials
Python
from gcore import Gcore

client = Gcore(
    api_key="My API Key",
)
postgres_user_credentials = client.cloud.databases.postgres.clusters.user_credentials.regenerate(
    username="username",
    project_id=0,
    region_id=0,
    cluster_name="cluster_name",
)
print(postgres_user_credentials.password)
{
  "password": "<PASSWORD>",
  "username": "myuser"
}

Authorizations

Authorization
string
header
required

API key for authentication. Make sure to include the word apikey, followed by a single space and then your token. Example: apikey 1234$abcdef

Path Parameters

project_id
integer
required

Project ID

region_id
integer
required

Region ID

cluster_name
string
required

Cluster name

username
string
required

Username

Response

New user credentials

password
string
required

Password

Examples:

"<PASSWORD>"

username
string
required

Username

Examples:

"myuser"