2605
Views
6
Comments
Solved
How to consume REST API that uses Oauth2?

Hello,

I'm trying to consume a REST api (Zoho CRM) https://www.zoho.com/crm/help/api/v2/#OAuth2_0

Is there a built in function or best practice for dealing with OAuth authentication?

I'm fairly new to Outsystems, any pointers would be appreciated.

Thank you

2016-03-23 19-42-07
Miguel Domingues
Staff
Solution

Hi David,

Like John said, there are several components on Forge related with that, and that already implement it.

Nevertheless, if you want to learn how to implement it, we have just release an exercise focusing on how to integrate with an OAuth 2.0 provider.
In this exercise we use Google OAuth, but you could adapt it to another provider.

Check the content here: https://www.outsystems.com/learn/lesson/1839/integrating-with-oauth-exercise/

If you have any feedback let us know!

Regards

2021-04-21 23-06-46
Jeanene Williams

There are a number of components in the Outsystems Forge that use oAuth, I suggest doing a search on oAuth in the forge and see if either one of them can be used or looking at the code to see how they do it.

2016-03-23 19-42-07
Miguel Domingues
Staff
Solution

Hi David,

Like John said, there are several components on Forge related with that, and that already implement it.

Nevertheless, if you want to learn how to implement it, we have just release an exercise focusing on how to integrate with an OAuth 2.0 provider.
In this exercise we use Google OAuth, but you could adapt it to another provider.

Check the content here: https://www.outsystems.com/learn/lesson/1839/integrating-with-oauth-exercise/

If you have any feedback let us know!

Regards

UserImage.jpg
Joshua Bye

Miguel,

Why does OutSystems not have an automatic handling of Oauth2?

This explanation is painful to follow and doesn't actually help.

2016-03-23 19-42-07
Miguel Domingues
Staff

Hi Joshua,

The REST integration provided by the OutSystems platform tries to be generic to be able to accommodate for several of the existing use cases, including custom ones. OAuth2 should be one of those cases.

Similar to OAuth2, there are many other authentication mechanisms based on REST, each one with their own specifics.


UserImage.jpg
Joshua Bye

Miguel,

That's a splendid marketing answer.

There is nothing that prevents OutSystems from taking sensible steps to implement GOOD examples and explanations as well as helpers for the most common scenarios.

your answer translates to me as "we were too lazy to put in the effort"

2020-02-15 02-48-12
Galter
Champion

Hello all, I wrote an example of integration with ZOHO.


Implementing integration with an external (or internal) API that you need to authenticate with OAuth2.0 is relatively easy and quick to implement with Outsystems. What you need is an example, the path of the stones ... I hope I can help you here.


Basically, the process is as follows:


Perform the initial configuration on the ZOHO website, then perform steps 1, 2, 3 below:

1- You need to map and consume an EndPoint that generates an Authorization (Bearer token or simulate, depends on the partner) on the partner you want to consume the API.

2- You need to map and consume the authenticated methods of the partner API, passing the token generated in step 1 above.

3- Refreshing your access Tokens


https://www.outsystems.com/forums/discussion/63381/sample-integration-via-api-with-zoho-crm/#Post248141


I hope it helps in your integration


Att.,

Galter.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.