Swiftpack.co -  twilio/twilio-chat-ios as Swift Package
Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
twilio/twilio-chat-ios
SPM releases
.package(url: "https://github.com/twilio/twilio-chat-ios.git", from: "v5.0.0")

Twilio Programmable Chat for iOS

This repository contains releases for the Twilio Programmable Chat for iOS SDK. These releases can be consumed using Swift Package Manager, CocoaPods or manual integration into your project.

Swift Package Manager

You can add Programmable Chat Client for iOS by adding the https://github.com/twilio/twilio-chat-ios repository as a Swift Package.

In your Build Settings, you will also need to modify Other Linker Flags to include -ObjC.

As of the latest release of Xcode (currently 12.3), there is a known issue with consuming binary frameworks distributed via Swift Package Manager. The current workaround to this issue is to add a Run Script Phase to the Build Phases of your Xcode project. This Run Script Phase should come after the Embed Frameworks build phase. This new Run Script Phase should contain the following code:

find "${CODESIGNING_FOLDER_PATH}" -name '*.framework' -print0 | while read -d $'\0' framework
do
    codesign --force --deep --sign "${EXPANDED_CODE_SIGN_IDENTITY}" --preserve-metadata=identifier,entitlements --timestamp=none "${framework}"
done

CocoaPods Integration

We support integration using CocoaPods as well. You can add Twilio Programmable Chat Client to your project using the following example Podfile:

source 'https://github.com/CocoaPods/Specs'

platform :ios, '11.0'

target 'TARGET_NAME' do
    pod 'TwilioChatClient', '~> 4.2'
end

Then run pod install to install the dependencies for your project.

Manual Integration

TwilioChatClient.xcframework is distributed as a dynamic iOS framework that you can drag and drop into your existing projects.

Once you've downloaded and unpacked the XCFramework, navigate to your Xcode project's General settings page. Drag and drop TwilioChatClient.xcframework onto the Frameworks, Libraries, and Embedded Content section. Ensure that "Copy items if needed" is checked and press Finish. Ensure that "Embed & Sign" is selected.

In your Build Settings, you will also need to modify Other Linker Flags to include -ObjC.

Carthage Integration

Carthage is not currently a supported distribution mechanism for Twilio Chat Client. Carthage does not currently work with .xcframeworks as documented here. Once Carthage supports binary .xcframeworks, Carthage distribution will be re-added.

Issues and Support

Please file any issues you find here on Github.

Please ensure that you are not sharing any Personally Identifiable Information(PII) or sensitive account information (API keys, credentials, etc.) when reporting an issue.

For general inquiries related to the Chat SDK you can file a support ticket.

License

Twilio Programmable Chat for iOS is distributed under TWILIO-TOS.

GitHub

link
Stars: 7
Last commit: 10 weeks ago

Ad: Job Offers

iOS Software Engineer @ Perry Street Software
Perry Street Software is Jack’d and SCRUFF. We are two of the world’s largest gay, bi, trans and queer social dating apps on iOS and Android. Our brands reach more than 20 million members worldwide so members can connect, meet and express themselves on a platform that prioritizes privacy and security. We invest heavily into SwiftUI and using Swift Packages to modularize the codebase.

Related Packages

Release Notes

Twilio Programmable Chat Client iOS 5.0.0
10 weeks ago

Breaking changes

  • Major internals improvement (the "Sessionless" protocol) This improvement has some core effects:
    • SDK commands will return success or failure up to ~10% more quickly than before.
    • Real-time updates of data is now likely to arrive after the command completes. For example, [TCHChannel setAttributes] will invoke completion (i.e. success) while [TCHChannel attributes] still returns old value. To see the new value, we recommend waiting for an update event, e.g. in chatClient:channel:updated:TCHChannelUpdateAttributes delegate.
  • Channel list page size increased from 50 to 100. Please make sure your code respects any returned page size, rather than assuming 50 (or 100).
  • Some error messages have changed:
    • Declining an invite whilst already joined will return an error 50601, Invite not found instead of 50602, Cannot decline invite when already channel member.
    • Trying to leave a channel you're not part of will return error 50402, Member not found instead of 50400, User not member of channel.

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API