[Hawkular-dev] How to create user/persona from Rest?
Juraci Paixão Kröhling
jpkroehling at redhat.com
Tue Jul 7 04:09:28 EDT 2015
Viet,
Do you need to create an user or a persona?
If you need to create an user, you have two options:
1) Change the realm that we import during the boot to include the users
you need. I think Alerts is doing something similar.
http://git.io/vqBY0
2) As we use Keycloak in the background, you can also create users using
their API. You'd need to check their documentation on how to achieve
that. http://keycloak.github.io/docs/
If all you need is a persona, it's easier:
$ curl -v \
-H 'Content-type: application/json' \
-H 'Accept: application/json' \
-d '{"name":"Acme, Inc"}' \
-X POST \
-u jdoe:password \
http://localhost:8080/hawkular-accounts/organizations
The ID returned for this organization can be then passed as
'Hawkular-Persona' to the backend.
- Juca.
On 07/06/2015 06:20 PM, Viet Nguyen wrote:
> Hello everyone,
>
> To make it easier to run test automation I'm looking for a way to create new users possibly from REST Api. Someone mentioned on IRC it is possible via Keycloak. Please advise.
>
> thanks,
>
> Viet
> _______________________________________________
> hawkular-dev mailing list
> hawkular-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/hawkular-dev
>
More information about the hawkular-dev
mailing list