PWCore 3.13.0

PWCore 3.13.0

TestsTested
LangLanguage Obj-CObjective C
License Unknown
ReleasedLast Release Jul 2024

Maintained by Troy Stump, Jenkins Phunware, Kent Tu, Aaron Pendley, Seshu, Matt Hendrickson.



PWCore 3.13.0

PWCore SDK for iOS

Version License Platforms Twitter

This is Phunware's Core SDK for use with its Multiscreen-as-a-Service platform. Visit http://maas.phunware.com for more details and to sign up.

NOTE: This is a required dependency for all Phunware SDKs.

Requirements

  • iOS 13.0 or greater
  • Xcode 12 or greater

Installation

CocoaPods

It is required to use CocoaPods 1.10 or greater to integrate the framework. Simply add the following to your Podfile:

pod 'PWCore'

To enable support for requesting authorization to access the identifier for advertisers (IDFA), add the DeviceIdentity subspec:

pod 'PWCore/DeviceIdentity'

Documentation

Documentation is included in the Documents folder in the repository as both HTML and as a .docset. You can also find the latest documentation here: http://phunware.github.io/maas-core-ios-sdk

Integration

Import PWCore at the top of your application's delegate:

import PWCore

Initialize PWCore in your application delegate's application(_:didFinishLaunchingWithOptions:) method:

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]? = nil) -> Bool {
    // These values can be found for your application in the MaaS portal at http://maas.phunware.com/clients.    
    PWCore.setApplicationID("APPLICATION_ID",
                            accessKey: "ACCESS_KEY",
                            signatureKey: "SIGNATURE_KEY")

    ...
}

Location Permissions

Location authorization of "When In Use" or "Always" is encouraged when starting PWCore for analytics purposes. Please follow Apple's Best Practices for requesting location permissions.

Identifier for Advertisers (IDFA) Permission

Starting with iOS 14.5, accessing the identifier for advertisers (IDFA) requires authorization through Apple's AppTrackingTransparency framework. Authorization is encouraged when starting PWCore, and can be requested directly through the SDK:

switch PWCore.isAdvertisingIdentifierPermissionRequestable {
case .allowed:
    PWCore.requestAdvertisingIdentifierPermission { (advertisingIdentifier) in
        // Advertising identifier available
        print("Advertising Identifier: \(advertisingIdentifier)")
    } failure: { (error) in
        // Advertising identifier not available
        print(error)
    }
case .notAllowed:
    // Authorization is either restricted or has been previously denied
    print("Advertising identifier cannot be requested.")
case .alreadyAuthorized:
    // Advertising identifier is already available
    print("Advertising Identifier: \(PWCore.deviceID())")
}

Attribution

PWCore uses the following third-party dependencies:

Component Description License
AFNetworking A delightful iOS and OS X networking framework. MIT
TMCache Fast parallel object cache for iOS and OS X. Apache 2.0
SSZipArchive Zipping and unzipping files for iOS and OS X. MIT

Privacy

You understand and consent to Phunware’s Privacy Policy located at www.phunware.com/privacy. If your use of Phunware’s software requires a Privacy Policy of your own, you also agree to include the terms of Phunware’s Privacy Policy in your Privacy Policy to your end users.

Terms

Use of this software requires review and acceptance of our terms and conditions for developer use located at http://www.phunware.com/terms