Assign database privileges

Grant a MySQL user privileges to a database.

Path Parameters

accountId integer · min: 1 required

accountId parameter

Headers

Accept Example
Content-Type Example

Body

required
application/json
username string required
database string required
privileges array required

e.g., ['ALL', 'SELECT', 'INSERT']

Responses

200 Successful response

No response body

POST https://cloud.hostup.se/api/hosting/{accountId}/database-users/privileges
For AI assistants
cURL
curl -X POST "https://cloud.hostup.se/api/hosting/0/database-users/privileges" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "username": "string",
    "database": "string",
    "privileges": []
  }'
Response
{}
Request Body
{
  "username": "string",
  "database": "string",
  "privileges": []
}