From 25c6e4ce4f97c63bcfb9cfb7310dfa808e2f6355 Mon Sep 17 00:00:00 2001 From: Matt <85322+mattmassicotte@users.noreply.github.com> Date: Mon, 16 Oct 2023 11:43:50 -0400 Subject: [PATCH] Add integration section --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index fffae36..5c424bd 100644 --- a/README.md +++ b/README.md @@ -22,6 +22,16 @@ There's also built-in support for services to streamline integration: If you'd like to contribute a similar thing for another service, please open a PR! +## Integration + +Swift Package Manager: + +```swift +dependencies: [ + .package(url: "https://github.com/ChimeHQ/OAuthenticator", from: "0.3.0") +] +``` + ## Usage The main type is the `Authenticator`. It can execute a `URLRequest` in a similar fashion to `URLSession`, but will handle all authentication requirements and tack on the needed `Authorization` header. Its behavior is controlled via `Authenticator.Configuration` and `URLResponseProvider`. By default, the `URLResponseProvider` will be a private `URLSession`, but you can customize this if needed.