Contents

patrick-zippenfenig/curl-swift

An opinionated `libcurl` wrapper for Swift

⌨️ Usage

There are 2 ways to use this library which kinda represents libcurl-easy and libcurl-share

CURL.swift

Each request runs in total isolation.

let req = CURL(
    method: "GET",
    url:
        "https://httpbin.org/get"
)
let res = try req.perform()

CURLSH.swift

Allow multiple requests to share cookies, dns cache, ssl session, and other goodies.

let share = CURLSH()
let res = try share.perform(curl: req) 

🏛 Design choices

  • The url string passed in will not be escaped, handle it at the call-site.

Package Metadata

Repository: patrick-zippenfenig/curl-swift

Default branch: main

README: README.md