Oauth2 ENG: erinevus redaktsioonide vahel

Allikas: Excellent || Opendoc
Mine navigeerimisribale Mine otsikasti
(Uus lehekülg: 'OAuth Testing Tool with Google OAuth 2.0 playground # Go to You can create developer credentials before visiting the website. Use "<nowiki>https://developers.google.com/oauthpla...')
 
Resümee puudub
 
(ei näidata sama kasutaja 3 vahepealset redaktsiooni)
1. rida: 1. rida:
OAuth Testing Tool with Google OAuth 2.0 playground
OAuth Testing Tool with Google OAuth 2.0 playground


# Go to You can create developer credentials before visiting the website. Use "<nowiki>https://developers.google.com/oauthplayground</nowiki>" as allowed redirect url.
#Go to https://mystandard.hansaworld.com/edit/devcred
# Goto page <nowiki>https://developers.google.com/oauthplayground/</nowiki>
#You can create developer credentials here. Use "<nowiki>https://developers.google.com/oauthplayground</nowiki>" as allowed redirect url. <br />[[Fail:Mystandard Setting.png|raamita]]
 
#Goto page <nowiki>https://developers.google.com/oauthplayground/</nowiki>
2. Click on OAuth 2.0 Configuration button
#Click on OAuth 2.0 Configuration button
 
#Change the folling settings:
3. Change the folling settings:
##OAuth Endpoints: Custom
 
##Authorization endpoint: <nowiki>https://standard-id.hansaworld.com/oauth-authorize</nowiki>
  - OAuth Endpoints: Custom
##Token endpoint: <nowiki>https://standard-id.hansaworld.com/oauth-token</nowiki>
 
##OAuth Client ID: Client ID from MyStandard page
  - Authorization endpoint: <nowiki>https://standard-id.hansaworld.com/oauth-authorize</nowiki>
##OAuth Client Secret: Client Secret from MyStandard page[[Fail:Google lehe setting.png|tühi|pisi|398x398px]]<br />
 
#On left size you need to specify the scope that you want to authorize for. For HW Rest API there is no scope to specify so you can write anything in free text and click button "Authorize APIs"
  - Token endpoint: <nowiki>https://standard-id.hansaworld.com/oauth-token</nowiki>
 
  - OAuth Client ID: Client ID from MyStandard page
 
  - OAuth Client Secret: Client Secret from MyStandard page
 
 
 
4. On left size you need to specify the scope that you want to authorize for. For HW Rest API there is no scope to specify so you can write anything in free text and click button "Authorize APIs"


5. If everything was fine with the request you will be redirected to StandardID website to authorize for the application
5. If everything was fine with the request you will be redirected to StandardID website to authorize for the application

Viimane redaktsioon: 1. aprill 2021, kell 10:07

OAuth Testing Tool with Google OAuth 2.0 playground

  1. Go to https://mystandard.hansaworld.com/edit/devcred
  2. You can create developer credentials here. Use "https://developers.google.com/oauthplayground" as allowed redirect url.
    Mystandard Setting.png
  3. Goto page https://developers.google.com/oauthplayground/
  4. Click on OAuth 2.0 Configuration button
  5. Change the folling settings:
    1. OAuth Endpoints: Custom
    2. Authorization endpoint: https://standard-id.hansaworld.com/oauth-authorize
    3. Token endpoint: https://standard-id.hansaworld.com/oauth-token
    4. OAuth Client ID: Client ID from MyStandard page
    5. OAuth Client Secret: Client Secret from MyStandard page
      Google lehe setting.png

  6. On left size you need to specify the scope that you want to authorize for. For HW Rest API there is no scope to specify so you can write anything in free text and click button "Authorize APIs"

5. If everything was fine with the request you will be redirected to StandardID website to authorize for the application

6. After that you will be redirected back to google's playground

7. Then you will be give option to "Exchange authorization code for tokens" - click the button. This will ask StandardID server for tokens that will be used for making API request

8. Now you will be asked to specify request URL - specify your servers url with fill Rest API path. IMPORTANT - from this website the URL needs to have valid certificates. You can't put expired or invalid certificates on the server and there is no way how to go around this (at least I couldn't find - i have a server for testing with url https://restapi.hansaworld.com:1098).

Full URL would look like this https://restapiserver.excellent.ee:1098/api/1/CUVc

9. Click button "Send the request" - this will make the call to your server and return the data