Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
bchavez committed Nov 21, 2018
1 parent b1ba217 commit 1327d83
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
3 changes: 3 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## v5.0.0-beta-6
* PR 44: Add callback method OnRefresh when client renews oauth token.

## v5.0.0-beta-5
* PR 41: OAuth Auto Refresh tokens supported.
* Renamed `CoinbaseApi` to `CoinbaseClient`.
Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,9 @@ var newRefreshToken = newToken.RefreshToken;
The `CoinbaseClient` supports automatic token renewal. If you want to avoid refreshing your every two hours you can use the following `.WithAutomaticOAuthTokenRefresh()` extension method to activate automatic token renewal. When creating the `CoinbaseClient` object in **Step 3** above do the following:

```csharp
var client = new CoinbaseClient(new OAuthConfig { AccessToken = token.AccessToken })
.WithAutomaticOAuthTokenRefresh(OAuthClientAppId, OAuthClientSecret, refreshToken);
var client = new CoinbaseClient(new OAuthConfig { AccessToken = token.AccessToken,
RefreshToken = token.RefreshToken })
.WithAutomaticOAuthTokenRefresh(ClientId, ClientSecret);
```
You only need to call `.WithAutomaticOAuthTokenRefresh` once when creating the `CoinbaseClient` object.

Expand Down

0 comments on commit 1327d83

Please sign in to comment.