Platforms to show: All Mac Windows Linux Cross-Platform

Back to AppReceiptVerificatorMBS class.

AppReceiptVerificatorMBS.Constructor

Type Topic Plugin Version macOS Windows Linux iOS Targets
method StoreKit MBS MacCloud Plugin 14.3 ✅ Yes ❌ No ❌ No ✅ Yes All
The constructor.

AppReceiptVerificatorMBS.verifyAppReceipt as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method StoreKit MBS MacCloud Plugin 14.3 ✅ Yes ❌ No ❌ No ✅ Yes All
Verifies the app's receipt file.
Example
dim a as new AppReceiptVerificatorMBS

if a.verifyAppReceipt then
MsgBox "My receipt is valid"
else
MsgBox "My receipt is invalid."
end if

Verifies the receipt by checking the integrity of the receipt, comparing its bundle identifier and bundle version to the values returned by the corresponding properties and verifying the receipt hash.

Returns true if the receipt is verified, false otherwise.
If validation fails, Apple recommends to refresh the receipt and try again.

If you set bundleVersion and/or bundleIdentifier properties, we use those values.
Else we pick them from the info.plist of the app.

AppReceiptVerificatorMBS.verifyReceipt(Receipt as AppReceiptMBS) as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
method StoreKit MBS MacCloud Plugin 14.3 ✅ Yes ❌ No ❌ No ✅ Yes All
Verifies the given receipt file.
Example
dim a as new AppReceiptVerificatorMBS
dim f as FolderItem = SpecialFolder.Desktop.Child("receipt")
dim r as AppReceiptMBS = AppReceiptMBS.receiptForFile(f)

// testing with receipt from current Dash app
a.bundleIdentifier = "com.kapeli.dash"
a.bundleVersion = "2.1.2"

if a.verifyReceipt(r) then
MsgBox "My receipt is valid"
else
MsgBox "My receipt is invalid."
end if

Verifies the receipt by checking the integrity of the receipt, comparing its bundle identifier and bundle version to the values returned by the corresponding properties and verifying the receipt hash.

Returns true if the receipt is verified, false otherwise.
If validation fails, Apple recommends to refresh the receipt and try again.

Some examples using this method:

The items on this page are in the following plugins: MBS MacCloud Plugin.


The biggest plugin in space...