Manual

iOS Swift SDK

Integrate the Swift package, asynchronous operations, clip browser, protected keys, and AVPlayer.

Install

Add the RTKCloudClient Swift package at the approved release tag or use the internal source archive. Supported package platforms are iOS 13 or later and macOS 12 or later. Import RTKCloudClient in the target that owns the network-facing service layer.

Client usage

Create RTKCloudClient with the HTTPS base URL and required device context. Use throwing synchronous APIs only away from the main thread and prefer async overloads from Swift concurrency code. Catch RTKCloudError, preserve its stable status for diagnostics, and show user-safe messages.

Stored video browser

Create ClipQuery with bearer token, optional filters, limit, and skip. listClips returns a typed ClipPage; display its ClipSummary values and follow nextSkip. Load thumbnails away from the main actor. Do not trust a cached clip URL as a playback session.

Live WebRTC

The SDK supplies cloud authentication, ICE, offer/answer/close, stable errors, and signaling-session helpers. The product app connects that session data to its iOS WebRTC peer connection, tracks, renderer, audio-session policy, and UIKit or SwiftUI lifecycle. The SDK does not bundle a complete media renderer.

Encrypted playback

Implement PlaybackKeyProvider in code backed by Keychain and, where appropriate, Secure Enclave key operations. The provider receives the selected clip and current server key and returns wrapped clip key plus ephemeral public key. Give the PlaybackSession.playbackURL to a new AVPlayerItem. Request another session after expiry and replace the item when the selection changes.

PKI

Use platform certificate and identity storage. Keep private keys non-exportable where product requirements allow. Validate server trust normally; never add a production trust callback that accepts arbitrary certificates.

Validation

Run swift test and swift build for the package and sample. Run simulator build, installation, launch, and UI tests on a macOS host with an iOS Simulator SDK. Deployed-cloud validation supplies credentials to the simulator sandbox at runtime and must not compile them into the app.

Other manual chapters

Continue with related manual sections.

SDK overview

Choose the right package and understand support boundaries.

Open section

Getting started

Install an SDK, configure a client, and complete a first request.

Open section

Authentication and security

Handle bearer tokens, PKI, TLS, keys, and sensitive media safely.

Open section

Lifecycle and errors

Apply timeout, retry, cancellation, callback, and shutdown rules.

Open section

Capability workflows

Integrate provisioning, devices, telemetry, OTA, commands, and signaling.

Open section

Video Cloud workflows

Integrate Live WebRTC signaling and encrypted stored-video upload, browsing, and playback.

Open section

Native C and C++ SDK

Use the stable C ABI, thin C++ wrapper, transports, and streaming uploads.

Open section

Android Kotlin SDK

Use Kotlin APIs, coroutines, Media3 playback, and secure key providers.

Open section

JavaScript and TypeScript SDK

Integrate the typed ESM package in browser and Node.js applications.

Open section

Go SDK

Use the pure Go client for devices, tools, and automation.

Open section

FreeRTOS and Pro2 SDK

Integrate board adapters, device transport, and WebRTC answerer boundaries.

Open section

Sample applications

Build and use the Android, iOS, Web, Linux, and Pro2 reference samples.

Open section

Troubleshooting and compatibility

Diagnose common integration problems and identify deprecated behavior.

Open section