Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error while requesting a transaction

Tags:

ios

swift

callkit

When I requesting a CXTansaction in CXStratCallAction it showing the error message as "Error Domain=com.apple.CallKit.error.requesttransaction Code=1 "(null)" ". Can anyone explain this Error message.

like image 650
sathish Avatar asked Dec 06 '17 11:12

sathish


1 Answers

From the header <CallKit/CXError.h>:

typedef NS_ERROR_ENUM(CXErrorDomainRequestTransaction, CXErrorCodeRequestTransactionError) {
    ...
    CXErrorCodeRequestTransactionErrorUnentitled = 1,
    ...
} API_AVAILABLE(ios(10.0));

So error code 1 corresponds to CXErrorCodeRequestTransactionErrorUnentitled.

This error is usually returned when an app lacks the voip iOS App Background Mode. To fix this, open Xcode's Capabilities tab for the app target and enable the "VoIP" background mode, or add 'voip' to the UIBackgroundModes array within the app's Info.plist.

(I have filed a request in Apple's bug tracker to mention this in the documentation, Radar 35903988.)

like image 160
Stuart M Avatar answered Sep 29 '22 18:09

Stuart M