Swiftpack.co - Package - line/line-sdk-ios-swift

Build Status CocoaPods Compatible Carthage Compatible

LINE SDK for iOS Swift

Overview

Developed in Swift, the LINE SDK for iOS Swift provides a modern way of implementing LINE APIs. The features included in this SDK will help you develop an iOS app with engaging and personalized user experience.

Features

The LINE SDK for iOS Swift provides the following features.

User authentication

This feature allows users to log in to your service with their LINE accounts. With the help of the LINE SDK for iOS Swift, it has never been easier to integrate LINE Login into your app. Your users will automatically log in to your app without entering their LINE credentials if they are already logged in to LINE on their iOS devices. This offers a great way for users to get started with your app without having to go through a registration process.

Utilizing user data with OpenID support

Once the user authorizes, you can get the user’s LINE profile. You can utilize the user's information registered in LINE without building your user system.

The LINE SDK supports the OpenID Connect 1.0 specification. You can get ID tokens that contain the user’s LINE profile when you retrieve the access token.

Using the SDK

Prerequisites

  • iOS 10.0 or later as the deployment target.
  • Xcode 10 or later.

To use the LINE SDK with your iOS app, follow the steps below.

  • Create a channel.
  • Integrate LINE Login into your iOS app using the SDK.
  • Make API calls from your app using the SDK or from server-side through the Social API.

For more information, refer to the LINE SDK for iOS Swift guide on the LINE Developers site.

Trying the starter app

To have a quick look at the features of the LINE SDK, try our starter app by following the steps below:

  1. Clone the repository.

    git clone https://github.com/line/line-sdk-ios-swift.git

  2. Open the LineSDK.xcworkspace file in Xcode.

  3. Build and run the LineSDKSample scheme.

The starter app should launch.

Contributing

If you believe you have discovered a vulnerability or have an issue related to security, please DO NOT open a public issue. Instead, send us a mail to dl_oss_dev@linecorp.com.

For contributing to this project, please see CONTRIBUTING.md.

Github

link
Stars: 683

Dependencies

Used By

Total: 0

Releases

5.7.0 - 2020-09-16 07:47:23

Added

  • Xcode 12 support. The new Swift Package Manager support. Now the built-in UI of LINE SDK is also available when integrated with SPM. #161

5.6.2 - 2020-08-14 02:53:25

Fixed

  • Auto retry NSURLErrorNetworkConnectionLost error once when exchanging token. This is a workaround for a long-last iOS bug discussed here. #159

5.6.1 - 2020-08-05 05:46:41

Fixed

  • The completion handler for logging out was not called for HTTP status code 400. It now should be always called and not causing a hanging. #158

5.6.0 - 2020-06-11 05:24:35

Added

  • Open Chat support. You can create an Open Chat room with LINE SDK for Swift now. There are also some other public APIs to help checking room availability or user's memebership for a given Open Chat room. Check the official documentation and API Reference of OpenChatCreatingController for more information. #132

Fixed

  • Lots of improvement of reference and documentation comments.

5.5.2 - 2020-04-30 06:18:47

Fixed

  • Now explicitly log in with web view does not trigger the "LINE is not installed" warning on the login screen page.

5.5.1 - 2020-02-27 06:12:30

Fixed

  • Use standard parameter names from PKCE for OAuth 2.0 to replace the original One-Time-Password mechanism. #133
  • An issue that some symbols cannot be found in XCFramework binary for Objective-C wrapper. #140
  • Fix several dangling pointer warning for Xcode 11.4. #141
  • Improve security for state and nonce generating to use a better random generator from Security.framework. #137

5.5.0 - 2019-12-17 05:09:22

Added

  • Add the displayNameOverridden and displayNameOriginal properties to User when getting friends list. Currently the User.displayName is a combination of displayNameOverridden and displayNameOriginal. It is a preferred version of user's name for displaying and searching. #125
  • Support for xcframework. Now you can download binary format of LINE SDK and LINE SDK Objective-C wrapper as xcframework, as well as the related dSYMs and symbol map files from the release page. To implement this feature, we modified a bit for the exposed Objective-C wrapper module, to make sure the binary compatibility not broken in future releases. #126

Fixed

  • A missing localization for pt-BR when searching in sharing list panel. #127

5.4.0 - 2019-11-29 07:12:03

Added

  • Sharing UI support. Now you can request .oneTimeShare permission and present a ShareViewController to let users select messages and share these messages to their friends or groups. LINE SDK provides a pre-defined UI for sharing messages. You can also build your own UI based on public methods in the SDK. #79
  • Properties in Friend and Group to retrieve the "large" version and "small" version of a profile image. #30
  • A new relation sort option to get graph list sorted by relationship between current user and friends. #30
  • Support for macCatalyst as a build target. #123
  • Support for building against Swift Package Manager. Currently SPM does not support adding resource, so all UI related parts (such as LoginButton and ShareViewController) are eliminated from SPM build. #70
  • Replace LoginManagerOptions with LoginManager.Parameters for flexible parameter configuration while login. #119
  • Provide a way to set customized IDTokenNonce as the nonce value in ID Token. #119
  • Now message payload setting provides more public setter. You can create a customized message payload much easier. #90
  • APIErrorDetail is now public, so you can get the detail error information when a .invalidHTTPStatusAPIError error happens. #115
  • Dark mode is supported now for iOS 13 or later. Although all parts of LINE SDK is compatible with the dark mode, the login page and consent pages are not yet. They will be prepared eventually without a native SDK release. #105

