MedalliaMXO APIs

Automatic API

Get or set the current automatic Interaction tracking configuration using the following:

open class var automaticInteractionTrackingConfiguration: MXOAutomaticInteractionTrackingConfiguration?

To retrieve an automatic Interaction, use the function below:

open class func getAutomaticInteraction(for 
	viewController: UIViewController
) -> MXOInteraction?
PropertyTypeDescription
viewControllerUIViewControllerThe View Controller to get an automatic Interaction for.
Note: For more information, see how to disable/enable automatic Interaction tracking.

Automatic Interaction assignment API

Assign an automatic Interaction to a View to be used instead of using the automatic path using the following:

open class func assign(automaticInteraction 
	assignInteraction: MXOAutomaticInteractionAssignment
) throws
PropertyTypeDescription
assignInteractionMXOAutomaticInteractionAssignmentThe Interaction to assign to automatic tracking.
Note: For more information, see how to assign an Interaction.

Automatic Interaction exclusion API

Exclude a View from automatically being tracked as an Interaction using the following:

open class func exclude(automaticInteraction 
	excludeInteration: MXOAutomaticInteractionExclusion
) throws
ParameterTypeDescription
excludeInterationMXOAutomaticInteractionExclusionThe Interaction to exclude from tracking.
Note: For more information, see how to exclude an Interaction.

Automatic Interaction subscription API

Subscribe to automatic Interaction request responses using the following:

protocol MXOAutomaticInteractionSubscription

Use the convenience function to subscribe to automatic Interaction tracking:

open class func subscribe(toAutomaticInteraction 
	subscriber: MXOAutomaticInteractionSubscriber
) throws -> MXOAutomaticInteractionSubscription
ParameterTypeDescription
subscriberMXOAutomaticInteractionSubscriberThe subscriber for an Interaction.
Note: For more information, see examples on how to subscribe to an Interaction.

Configuration API

Get or set the MXO SDK configuration using the following:

open class var configuration: MXOConfiguration?
Note: For more information, see how to configure the SDK or get the current configuration.

Identity APIs

Retrieve the TID of the current user using the following:

open class func getTid() -> String?
Note: For more information, see how to get the current TID.

Clear the current user's TID from the SDK using the following:

open class func clearTid()

This feature enables the SDK to notify MXO when multiple user's may access the same app on the same device.

Note: For more information, see how to clear the current TID.

Identity Transfer API

Programmatic API to process a deep link to an app that has had the MXO Orchestration Plugin disabled or has had the identity transfer disabled therefore preventing the automatic sending of deep link parameters to MXO.

Get or set the MXO SDK identity transfer configuration using the following:

open class var identityTransferConfiguration: MXOIdentityTransferConfiguration?
Note: For more information, see how to disable/enable automatic identity transfer.

Process a URL deep link using the function below:

open class func process(deepLink 
	url: URL
) throws
ParameterTypeDescription
urlURLThe deep link URL to process.
Note: For more information, see how to process a deep link.

Generate a URL with a tid query parameter using the function below:

open class func generateIdentityTransferUrl(_ 
	url: URL
) throws -> URL
ParameterTypeDescription
urlURLThe URL to generate.
Note: For more information, see how to generate identity transfer links.

Interaction APIs

Send Interactions to MXO using the following:

open class func sendInteraction(
	request: MXOInteractionRequest
) throws
ParameterTypeDescription
requestMXOInteractionRequestThe Interaction request to be sent.
Note: For more information, see how to send Interactions.

Send Properties to MXO using the following:

open class func sendProperties(
	request: MXOInteractionRequest
) throws
ParameterTypeDescription
requestMXOInteractionRequestThe Interaction request to be sent.
Note: For more information, see how to send Properties.

Send response code to MXO using the following:

open class func sendInteraction(responseCodeRequest 
	request: MXOResponseCodeRequest
) throws
ParameterTypeDescription
requestMXOResponseCodeRequestThe response code to be sent.
Note: For more information, see how to send a response code.

Generate a URL for outbound link tracking using the function below:

open class func sendInteraction(forOutboundLink 
	link: URL
) throws
ParameterTypeDescription
linkURLThe URL for outbound link tracking.
Note: For more information, see how to send an outbound link or disable outbound link tracking.

Process the response returned from sending an Interaction using the following:

open class func process(
	response: MXOInteractionResponse
) throws
ParameterTypeDescription
responseMXOInteractionResponseThe Interaction response to process.
Note: For more information, see how to process an Interaction response.

Location API

Inform the MXO SDK about location details using the following:

open class func process(
	location: CLLocation
) throws
ParameterTypeDescription
locationCLLocationThe device location to send to MXO.
Note: For more information, see how to send a location object.

Logging API

Get or set the MXO SDK logging configuration using the following:

open class var loggingConfiguration: MXOLoggingConfiguration?
Note: For more information, see how to configure logging.

MXOErrorCode

An MXO SDK Runtime exception.

public struct MXOError : CustomNSError, Hashable, Error {
	public init(_nsError: NSError)
	public static var errorDomain: String { get }
	public enum Code : Int, @unchecked Sendable, Equatable {
		public typealias _ErrorType = MXOError
		case sdkError = 9000
		case apiError = 9001
		case invalidRequestError = 9002
		case invalidParamError = 9003
		case invalidSubscriberError = 9004
	}
	public static var sdkError: MXOError.Code { get }
	public static var apiError: MXOError.Code { get }
	public static var invalidRequestError: MXOError.Code { get }
	public static var invalidParamError: MXOError.Code { get }
	public static var invalidSubscriberError: MXOError.Code { get }
}
EnumDescription
sdkErrorUsed to specify that an SDK error was encountered.
apiErrorUsed to specify that an API error was encountered.
invalidRequestErrorUsed to specify that an invalid request error was encountered.
iInvalidParamErrorUsed to specify that an invalid param error was encountered.
subscriberErrorUsed to specify that an invalid subscriber error was encountered.
Note: For more information, see an example of using MXO error codes.

Opt Out API

Get or set the optout settings for compliance with a user's will to be tracked or not using the following:

open class var optOutConfiguration: MXOOptOutConfiguration?
Note: For more information, see how to opt out or into Interaction tracking.

Version API

Get the version of the MXO SDK using the following:
open class func getVersion() -> String
Note: For more information, see how to get the current SDK version.