diff --git a/README.md b/README.md index d2e9d75..8ef1f17 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,9 @@ For automation, `-ipx.server ` as a launch argument overrides the stored va | `ios/Sources/WebViewController.swift` | the `WKWebView`, and the banner when something is wrong | | `ios/Sources/Bridge.swift` | the messages, both directions | | `ios/Sources/Playback.swift` | `AVPlayer`, the audio session, now-playing, the remote commands | -| `ios/Sources/Library.swift` | the API calls the host makes: position, read, artwork | +| `ios/Sources/API.swift` | ipx's HTTP API, typed | +| `ios/Sources/APIModels.swift` | what ipx sends: feeds, entries, enclosures | +| `ios/Sources/Events.swift` | the `/api/events` stream, and reconnecting to it | | `ios/Sources/CookieBridge.swift` | `WKHTTPCookieStore` into `HTTPCookieStorage.shared` | | `ios/Sources/ServerSettings.swift` | which server | diff --git a/ios/Sources/API.swift b/ios/Sources/API.swift new file mode 100644 index 0000000..bfdf13a --- /dev/null +++ b/ios/Sources/API.swift @@ -0,0 +1,168 @@ +import Foundation +import UIKit + +/// ipx's HTTP API. +/// +/// It sends nothing of its own to authenticate: ipx decides who is asking by cookie, and +/// CookieBridge keeps HTTPCookieStorage in step with the web view's store. That is deliberate -- +/// the auth layer was written so a plain `