gab.com api client.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
Example attachment object is enum Oct 16, 2018
GabKit add mensions Oct 18, 2018
.gitignore add ignore Oct 9, 2018
.travis.yml first init Oct 9, 2018
GabKit.podspec add mensions Oct 18, 2018
LICENSE first init Oct 9, 2018
README.md support attachment Oct 16, 2018
_Pods.xcodeproj first init Oct 9, 2018

README.md

GabKit

CI Status Version License Platform

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, noppelabs@gmail.com

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

  • supported attachment type

    • media
    • url