Swiftpack.co - zunda-pixel/Sweet as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by zunda-pixel.
zunda-pixel/Sweet 2.3.11
Twitter API v2 Swift Library
⭐️ 7
🕓 36 weeks ago
iOS macOS watchOS tvOS macCatalyst
.package(url: "https://github.com/zunda-pixel/Sweet.git", from: "2.3.11")

Sweet

Twitter API v2 for Swift

Support Swift 5.7

Support Platform for iOS macOS watchOS tvOS Linux Windows

Getting Started

Add the following dependency clause to your Package.swift:

dependencies: [
  .package(url: "https://github.com/zunda-pixel/Sweet", .upToNextMajor(from: "2.3.10")),
],
.target(
  name: "PenguinKit",
  dependencies: [
    .product(name: "Sweet", package: "Sweet"),
  ]
)

Usage

let sweet = Sweet(token: .oAuth2user(token: "token"), config: .default)
let response = try await sweet.me()
print(response.user)

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics