8000 GitHub - daprice/SwiftyJoinMastodonAPI: Swift client library for the api.joinmastodon.org server listing
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

daprice/SwiftyJoinMastodonAPI

Repository files navigation

SwiftyJoinMastodonAPI

An easy way to work with the joinmastodon.org server listing API in Swift.

import SwiftyJoinMastodonAPI

// Get all servers
async let servers = JoinMastodonAPI.default.perform(.getServers)

// Get servers filtered by language, category, region, ownership type, or open registrations
async let filteredServers = JoinMastodonAPI.default.perform(.getServers(filterParameters: .init(
	language: "en",
	category: "general",
	region: .europe,
	registrations: .instant
)))

// Use a custom URLSession
let customURLSessionAPIClient = JoinMastodonAPI(urlSession: .init(configuration: .ephemeral))
async let stats = customURLSessionAPIClient.perform(.getStatistics)

About

Swift client library for the api.joinmastodon.org server listing

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

0