GabKit
Example
To run the example project, clone the repo, and run pod install
from the Example directory first.
Requirements
Installation
GabKit is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'GabKit'
Usage
Authorize
let gab = Gab(clientID: Secret.clientID,
clientSecret: Secret.clientSecret,
scopes: .read, .notifications, .writePost)
gab.authorize(withPresentingFrom: self)
Add your callback url as url scheme to info.plist.
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLSchemes</key>
<array>
<string>gabkit</string>
</array>
</dict>
</array>
Handle URL in AppDelegate.
func application(_ app: UIApplication, open url: URL, options: [UIApplicationOpenURLOptionsKey : Any] = [:]) -> Bool {
Gab.handleURL(url)
return true
}
Get Main feed
gab.getMainFeed(success: { (response) in
})
Create Post
gab.createPost(body: "hello gab.")
Author
noppefoxwolf, [email protected]
License
GabKit is available under the MIT license. See the LICENSE file for more info.
TODO
-
authorize
-
create post
-
convenience upload image and publish post
-
engaging with other users
-
feeds
-
group
-
notificaitons
-
popular
-
reacting to posts
-
request
-
user details
-
support ios
-
support osx
-
support linux
-
support cocoapods
-
support carthage
-
support swift package manager
-
codable
-
supported attachment type
- media
- media array
- url
- giphy
- youtube
-
undocumented api