Skip to content

Repository files navigation

APIClientKit

Cross-platform Swift 6 HTTP client primitives (Endpoint, middleware, typed errors) plus an optional URLSession adapter product.

Swift Platforms

Products

  • APIClientKit — core seams (APIClientProtocol, Endpoint, middleware, InMemoryAPIClient). Uses FoundationEssentials when available.
  • APIClientKitURLSessionURLSessionAPIClient adapter. Depends on FoundationNetworking on Linux.

Documentation

  • DocC catalogs ship in-tree under each target’s *.docc bundle.
  • Swift Package Index hosts generated docs once the package is indexed (see .spi.yml).
  • Agent-oriented pointers: AGENTS.md.
  • CI: .github/workflows/ci.yml runs swift test on Swift 6.3+ (Linux, Windows, macOS, Android SDK build).
swift package generate-documentation --target APIClientKit
swift package generate-documentation --target APIClientKitURLSession

Quick start

import APIClientKit
import APIClientKitURLSession

struct Health: Endpoint {
    let path = "/health"
    let method = Method.get
    let task = EndpointTask.plain
}

let client = URLSessionAPIClient(baseURL: URL(string: "https://example.com")!)
let data = try await Health().execute(client: client)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages