1. Passing user's information
The first step is to pass required information to UserRules. These all params need to be passed in URL.
||String||yes||A unique identifier for the user (ex: the user_id in your system).|
||String||yes||User Display Name|
||String||yes||User Email, required for user to be updated on his feedbacks|
||String||User Image Url, This will be used to show images from your systems|
||String||yes||true||Always pass value true.|
||String||yes||Your company's short name registered with UserRules.|
2. Create a Signature
Next, we'll need a way to ensure that you sent this request. It will need another parameter
sign which you can generate using your API Key (you can get your API Key from
My Company -> Settings -> Advanced Settings).
- Create a string like this
"uid=" + uid + "&un=" + un + "&uem=" + uemail + "&uimg=" + uimg
- You will create a Hmac-SHA1 hash based signature for this string.
- Base64 encode the encrypted output to generate the token.
The next step is to append the signature to UserRules using a
sign request parameter.
sign has to be last request parameter in order for it to work.
3. Sample SSO Request
We have created a live demo sample request which will show how your request should look like in the end.
Sample Request: http://www.userrules.com/company/userrules/forum?sso=true&companyShortName=userrules&uid=pavitar_beniwal&un=Pavitar%20Beniwalfirstname.lastname@example.org&uimg=&sign=TfwrzfiOic2ouJRNfyH2Nh5InFM=
If you need help, please contact support.