I'm currently experimenting with the latest Xcode beta 15.3 (15E5194e) and attempting to integrate FinanceKit into my project. However, I've encountered a persistent issue where the app crashes upon attempting to read or request authorization, accompanied by the following error message:
FinanceKit/FinanceStore+FinancialDataAuthorization.swift:52: Fatal error: Process is not entitled
Upon investigation, I've found no evident entitlements for FinanceKit, despite exploring options like Apple Wallet. Furthermore, I thoroughly examined the info.plist for relevant privacy values but found nothing pertinent.
Here's the code snippet that triggers the fatal error, whether it's the request or read function:
import FinanceKit
import UIKit
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
requestFinancePermission()
// readFinancePermission()
}
private func requestFinancePermission() {
Task {
do {
let status = try await FinanceStore.shared.requestAuthorization()
} catch {
print("Error: \(error)")
}
}
}
private func readFinancePermission() {
Task {
do {
let status = try await FinanceStore.shared.authorizationStatus()
} catch {
print("Error: \(error)")
}
}
}
}
Even though the API is available on Xcode 15.3b, the capabilities are not yet turned on for everyone. I believe you will have to go to your app configuration in the developer portal under capabilities & app services.