Create a database
Create a new database
You will need to base64 encode the string containing your credentials. Separate your username and password with a colon, i.e., username:password and send it as 'Authorization' request header. More details: https://en.wikipedia.org/wiki/Basic_access_authentication.
The unique ID of the cluster.
498ae72f-411f-11eb-9d07-046c59cc737eSuccessful operation.
The type of the resource.
The unique ID of the resource.
498ae72f-411f-11eb-9d07-046c59cc737eAbsolute URL of the resource.
Any erroneous status code: 400 (parse error), 401 (auth error), 402 (trial access), 403 (insufficient permissions), 404 (not found), 405 (unsupported HTTP method), 415 (unsupported content type, 422 (validation error), 429 (request rate limit exceeded), 500 (server error), 503 (maintenance)
POST /databases/postgresql/clusters/{clusterId}/databases HTTP/1.1
Host: api.ionos.com
Authorization: Basic username:password
Content-Type: application/json
Accept: */*
Content-Length: 55
{
"properties": {
"name": "benjamindb",
"owner": "benjamin"
}
}{
"type": "collection",
"id": "498ae72f-411f-11eb-9d07-046c59cc737e",
"href": "text",
"metadata": {
"createdBy": "ionos:iam:cloud::users/f719718d-e0aa-4870-a36c-cc0bdb8c6d90",
"createdByUserId": "f719718d-e0aa-4870-a36c-cc0bdb8c6d90",
"createdDate": "2023-05-11T13:37:50Z",
"lastModifiedBy": "ionos:iam:cloud::users/f719718d-e0aa-4870-a36c-cc0bdb8c6d90",
"lastModifiedByUserId": "f719718d-e0aa-4870-a36c-cc0bdb8c6d90",
"lastModifiedDate": "2023-05-11T13:37:50Z",
"resourceURN": "ionos:postgresql:de-fra:11274857:clusters/c668480f-8627-4b6c-b422-2599d4b568a6/users/benjamin"
},
"properties": {
"name": "benjamindb",
"owner": "benjamin"
}
}Last updated
Was this helpful?