Skip to content

antarianLogic/interchange

Repository files navigation

Interchange

Swift Platforms License SPM Compatible

A lightweight Swift package for interacting concurrently with RESTful web APIs using declarative endpoint specifications and returning decoded Codable types, with support for pagination, rate limiting, and more


Features

  • 🪶 Lightweight: Relativly simple implementation with no main target dependencies
  • 🚸 Swift Concurrency: Uses async/await and actors for thread-safe operations
  • 📋 Declarative: The configuration specific to each call is passed as declaratively as value types
  • 🦺 Type-Safe: Leverages Swift's Codable for automatic JSON parsing
  • 📑 Pagination Support: Stream multi-page responses with AsyncThrowingStream
  • 🚦 Automatic Rate Limiting: Respects API rate limits based on response headers
  • 💾 Caching: Built-in URLCache support with configurable intervals
  • 🧪 Testable: Protocol-based design for easy mocking

Requirements

  • iOS 15.0+ / macOS 12.0+
  • Swift 6.0+
  • Xcode 14.0+

Quick Start

To jump right in, see the Quick Start Guide.

Full Documentation

The full documentation is here: Interchange.

Example Projects

Contributing

Contributions are welcome! Please read CONTRIBUTING.md for details on our code of conduct and the process for submitting pull requests.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Author

Carl Sheppard - Antarian Logic LLC

Acknowledgments

Support

About

A lightweight Swift package for interacting with RESTful web APIs

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages