<div dir="ltr"><div><div>Hi all,<br><br></div>please, could somebody clarify issue (see bottom of the mail) discovered in version 1.6.1.Final?<br>The same behavior is detected in version 1.7.0.Final.<br><br></div><div>This behavior differs from a Create a New User where the JSON body parameter &quot;id&quot; is skipped.<br></div><div><br>Thanks a lot.<br><br></div><div>Best regards,<br></div><div>Juraj<br></div><div><div><div><div class="gmail_extra"><br><div class="gmail_quote">2015-11-12 10:32 GMT+01:00 Juraj Janosik <span dir="ltr">&lt;<a href="mailto:juraj.janosik77@gmail.com" target="_blank">juraj.janosik77@gmail.com</a>&gt;</span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div>Hi,<br></div>I want to clarify the &quot;Create a new client&quot; via REST API <br>especially for body parameter &quot;id&quot; from &quot;ClientRepresentation&quot;.<br></div></div>If I set the parameter &quot;id&quot; in the request body (see example below), <br>the value is set to the client. No new id value is generated for the client, which is the typically behavior of &quot;<a href="http://keycloak.github.io/docs/rest-api/index.html#_create_a_new_role_for_the_realm_or_client" target="_blank">Create a new role for the realm or client</a>&quot; and &quot;<a href="http://keycloak.github.io/docs/rest-api/index.html#_create_a_new_user" target="_blank">Create a new user</a>&quot;.<br></div><div>Is this a correct behavior?<br></div><div><br>Tested data example:<br>&quot;Create Client&quot;:<br>&quot;method&quot;:&quot;POST&quot;,&quot;url&quot;:&quot;&lt;URL&gt;:&lt;PORT&gt;/auth/admin/realms/&lt;REALM&gt;/clients&quot;<br></div><div>&quot;body&quot;:<br>&quot;{<br>&quot;id&quot;:&quot;3&quot;,<br>&quot;clientId&quot;:&quot;testclient-3&quot;,<br>&quot;name&quot;: &quot;testclient-3&quot;,<br>&quot;description&quot;: &quot;TESTCLIENT-3&quot;,<br>&quot;enabled&quot;: true,<br>&quot;redirectUris&quot;:[ &quot;\\&quot; ],<br>&quot;publicClient&quot;: true<br>}&quot;<br></div><div>&quot;headers&quot;:<br>[[&quot;Content-Type&quot;,&quot;application/json&quot;],<br>[&quot;Authorization&quot;,&quot;Bearer &lt;ACCESS_TOKEN&gt;]]<br><br>Output for GET clients looks like:<br> {<br>        &quot;<b>id&quot;: &quot;3&quot;</b>,<br>        &quot;clientId&quot;: &quot;testclient-3&quot;,<br>        &quot;name&quot;: &quot;testclient-3&quot;,<br>        &quot;description&quot;: &quot;TESTCLIENT-3&quot;,<br>        &quot;surrogateAuthRequired&quot;: false,<br>        &quot;enabled&quot;: true,<br>        &quot;clientAuthenticatorType&quot;: &quot;client-secret&quot;,<br>        &quot;redirectUris&quot;:<br>        [<br>            &quot;\&quot;<br>        ],<br>        &quot;webOrigins&quot;:<br>        [<br>        ],<br>        &quot;notBefore&quot;: 0,<br>        &quot;bearerOnly&quot;: false,<br>        &quot;consentRequired&quot;: false,<br>        &quot;serviceAccountsEnabled&quot;: false,<br>        &quot;directGrantsOnly&quot;: false,<br>        &quot;publicClient&quot;: true,<br>        &quot;frontchannelLogout&quot;: false,<br>        &quot;attributes&quot;:<br>        {<br>        },<br>...<br><br>Thanks a lot.<br><br></div><div>Best Regards,<br></div><div>Juraj<br></div><div><br></div><div><div><div><br></div></div></div></div>
</blockquote></div><br></div></div></div></div></div>