Skip to content

Commit c2b83b9

Browse files
authored
Merge pull request #6726 from AndyButland/patch-1
Update authorized-services.md
2 parents 3533d1f + 679f24e commit c2b83b9

File tree

1 file changed

+12
-24
lines changed

1 file changed

+12
-24
lines changed

marketplace-and-integrations/packages/authorized-services.md

Lines changed: 12 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,9 @@ There are also differences across the request and response structures and variat
2323

2424
The package tries to implement a single, best practice implementation of working with OAuth. For particular providers the specific flow required can be customized via configuration or code.
2525

26-
The primary use case for this package is when working with services that offer an OAuth2/OAuth1 default authentication and authorization flow against an "app". The developer will need to create this "app" with the service. By doing this, for OAuth1 information such as "client ID"/"consumer key" and "client secret"/"consumer secret" can be applied to the configuration.
26+
The primary use case for this package is when working with services that offer an OAuth authentication and authorization flow against an "app". The developer will need to create this "app" with the service. From this, details such as client key and secret can be obtained and applied to the configuration.
2727

28-
When creating the app it is usually necessary to configure a call-back URL. You should use the following:
29-
30-
* For OAuth2: `/api/AuthorizedServiceResponse/HandleOAuth2IdentityResponse`
31-
* For OAuth1: `/api/AuthorizedServiceResponse/HandleOAuth1IdentityResponse`
32-
33-
In addition, the package supports integration with OAuth1 or Api key based authentication and authorization services.
28+
In addition, the package supports integration with Api key based authentication and authorization services.
3429

3530
## Features
3631

@@ -48,30 +43,21 @@ Each tree entry has a management screen where an administrator can authenticate
4843

4944
![authorized-screen](images/authorized-screen.png)
5045

51-
A service can be configured to allow the manual entry of access tokens/API keys manually using the `CanManuallyProvideToken` or `CanManuallyProvideApiKey` settings. If this is set to `true`, a new section will be available for providing them.  
46+
A service can be configured to allow the manual entry of access tokens/API keys manually using the `CanManuallyProvideToken` or `CanManuallyProvideApiKey` settings. If this is set to `true`, a new section will be available for providing them.
5247

5348
<figure><img src="images/provide-api-key.png" alt=""><figcaption></figcaption></figure>
5449

5550
<figure><img src="images/provide-oauth2-token.png" alt=""><figcaption></figcaption></figure>
5651

5752
<figure><img src="images/provide-oauth1-token.png" alt=""><figcaption></figcaption></figure>
5853

59-
### IAuthorizedServiceCaller interface
60-
61-
Secondly, the developer has access to an interface - `IAuthorizedServiceCaller` - that they can inject instances of and use to make authorized requests to the service's API.
62-
63-
Using a settings screen the administrator can review the service configuration.
64-
65-
![settings-screen](images/settings-screen.png)
54+
From the settings panel the administrator can review the service configuration.
6655

67-
Depending on the authentication method of the service,
56+
<figure><img src="images/settings-screen.png" alt=""><figcaption></figcaption></figure>
6857

69-
* `OAuth1`
70-
* `OAuth2AuthorizationCode` (default)
71-
* `OAuth2ClientCredentials`
72-
* `ApiKey`
58+
### IAuthorizedServiceCaller interface
7359

74-
The interface provides methods for retrieving the value of the access tokens or API key - `GetOAuth1Token()`, `GetOAuth2Token()` and `GetApiKey()`. These will return null if the token or key is not found. They will also return null if the service is not configured to use the authorization method related to these objects.
60+
Secondly, the developer has access to an interface - `IAuthorizedServiceCaller` - that they can inject instances of and use to make authorized requests to the service's API.
7561

7662
## Usage
7763

@@ -85,10 +71,10 @@ The package should be installed into your Umbraco solution from [NuGet](https://
8571

8672
Services supported by the package will often offer an OAuth authentication and authorization flow against an "app" that the developer will need to create. This will make available information, including for example a "**client ID**" and "**client secret**", that will need to be applied in configuration.
8773

88-
When creating the app it will usually be necessary to configure a call back URL. You should use the following:
74+
When creating the app it will be necessary to configure a call back URL. You should use the following:
8975

90-
- For OAuth2: `/umbraco/api/AuthorizedServiceResponse/HandleOAuth2IdentityResponse`
91-
- For OAuth1: `/umbraco/api/AuthorizedServiceResponse/HandleOAuth1IdentityResponse`
76+
* For OAuth2: `/umbraco/api/AuthorizedServiceResponse/HandleOAuth2IdentityResponse`
77+
* For OAuth1: `/umbraco/api/AuthorizedServiceResponse/HandleOAuth1IdentityResponse`
9278

9379
### Configuring a Service
9480

@@ -247,6 +233,8 @@ Task<string?> GetOAuth2Token(string serviceAlias);
247233
Task<string?> GetApiKey(string serviceAlias);
248234
```
249235

236+
These will return null if the token or key is not found. They will also return null if the service is not configured to use the authorization method related to these objects.
237+
250238
## Verified Providers
251239

252240
The following service providers have been tested against the package implementation. For each one the necessary configuration is listed.

0 commit comments

Comments
 (0)