[ID-1150] prep for rust bindings#31
Merged
thereisnogabe merged 9 commits intoNov 19, 2025
Merged
Conversation
thereisnogabe
commented
Nov 6, 2025
Contributor
- dependent on feat: add initial Swift bindings idkit#5
This commit adds backwards-compatible convenience methods and updates the generated UniFFI bindings to match the latest Rust core implementation. ## New Swift Convenience Wrappers ### Request+Convenience.swift Backwards-compatible initializers that mirror IDKit v2 API: - `init(credentialType:signal:faceAuth:)` - Accepts string signals - `init(credentialType:abiEncodedSignal:faceAuth:)` - Accepts ABI-encoded Data - `Signal.data` - Computed property exposing raw bytes as Data - `Signal.string` - Computed property exposing string form ### Session+Compatibility.swift Async/await helpers and convenience accessors: - `status(pollInterval:)` - AsyncThrowingStream for status updates - `statusStream(pollInterval:)` - Backwards-compatible alias - `verificationURL` - Computed property returning URL instead of String - `requestUUID` - Computed property returning UUID instead of String - `SessionError` - Swift-friendly error enum ## Updated Generated Bindings ### Session method renamed - `poll()` → `pollForStatus()` - Matches Rust implementation - Updated documentation to clarify non-blocking polling behavior - Updated FFI function names and checksums ### Headers updated - Updated `idkitFFI.h` with latest function signatures ## Migration Notes These changes maintain v2 API compatibility while exposing the v3 Rust core: - Existing code using v2 API continues to work - New code can use either v2 convenience methods or v3 core APIs - Generated types (Status, Proof, Constraints, etc.) remain unchanged 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
The Package.swift requires valid HTTPS URLs for binary targets. This commit adds a placeholder URL that will be replaced by the publish-swift.yml workflow when the first release is created. Note: CI will fail to download this placeholder URL, but that's expected until the first official release is published from the idkit repository. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Syncs generated Swift bindings and convenience extensions from main idkit repo after upgrading to UniFFI 0.30. Key changes: - Updated all generated Swift files (idkit.swift, idkit_core.swift) - Updated C headers and modulemaps - Fixed Request+Convenience.swift to use unsafeFromHandle (UniFFI 0.30 API) - API change: unsafeFromRawPointer() → unsafeFromHandle() - API change: uniffiClonePointer() → uniffiCloneHandle() Generated from idkit commit: 1290765
SeanROlszewski
approved these changes
Nov 19, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.