https://github.com/rubygarage/authorize-me
Authorization with social networks
https://github.com/rubygarage/authorize-me
auth authorization cocoapod ios login signin social social-login social-network swift
Last synced: 6 months ago
JSON representation
Authorization with social networks
- Host: GitHub
- URL: https://github.com/rubygarage/authorize-me
- Owner: rubygarage
- License: mit
- Archived: true
- Created: 2017-06-14T15:53:38.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2019-04-16T12:43:34.000Z (about 6 years ago)
- Last Synced: 2024-03-26T22:57:24.397Z (over 1 year ago)
- Topics: auth, authorization, cocoapod, ios, login, signin, social, social-login, social-network, swift
- Language: Swift
- Homepage: https://rubygarage.org
- Size: 735 KB
- Stars: 44
- Watchers: 6
- Forks: 15
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# AuthorizeMe
**AuthorizeMe** is a mobile library for iOS that designed to easy implementation of authorization with social networks. This repository holds the source code that contain a set of providers that implement the functionality needed to get credentials and information about user from various social services.
## Features
* **No dependency:** AuthorizeMe is a fully Swift framework without any dependency. Use the library without any additional Xcode project configurations after installation.
* **Authorization:** There are two ways to authorize user. Use `SystemProvider` for authorize user with iOS social accounts data. Use `WebProvider` for authorize user with `UIWebView` in case when is not possible to use first way.
* **Custom provider:** Implement own provider if AuthorizeMe does not following social network that needed. It is easy and free.## Getting Started
### Installation
`CocoaPods` is a dependency manager for Cocoa projects. Install it with the following command:
```bash
$ gem install cocoapods
```To integrate AuthorizeMe into Xcode project using CocoaPods, specify it in `Podfile`:
```ruby
platform :ios, '10.0'target 'Target Name' do
use_frameworks!pod 'AuthorizeMe'
# or
# pod 'AuthorizeMe/Facebook'
# to integrate Facebook onlyend
```Then, run the following command:
```bash
$ pod install
```### First Look
Firstly, import `AuthorizeMe` framework into class in Xcode project.
````swift
import AuthorizeMe
````Then, turn logging on for seen error messages of authorization process if needed. Do it in `AppDelegate` class is the best way.
````swift
DebugService.isNeedOutput = true
````Finally, use `Authorize` manager that authorize user with `SystemProvider` if it possible, but in other case manager authorize user with `WebProvider`.
````swift
Authorize.me.on("Name of social network") { session, error in
// Do something
}
````To separate usage of various providers, use `SystemProvider` and `WebProvider` apart.
````swift
let provider = FacebookSystemProvider()
// or
// let provider = TwitterWebProvider()provider.authorize { session, error in
// Do something
}
````## Guides
* **[Facebook Provider](https://github.com/rubygarage/authorize-me/wiki/Facebook-Provider)**
* **[Twitter Provider](https://github.com/rubygarage/authorize-me/wiki/Twitter-Provider)**
* **[Google Provider](https://github.com/rubygarage/authorize-me/wiki/Google-Provider)**
* **[Instagram Provider](https://github.com/rubygarage/authorize-me/wiki/Instagram-Provider)**
* **[LinkedIn Provider](https://github.com/rubygarage/authorize-me/wiki/LinkedIn-Provider)**
* **[Custom Provider](https://github.com/rubygarage/authorize-me/wiki/Custom-Provider)**
***
AuthorizeMe library is licensed under the [MIT](https://opensource.org/licenses/MIT) license. See the [LICENSE](https://github.com/rubygarage/authorize-me/blob/master/LICENSE) file for more info.
***RubyGarage is a leading software development and consulting company in Eastern Europe. Our main expertise includes Ruby and Ruby on Rails, but we successfully employ other technologies to deliver the best results to our clients. [Check out our portfolio](https://rubygarage.org/portfolio) for even more exciting works!