Rotate database credentials
Rotate a managed database’s password (generated for you unless you supply one) and invalidate the previous credential.
Request & response examples
curl --fail-with-body --request POST \ 'https://app.helicarrier.xyz/api/services/YOUR_ID/db/password' \ -H "Authorization: Bearer $HELI_API_KEY"const response = await fetch( "https://app.helicarrier.xyz/api/services/YOUR_ID/db/password", { method: "POST", headers: { Authorization: `Bearer ${process.env.HELI_API_KEY}` } });const data = await response.json();if (!response.ok) { throw new Error(`HTTP ${response.status}: ${data.error}`);}// Inspect data; avoid logging secret responses.import osimport requests
response = requests.request( "POST", "https://app.helicarrier.xyz/api/services/YOUR_ID/db/password", headers={ "Authorization": f"Bearer {os.environ['HELI_API_KEY']}" }, timeout=30,)response.raise_for_status()data = response.json()# Inspect data; avoid logging secret responses.{ "status": "password changed", "generated": true, "reveal": "The password is not included. Call GET /api/services/{id}/connection?reveal=true (MCP: get_db_connection with reveal=true) to read it; each reveal is recorded in the audit trail and needs a key that can write.", "dependents": [ "my-app", "my-worker" ], "reconnected": true, "warning": "these 2 service(s) briefly lose access while they redeploy with the new credential"}Illustrative values · selected fields
Path parameters
idstringrequiredDatabase or bucket service id.
Request body
passwordstringoptionalOptional. Omit to have the platform generate the new password (databases) or secret key (buckets); recommended, so no secret passes through your transcript. If given: at least 6 characters (buckets: 8), no control characters.
accessKeystringoptionalBuckets only: a new S3 access key. Omit to keep the current one.
reconnectDependentsstringoptionalDefault true: the services that connect to this one are redeployed so they pick the new credential up, and they briefly lose access while they do. Set false to skip that and deploy them yourself — until you do, they keep using the old credential and will fail. Not available for Redis, which has to be redeployed for a rotation to take effect, and that reconnects its dependents either way.
Response 200
Omit password and the platform generates a strong one (recommended), so no secret passes through your client, transcript or shell history. A supplied password is still accepted. The new value is never returned: generated says who chose it, and get_db_connection with reveal=true reads it. Returns confirmation, the services that connect to this one, and whether they were redeployed to pick the new credential up. They briefly lose access while they redeploy — set reconnectDependents to false to skip that and deploy them yourself, in which case they keep using the old credential and will fail until you do.
Examples show selected response fields with illustrative values. Your response can contain additional fields.
statusstringCurrent state of the resource or operation.
generatedbooleanrevealstringdependentsarrayreconnectedbooleanwarningstringErrors
400Invalid parameters. Check the required fields, types, and resource configuration.
401The API key is missing, invalid, or revoked.
403The caller or key scope does not permit this operation.
409The current resource state prevents the operation. Inspect it before retrying.
500The operation could not be completed. Check resource state before retrying a write.
503The request could not be completed.
rotate_db_credentials
Required MCP arguments: id. Send path, query, and body fields together as tool arguments.