Create User using an API call [closed]

asked 2014-02-25 01:23:57 -0600

Lokesh gravatar image

updated 2014-02-25 04:26:03 -0600

Hi , May i know how to create the Openstack User using the api call .

Regards , Lokesh.S

edit retag flag offensive reopen merge delete

Closed for the following reason duplicate question by Lokesh
close date 2014-04-14 08:55:53.240776

2 answers

Sort by » oldest newest most voted

answered 2014-02-25 09:33:54 -0600

KeithJ gravatar image

updated 2014-02-26 06:17:48 -0600

Apologies; It seemed I misunderstood the question.    But from teh manuals I found this:

and if you look under users you will find this when you click on the detail button

Adds a user.

Normal Response Codes201
Error Response CodesidentityFault (400, 500, …), badRequest (400), unauthorized (401), forbidden (403), badMethod (405), overLimit (413), serviceUnavailable (503), itemNotFound (404)
    "user": {
        "default_project_id": "--default-project-id--",
        "description": "a user",
        "domain_id": "1789d1",
        "email": "...",
        "id": "--user-id--",
        "links": {
            "self": "http://identity:35357/v3/users/--user-id--"
        "name": "admin"
edit flag offensive delete link more

answered 2014-02-25 23:04:09 -0600

Lokesh gravatar image

Helo KeithJ ,

That worked fine ,Thanks for the reply

I have used the code as shown below , here is the post data that i have sent along with the curl

$post='{"user":{"name":"guru", "email":"", "enabled":true, "OS-KSADM:password":"password123"}}';

Regards , Lokesh.S

edit flag offensive delete link more


Hello Keith ,

                   A small issue am facing here in relating the project_id to a user . If i use "default_project_id":"...", this parameter while creating the user , will this creates a user along with the project that relates the project & user ? or is there any other way of mapping ???
Lokesh gravatar imageLokesh ( 2014-03-24 09:13:47 -0600 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools


Asked: 2014-02-25 01:23:57 -0600

Seen: 88 times

Last updated: Feb 26 '14