talira

A server-side Swift HTTP web framework

open sourceMITfree

Vapor is a web framework for building HTTP servers, backends and APIs in Swift. It runs on Apple's SwiftNIO with a non-blocking, event-driven architecture and async/await, and covers routing, JSON, middleware, WebSockets and sessions. Its own packages add Fluent, an ORM that talks to Postgres, MySQL, SQLite and MongoDB in Swift without writing SQL; Leaf, a templating engine for HTML pages and emails; and JWT signing and verification built on Swift Crypto. It's installed with Swift Package Manager and runs on macOS and Linux.

Problems it solves

  • build a REST API backend in Swift
  • use the same language for my iOS app and its server
  • a server-side Swift web framework with an ORM and templates
  • run a Swift HTTP server on Linux
  • build a backend with async/await in Swift

Features

  • HTTP routing, middleware, JSON and WebSockets
  • built on SwiftNIO, non-blocking and event-driven
  • Fluent ORM for Postgres, MySQL, SQLite and MongoDB
  • Leaf templating for HTML and email
  • JWT signing and verification
  • runs on macOS and Linux