Fixed

  • Now resource_bundles is used instead of resources when integrated by CocoaPods. #77

Deprecated

  • LoginManagerOptions and the related login method is deprecated. Use LoginManager.Parameters instead. #119
  • preferredWebPageLanguage is deprecated. Use the property with the same name in LoginManager.Parameters instead. #119
  • The general error type (Error) version of error handling delegate method in LoginButtonDelegate is deprecated. Use the specific LineSDKError version instead. #120
  • All token related APIs in API are now deprecated. They are moved to API.Auth to distinguish from the normal public APIs. Not like API, methods in API.Auth will not try to automatically refresh your access token. #118

5.3.1 - 2019-10-25 07:38:50

Fixed

  • Web page preference language for Japanese now works properly with correct language code. #113

5.3.0 - 2019-09-17 06:34:35

Added

  • Add IDTokenNonce to LoginResult. This value can be used against the ID token verification API as a parameter.

Fixed

  • Some improvements in documentation spelling and grammar.

5.2.4 - 2019-08-23 08:11:55

Fixed

  • Source application validation is removed. Login with LINE app now works correctly on iOS 13. #97

5.2.3 - 2019-08-01 01:51:31

Fixed

  • An issue that the stored ID Token will be overwritten when a refreshed token is issued. #88

5.2.2 - 2019-07-29 06:54:22

Fixed

  • When verifying token, get the provider metadata issuer from open ID discovery document, instead of a fixed value. #86

5.2.1 - 2019-07-19 06:16:10

Fixed

  • Align the behavior of LineSDKLoginButton (wrapper class) to LoginButton, when user click login, will only return if login process is ongoing. #78

5.2.0 - 2019-06-12 02:02:36

Added

  • Support for customizing the language used when login through web page. Set preferredWebPageLanguage of LoginManager to apply the required language. The default behavior (using the system language on user's device) is not changed. #61
  • Support for accessing AMR (Authentication Methods References) value in ID Token. #63
  • Now you can use either Swift 4.2 or Swift 5.0 when integrating LINE SDK with CocoaPods. #60

Fixed

  • The refreshToken in AccessToken is now marked as private. We do not encourage you to use or store the refresh token yourself. Instead, always use the refresh token API from client when you want to get a new access token.

5.1.2 - 2019-04-15 04:41:45

Fixed

  • Logging out a user now revokes refresh token and its corresponding access tokens, instead of the current access token only. #45

5.1.1 - 2019-03-28 05:21:48

Fixed

  • Allow additional application bundle ID of LINE apps to grant authorization code.

5.1.0 - 2019-02-26 04:05:59

Added

  • Some model types also support Encodable now for easier serialization.
  • Support JSON conversion for Objective-C model wrapper classes for future features.
  • Now you can get the raw ID Token value for server verification purpose.
  • Add compatibility for Swift 5.0 and Xcode 10.2.

5.0.3 - 2019-01-17 01:54:20

Fixed

  • Build LineSDKObjC with Carthage now works properly with all targets included. #13

5.0.2 - 2018-12-18 01:35:15

Fixed

  • A compiling crash when using Swift 5.0 tool chain to compile LINE SDK. #6, SR-9375, Swift #21296
  • An internal improvement on JWK handling.
  • Improvement on documentation spelling and grammar. #9

5.0.1 - 2018-11-29 06:34:51

Fixed

  • Improve ID Token signature verifying code to use latest Security framework API. #4
  • Hide an implementation detail in the sample app. #2

5.0.0 - 2018-11-20 06:18:49

Initial release of LINE SDK Swift. Now the LINE SDK is an open source project.

LINE SDK version 5 is not compatible with version 4.x. To upgrade to version 5, check the Migration Guide.

Added

  • Support LINE Login v2.1, which provide a fine-tuned authorization permissions and more safety authorizing flow. See LINE Login v2.1 for more about it.

    Warning: Tokens from LINE Login v2.0 will be invalidated and your users will be logged out once you upgrade your SDK integration from version 4.x or earlier.

  • ID Token with ECDSA verification based on OpenID protocol. It provides a secure way to verify user information.
  • You can use a predefined login button to let your users login now. The button follows LINE Login button design guideline. It provides a quick way to integrate LINE Login to your app. See LoginButton for more.

Fixed

  • A potential issue which causes authorizing from LINE app may fail on devices with iOS 12.
  • The automatically token refreshing should now work properly when receives a token expiring error from LINE Login Server.