Get Authentication Token
Options
Ram Singh
Member Posts: 5 ✭
Hello Guys,
We are trying to implement Reckon One API. I got success to get records from your website as discussed on below link:
https://reckonproduction.portal.azure-api.net/
I tried to implement the same thing in code, but I am not able to get the token. I tried but didn't succeed.
I have used the attached code, please correct me where I am doing wrong:
The output I am getting from the following Request:
In Console:
In Network Tab:
Please help me work around.
Wish and hope to hear back from you asap.
We are trying to implement Reckon One API. I got success to get records from your website as discussed on below link:
https://reckonproduction.portal.azure-api.net/
I tried to implement the same thing in code, but I am not able to get the token. I tried but didn't succeed.
I have used the attached code, please correct me where I am doing wrong:
The output I am getting from the following Request:
In Console:
In Network Tab:
Please help me work around.
Wish and hope to hear back from you asap.
0
Comments
-
Hi Ram,
Your code snippets (images) dont seem to be visable?? Can you copy directly into the forum?0 -
var params = { // Request parameters grant_type: 'password', username: 'xxxxxx@xxxxxx.com', password: 'xxxxxx', scope: 'read+write', Authorization: 'Basic MTIzNDo1xxxx', MTIzNDo1Njc4: 'xxxxxxxx-xxxx-4xxx-9xxx-7fd287c9f06e:88dee5d7-ff30-4cc8-b360-22b27xxxxxx' }; $.ajax({ url: "https://identity.reckon.com/connect/token?" + $.param(params), beforeSend: function (xhrObj) { xhrObj.setRequestHeader("Authorization", "Basic MTIzNDo1xxxx"); xhrObj.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); // Request headers }, type: "POST", // Request body data: "{body}", }) .done(function (data) { console.log(data); alert("success"); }) .fail(function () { alert("error");
});0 -
Hi Ram,
It's most likely the grant type of the authorization that you are expecting. We use Authorization Code by default for OAuth2. We do have a support ticket where I think you have requested Resource Owner. Is that correct?0 -
Hi Jason,
Yes, i requested, but not sure if it is the correct for me..
0 -
You now have the resource owner flow type assigned to your Identity Server credentials Ram, therefore check our online docs to ensure you are including the correct header syntax.0
-
Hi Jason,
I tried to use the Auth_code for Grant_Type, but still, it's throwing me same error.0 -
Hi Ram, so your grant type has been changed to Resource Owner as requested. Check our docs to make sure you are passing the correct header.0
-
Hi Jason,
Could you please share the link where you have specified this thing for Resource Owner.
0 -
Hi Ram
Now that Jason ha changed the identity server credentials, your grant_type is password as per your above code
Thanks
Simon H
Reckon API0 -
0
-
Look at Resource Owner. There are also links to a site that explains the grant types for OAuth2 so please ensure resource owner is for you. If not let us know.0
-
Here is that link I mentioned above: https://www.digitalocean.com/community/tutorials/an-introduction-to-oauth-2
Our default Grant Type is Authorization Code and we do not offer any others unless you provide your specific use case (which you did in your email to us).
Other available are Implicit and Resource Owner.
The above site gives good examples on what each is best used for.0
Categories
- All Categories
- 6.9K Accounts Hosted
- 11 📢 Reckon Accounts Hosted - Announcements
- 6K Reckon Accounts (Desktop)
- 3 📢 Reckon Accounts Desktop - Announcements
- 1.2K Reckon Payroll 🚀
- 21 📢 Reckon Payroll - Announcements
- 21 Reckon Payroll Help Videos 🎥
- 21 Reckon Mate App
- 3.1K Reckon One
- 7 📢 Reckon One - Announcements
- 11 Reckon Invoices App
- 14 Reckon Insights
- 114 Reckon API
- 830 Payroll Premier
- 326 Point of Sale
- 2K Personal Plus and Home & Business
- 74 About Reckon Community