Last modified by bougault on 2022/03/02 11:58

From version 3.2
edited by allan
on 2019/09/19 11:20
Change comment: There is no comment for this version
To version 4.2
edited by allan
on 2019/09/19 14:22
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -162,3 +162,34 @@
162 162  
163 163  * your client **secret** ("secret" attribute) which is needed by your application to **authenticate to the IAM server** when making backend calls
164 164  * your client **registration access token** ("registrationAccessToken")  which is the token you will need to authenticate when **modifying your client in the future**
165 +
166 +=== Modifying your client ===
167 +
168 +Updating a client is done with a PUT request:
169 +
170 +{{code language="bash"}}
171 +# Set your registration token and client id
172 +clb_reg_token=...
173 +
174 +# Update the client
175 +curl -X PUT https://iam.humanbrainproject.eu/auth/realms/hbp/clients-registrations/default/my-awesome-client \
176 + -H "Authorization: Bearer ${clb_reg_token}" \
177 + -H 'Content-Type: application/json' \
178 + -d '{
179 + "clientId": "my-awesome-client",
180 + "redirectUris": [
181 + "/relative/redirect/path",
182 + "/these/can/use/wildcards/*",
183 + "/a/new/redirect/uri"
184 + ]
185 + }' |
186 +
187 +# Prettify the JSON response
188 +json_pp;
189 +{{/code}}
190 +
191 + Note that your client id must be provided both in the endpoint URL and within the body of the request.
192 +
193 +{{warning}}
194 +/!\ ** Each time you modify your client, a new registration access token will be generated. You need to track of your token changes in order to keep access to your client.   **/!\
195 +{{/warning}}