<div dir="ltr"><p style="margin:0px;font-size:12px;font-family:Helvetica">Hi All,</p><p style="margin:0px;font-size:12px;font-family:Helvetica"><br></p><p style="margin:0px;font-size:12px;font-family:Helvetica">I have a question regarding using novaclient API. </p>
<p style="margin:0px;font-size:12px;font-family:Helvetica;min-height:14px"><br></p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">I need to use it for getting a list of instances for an user/project.</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">In oder to do that I tried to use :</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica;min-height:14px"><br></p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">from novaclient.v1_1 import client</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">nc = client.Client(<b>username</b>,<b>token_id</b>, project_id, auth_url,insecure,cacert)</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">nc.servers.list()</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica;min-height:14px"><br></p><p style="margin:0px;font-size:12px;font-family:Helvetica;min-height:14px">( however, the comment on the code/document says different thing which as far as tried it didn't work.<br>
</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">>>> client = Client(USERNAME, <b>PASSWORD</b>, PROJECT_ID, AUTH_URL)</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica;min-height:14px"><br></p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">so it seems token_id has to be provided.</p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">I can get the token_id using keystone REST API (<i><u><a href="http://localhost:5000/v2.0/tokens">http://localhost:5000/v2.0/tokens</a> …-d ' the credentials …username and password'</u></i>. </p>
<p style="margin:0px;font-size:12px;font-family:Helvetica">And my question is: how to get credentials for an user in the code when using the keystone's REST API? Is there any api to get such an info?</p><p style="margin:0px;font-size:12px;font-family:Helvetica">
<br></p><p style="margin:0px;font-size:12px;font-family:Helvetica">Appreciate your comments.</p><p style="margin:0px;font-size:12px;font-family:Helvetica"><br></p><p style="margin:0px;font-size:12px;font-family:Helvetica">
Regards,</p><p style="margin:0px;font-size:12px;font-family:Helvetica">Nader.</p><p style="margin:0px;font-size:12px;font-family:Helvetica"><br></p></div>