{"id":13428612,"url":"https://github.com/calebd/SimpleAuth","last_synced_at":"2025-03-16T01:32:47.711Z","repository":{"id":11671448,"uuid":"14180840","full_name":"calebd/SimpleAuth","owner":"calebd","description":"Simple social authentication for iOS.","archived":true,"fork":false,"pushed_at":"2018-04-24T13:44:21.000Z","size":1788,"stargazers_count":1145,"open_issues_count":52,"forks_count":135,"subscribers_count":37,"default_branch":"master","last_synced_at":"2025-02-24T16:32:12.089Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://simpleauth.io","language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/calebd.png","metadata":{"files":{"readme":"Readme.markdown","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-11-06T17:58:32.000Z","updated_at":"2025-01-17T15:55:54.000Z","dependencies_parsed_at":"2022-09-24T06:11:17.410Z","dependency_job_id":null,"html_url":"https://github.com/calebd/SimpleAuth","commit_stats":null,"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calebd%2FSimpleAuth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calebd%2FSimpleAuth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calebd%2FSimpleAuth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calebd%2FSimpleAuth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/calebd","download_url":"https://codeload.github.com/calebd/SimpleAuth/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243814905,"owners_count":20352037,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-31T01:01:01.734Z","updated_at":"2025-03-16T01:32:47.412Z","avatar_url":"https://github.com/calebd.png","language":"Objective-C","funding_links":[],"categories":["Authentication","Misc","Objective-C"],"sub_categories":["Other free courses","Getting Started","ReactiveCocoa"],"readme":"# SimpleAuth\n\nSimpleAuth is designed to do the hard work of social account login on iOS. It has a small set of public APIs backed by a set of \"providers\" that implement the functionality needed to communicate with various social services.\n\nSimpleAuth currently has the following providers:\n\n- [Twitter](https://github.com/calebd/SimpleAuth/wiki/Twitter)\n- [Facebook](https://github.com/calebd/SimpleAuth/wiki/Facebook)\n- [Instagram](https://github.com/calebd/SimpleAuth/wiki/Instagram)\n- [Tumblr](https://github.com/calebd/SimpleAuth/wiki/Tumblr)\n- [Dropbox](https://github.com/calebd/SimpleAuth/wiki/Dropbox)\n- [Foursquare](https://github.com/calebd/SimpleAuth/wiki/Foursquare)\n- [Meetup](https://github.com/calebd/SimpleAuth/wiki/Meetup)\n- [LinkedIn](https://github.com/calebd/SimpleAuth/wiki/LinkedIn)\n- [Sina Weibo](https://github.com/calebd/SimpleAuth/wiki/SinaWeibo)\n- [Google](https://github.com/calebd/SimpleAuth/wiki/Google)\n- [Box](https://github.com/calebd/SimpleAuth/wiki/Box)\n- [OneDrive](https://github.com/calebd/SimpleAuth/wiki/OneDrive)\n\n## Installing\n\nInstall SimpleAuth with CocoaPods. For example, to use Facebook and Twitter authentication, add\n\n```ruby\npod 'SimpleAuth/Facebook'\npod 'SimpleAuth/Twitter'\n```\n\nto your `Podfile`.\n\n## Usage\n\nConfiguring  and using SimpleAuth is easy:\n\n````swift\n// Somewhere in your app boot process\nSimpleAuth.configuration()[\"twitter\"] = [\n    \"consumer_key\": \"KEY\",\n    \"consumer_secret\": \"SECRET\"\n]\n````\n\n````swift\n// Authorize\nfunc loginWithTwitter() {\n    SimpleAuth.authorize(\"twitter\", completion: { responseObject, error in\n        println(\"Twitter login response: \\(responseObject)\")\n    })\n}\n````\n\n## Implementing  a Provider\n\nThe API for creating providers is pretty simple. Be sure to look at `SimpleAuthProvider` and `SimpleAuthWebLoginViewController`. These classes will help you simplify your authentiction process. Providers should be stored in `Pod/Providers/` and have an appropriately named folder and sub spec. All providers are automatically registered with the framework. There are a handful of methods you'll need to implement:\n\nLet SimpleAuth know what type of provider you are registering:\n\n````objc\n+ (NSString *)type {\n    return @\"facebook\";\n}\n````\n\nOptionally, you may return a set of default options for all authorization options to use:\n\n````objc\n+ (NSDictionary *)defaultOptions {\n    return @{\n        @\"permissions\" : @[ @\"email\" ]\n    };\n}\n````\n\nFinally, provide a method for handling authorization:\n\n````objc\n- (void)authorizeWithCompletion:(SimpleAuthRequestHandler)completion {\n\t// Use values in self.options to customize behavior\n\t// Perform authentication\n\t// Call the completion\n}\n````\n\nThe rest is up to you! I welcome contributions to SimpleAuth, both improvements to the library itself and new providers.\n\n## License\n\nSimpleAuth is released under the MIT license.\n\n## Thanks\n\nSpecial thanks to my friend [@soffes](https://twitter.com/soffes) for advising on the SimpleAuth API design.\n\n### Contributors\n\n- [kornifex](https://github.com/kornifex): Foursquare provider\n- [mouhcine](https://github.com/mouhcine): Meetup provider\n- [iamabhiee](https://github.com/iamabhiee): LinkedIn provider\n- [aschuch](https://github.com/aschuch): Sina Weibo provider\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcalebd%2FSimpleAuth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcalebd%2FSimpleAuth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcalebd%2FSimpleAuth/lists"}