Description
Create accounts for database.。
Request URL
Database API v1.0 POST /v1/users
Request Paramters
Parameter | Value | Style | Type | Description |
---|---|---|---|---|
X-Auth-Token | - | header | string | User Token |
service_id | - | plain | UUID | Service ID |
user_name | - | plain | string | User Name The type of characters allowed:[a-z0-9_] The length of characters : 1-14 |
password | - | plain | string | Password The type of characters allowed:Refer to below. The length of characters : 9~70 |
hostname | - | plain | string | Hostname The type of characters allowed:[a-zA-Z0-9./%_:-](Capital letters are automatically replaced by small letters.) The length of characters : 60 |
memo(Optional) | - | plain | string | Memo The type of characters allowed:All ASCII characters that can be printed. The length of characters : 255 |
※About Password
・A combination of capital letters, small letters and numbers are required
・The special letters allowed:!#$%&?“'=+-_{}[]^~:;().,/|\*@
Response Paramters
Parameter | Value | Style | Type | Description |
---|---|---|---|---|
service_id | - | plain | UUID | Service ID |
user_id | - | plain | UUID | User ID |
user_name | - | plain | string | User Name Prefix+“_”+ the name of the database name you specified when you requested |
hostname | - | plain | string | Hostname |
memo | - | plain | string | Memo |
status | creating | plain | string | Status |
Request Json
{ "service_id": "9d6441f6-c5a0-4dcf-a1a9-1a4d724e51fd", "user_name": "dbuser001", "password": "wa6g76w08#", "hostname": "cl1.example.com", "memo": "memo" }
Normal response codes
200 - Success
Error response codes
409 - Conflict
400 - Bad Request
401 - Access Denied
Repeatable
No
Example
curl -i -X POST \ -H "Accept: application/json" \ -H "X-Auth-Token: 39be9f8d53044388b7f2e867eba8b140" \ -d '{ "service_id": "9d6441f6-c5a0-4dcf-a1a9-1a4d724e51fd", "user_name": "dbuser001", "password": "wa6g76w08#", "hostname": "cl1.example.com", "memo": "memo" }' \ https://database-hosting.tyo1.cloud.z.com/v1/users
HTTP/1.1 200 Success Date: Tue, 09 Dec 2014 01:46:58 GMT Server: Apache Content-Length: 1003 Content-Type: application/json { "user" : { "service_id": "9d6441f6-c5a0-4dcf-a1a9-1a4d724e51fd", "user_id": "5f02c821-977f-4160-812d-397a5e3c7caa", "user_name": "02p8y_dbuser001", "hostname": "cl1.example.com", "memo": "memo", "status": "creating" } }