Introducing Hosted Content for Unibill


One plugin, seven platforms


    1. Introduction

      1. Overview
      2. How it works
      3. How to use this document
    2. Cross platform guide

      1. Overview
      2. How it works
      3. Defining your in App purchases
      4. Updating Inventory at Runtime
      5. Virtual currencies
        1. Defining your virtual currencies
        2. Checking currency balance
        3. Spending currency
        4. Gifting currency
      6. Calling Unibill methods
      7. Initialising Unibill
      8. Checking for Unibill errors
      9. Receiving messages from Unibill
      10. Browsing available purchases
      11. Initiating purchases
      12. Retrieving transaction history
      13. Overriding identifiers
      14. Clearing transaction history
      15. Accessing purchase receipts
      16. The Unibill demo scene
    3. Google Play

      1. Configure your Google Play public key
      2. Uploading your purchase metadata to Google Play
      3. Testing on an Android device
    4. Amazon Appstore

      1. Entering your purchase metadata in the Amazon portal
      2. Testing using the Amazon test client
    5. Apple App Store

      1. Configuring your iOS SKU
      2. Price tiers
      3. Using the screenshot taker
      4. Uploading your purchase metadata using the Application loader
      5. Note for Unity iOS standard users
      6. Testing on device
    6. Mac App Store

      1. Intro
      2. Testing In App Purchasing
    7. Windows Phone 8

      1. Intro
      2. Testing In App Purchasing
    8. Windows 8

      1. Testing
    9. Samsung Apps

      1. Setup
      1. Testing
    10. Getting Support



Unibill is a one stop solution for in App purchasing in Unity3D; a single plugin that works across the Apple App store, Mac App Store, Google Play, Amazon App store, Samsung Apps Store, Windows Phone 8 and Windows 8.1!

What’s more, Unibill now offers cross platform downloadable content via Unibill Hosted Content; we take care of hosting your content, verifying your customer’s purchase receipts and delivering the content. It’s fully integrated with Unibill and works seamlessly across platforms and even the Editor, just like Unibill does.

Unibill also features automatic virtual currencies; just tell Unibill what your currencies are called and how much users get when purchasing which consumable In App Purchases.

As a demonstration of how simple it is, the following code snippet initialises Unibill and makes a purchase, and works across all seven platforms

Unibiller.onBillerReady += (state) => {
    if (UnibillState.SUCCESS == state) {


What’s more, Unibill is brimming with features to get you up and running in record time, including tools to help you bulk upload your metadata to Apple and Google, and automatic integration with Amazon’s SDK tester and Microsoft’s mock IAP framework on both Windows Phone and Windows Desktop.

How it works

Instead of using the raw billing interfaces of Apple, Google, Amazon and Microsoft, your application uses the more abstract Unibill interface. Unibill is responsible for communicating with the underlying billing system on each platform, so your code remains simple and clean.

Unibill does a huge amount of work for you, such as verifying your product data with Apple and Amazon when your application launches, and maintaining a database of what a user has purchased.

Unibill automatically integrates with your project, generating and merging your AndroidManifest and XCode projects as required. Changing between Google Play and Amazon billing is as simple as changing a drop down; Unibill handles everything else for you!

How to use this document

Start with the Cross platform guide, which is applicable to all billing platforms, then work through each platform specific section for each platform you are targeting.

Cross platform guide

Defining your in App purchases

Once you’ve installed the Unibill unity package, the first step is to tell Unibill what purchasable items your application has; the coins, potions, planets or subscriptions that you will be selling to your users.

You define your purchases using the Inventory Editor, a Unity editor window which you can find in the ‘Window/Unibill’ toolbar menu. The inventory editor tracks these purchasable items in an JSON file located at Assets/Plugins/unibill/resources/unibillInventory.json.txt, which you can edit manually (or with your own tools) if you prefer.

Screen Shot 2013-01-06 at 17.01.18

Configuration settings

These are global Unibill settings, specific to the underlying billing platforms. See the platform specific sections for details of how to fill these in.

Purchasable items

This is where you define your in app purchases. Click the ‘+’ button to define a new in app purchase, and enter the following fields:

Purchase type

“Consumable” Can be purchased repeatedly. Suitable for consumable items such as virtual currencies.
“Non-Consumable” Can only be purchased once. Suitable for one off purchases such as extra levels.
“Subscription” Has a finite window of validity once purchased


This uniquely identifies each In App Purchase. This should be in the format of a bundle identifier; eg com.companyname.appname.purchasename.
This must be unique across all your purchasable items.


The name of the purchasable item, as you display it to users.


A description of the purchasable item, as you display it to users.

Virtual currencies

Unibill features built in support for virtual currencies; Unibill will track the player’s balance, incrementing it when they buy more and providing methods to check, credit and debit their balance.

1. Defining your currencies

Virtual currencies are defined in the inventory editor.  Just tell Unibill what your currency is called, and then set up a series of ‘mappings’ to the consumable in app purchases you have defined.

You don’t need to worry about subscribing to events or incrementing balances when purchases are made, Unibill will do it for you.

In the example screenshot, our “gold” can be bought in two different increments of 100 and 250.

Screen Shot 2013-10-14 at 20.22.44

2. Checking currency balance

decimal balance = Unibiller.GetCurrencyBalance("gold");

3.  Spending currency

if (Unibiller.DebitBalance("gold", 100)) {
 // Spend was successful
} else {
 // Not enough cash!

4. Gifting currency

Unibiller.CreditBalance("gold", 100);

Updating Inventory at Runtime

To avoid having to update your app every time you change your inventory of products, Unibill can fetch an updated configuration file from a URL of your specification, and use it the next time your application boots.

Unibill stores your configuration in a JSON file at Assets/Plugins/unibill/resources/UnibillInventory.json.txt.

Simply check the ‘use hosted config’ box and enter the URL where you will be publishing your inventory.

Screen Shot 2014-08-15 at 08.38.13

Calling Unibill methods

The entire Unibill API is a series of static methods in the Unibiller class; any methods you see referred to hereonin are to be found in the Unibiller class, which you can browse at Assets/Plugins/unibill/src/impl/Unibiller.cs.

See the next section, Initialising Unibill, for some sample code demonstrating the use of static functions.

There are no prefabs or management MonoBehaviours to worry about.

Initialising Unibill

You should initialise Unibill as soon as possible, ideally in the first scene that Unity loads.

To initialise Unibill you must subscribe to Unibill’s onBillerReady event, then call Unibiller.Initialise():

Note that is is essential that you subscribe to Unibill’s onBillerReady method *before* calling initialise, to avoid a race condition.

class ExampleMonoBehaviourThatInitialisesUnibill : Monobehaviour {

    public void Start() {
        Unibiller.onBillerReady += onInitialised;

    private void onInitialised(UnibillState result) {

When Unibill has finished initialising, the Unibiller.onBillerReady event will be fired, which in this case will result in onInitialised() being called.

The UnibillState parameter has three possible results:

SUCCESS Unibill encountered no problems and is ready to make purchases.
SUCCESS_WITH_ERRORS Unibill encountered one or more non critical errors and is ready to make purchases. Details of these errors will have been printed to the console, or you can retrieve the errors manually.
CRITICAL_ERROR Unibill was unable to initialise. Details of the error will have been printed to the console, or you can retrieve them manually. You should not attempt to make any purchases.

Checking for Unibill errors

*Unibill will always print diagnostic information to the device console*

When Unibill encounters an error it will automatically print a brief help message and a URL to the console; if you visit the URL in a browser you can find full documentation for the specific error. You can view the console output of a device using adb on android and xcode on iOS.

You can also retrieve these errors manually from Unibill if you so choose, by checking the Unibiller.Errors property which returns an array of the UnibillError enumeration. Full documentation for each error is available at http://www.outlinegames.com/unibill/errors#%5Berror name]

Receiving messages from Unibill

Unibill provides a strongly typed interface for informing your application of billing events, which works identically across all billing platforms.

The API is asynchronous; your application receives messages from Unibill by subscribing to events, which may fire at any time. The Unibiller class exposes the following static events that you may subscribe to:

/// Occurs after a call to Unibiller.Initialise.
/// UnibillState.SUCCESS Unibill initialised successfully.
/// UnibillState.SUCCESS_WITH_ERRORS Unibill initialised successfully but with one
/// or more non critical errors. Check the console logs or Unibiller.Errors.
/// UnibillState.CRITICAL_ERROR Unibill encountered a critical error and cannot make
/// purchases. Check the console logs or Unibiller.Errors.
public static event Action onBillerReady;

/// Occurs when the user chose to cancel the specified purchase rather than buy it.
public static event Action onPurchaseCancelled;

/// Occurs when the specified item was purchases successfully.
public static event Action onPurchaseComplete;

/// Occurs when the specified purchase failed.
public static event Action onPurchaseFailed;

/// Occurs when the specified purchase was refunded.
/// Unibill will automatically update the transaction database for the PurchasableItem by
/// decrementing the purchase count.
public static event Action onPurchaseRefunded;

/// Occurs when a call to Unibiller.restoreTransactions completed.
/// The parameter indicates whether the restoration was successful.
public static event Action onTransactionsRestored;

Browsing available purchases

Once Unibill has initialised successfully, you can retrieve details of the In App Purchases that you have defined using the Inventory Editor.

Unibill features the ‘PurchasableItem’ class to represent your purchasable items:

/// Represents an item that may be purchased as an In App Purchase.
public class PurchasableItem : IEquatable {
    /// A platform independent unique identifier for this PurchasableItem.
    public string Id;

    /// The PurchaseType of this PurchasableItem; Consumable, Non-Consumable or Subscription.
    public PurchaseType PurchaseType;

    /// The following fields are retrieved from the underlying billing system,
    /// eg iTunes connect, the Google play Publisher interface, etc.
    /// NOTE: Since these fields are retrieved from the Apple, Google etc,
    /// they will be blank when running in Editor mode.

    /// The precise formatting of this string varies across platforms.
    /// On Google Play, formatting includes the currency symbol.
    /// On other platforms, this is simply a decimal number.
    /// The localized price string.
    public string localizedPriceString { get; private set; }

/// Gets the localized product title.
    public string localizedTitle { get; private set; }

/// Gets the localized product description.
    public string localizedDescription { get; private set; }


The following properties return your PurchasableItems by PurchasableType(Consumable, Non-Consumable, Subscription) or you can retrieve a PurchasableItem directly if you know its identifier.

/// Get all PurchasableItem that can be purchased including Consumable,
/// Non-Consumable and Subscriptions.
public static PurchasableItem[] AllPurchasableItems;

/// Get all PurchasableItem of type Non-Consumable.
public static PurchasableItem[] AllNonConsumablePurchasableItems;

/// Get all PurchasableItem of type Consumable.
public static PurchasableItem[] AllConsumablePurchasableItems;

/// Get all PurchasableItem of type Subscription.
public static PurchasableItem[] AllSubscriptions;

/// Get the specified PurchasableItem by its Unibill identifier,
/// eg "com.companyname.100goldcoins".
/// Unibill identifiers must be globally unique and can refer to Consumable,
/// Non-Consumable and Subscription purchasable items.
public static PurchasableItem GetPurchasableItemById(string unibillPurchasableId);

Initiating purchases

The following methods may be used to initiate a purchase:

/// Initiate purchasing of the specified PurchasableItem.
public static void initiatePurchase (PurchasableItem purchasable);

/// Initiate purchasing of the PurchasableItem with specified Id.
public static void initiatePurchase (string purchasableId);

Retrieving transaction history

Unibill maintains its own local database of which items a user has purchased. You may query it to find out whether a user has purchased a Non-Consumable item, or how many times a user has purchased a Consumable item.

/// Get the number of times this PurchasableItem has been purchased.
/// Returns 0 for unpurchased items, a maximum of 1 for Non-Consumable items.
public static int GetPurchaseCount (PurchasableItem item) {
    if (null != biller) {
        return biller.getPurchaseHistory(item);
    return 0;

/// Get the number of times the PurchasableItem with specified Id has been purchased.
/// Returns 0 for unpurchased items, a maximum of 1 for Non-Consumable items.
public static int GetPurchaseCount (string purchasableId) {
    if (null != biller) {
        return biller.getPurchaseHistory(purchasableId);
    return 0;

Overriding identifiers

Google, Amazon and Apple do not allow in App purchase identifiers to be changed or reused, which is a problem if you make a mistake submitting your in app purchase metadata.

Take, for example, some gold coins which you might define with an Id of “com.companyname.100goldcoins”. If you were to define these with a ‘Non-Consumable’ type in iTunes connect you cannot later change it to ‘Consumable’. “com.companyname.100goldcoins’ will forever refer to a ‘Non-Consumable’ as far as Apple is concerned.

The only way to work around this is to define an entirely new in app purchase with a different identifier and the correct type, eg “com.companyname.100goldcoins.v2”.

You must then tell Unibill that this purchase has a different identifier on the Apple App store, by overriding the identifier in the inventory editor:

Screen Shot 2013-01-05 at 12.23.59

Clearing Transaction History

You can clear Unibill’s local purchase database as follows, which you will typically want to do for testing purposes.


Accessing purchase receipts

Purchase receipts are available on all Platforms apart from the Mac App Store, currently. Simply call Unibiller.GetAllPurchaseReceipts(); passing in the purchasable item you wish to retrieve the receipt for.

The structure of the receipt differs on each platform, for which you should consult the relevant documentation of Apple, Google et al.

The Unibill demo scene

Unibill comes with a demonstration scene at Assets/Plugins/unibill/scenes/unibillDemo. The script that powers it is at Assets/script/UnibillDemo. Exploring this scene is a good way to understand how a Unibill application fits together.


The dropdown at the top of the screen lists all of the items that have been defined using the Inventory Editor. The ‘Buy’ button triggers a purchase request for the currently selected item.

The center of the screen is used to display the purchase counts for each item, as reported by Unibill.

You can test this scene immediately on an Android device using the Amazon SDK tester. To test it using Google Play or Apple App store billing you would need to upload your purchase metadata to Google and Apple.

Google Play

Configure your Google Play public key

You must enter your application’s public key in the ‘Google Play public key’ field of the inventory editor. To get your application’s public key you must first upload a draft APK to the publisher console. You can then find it’s public key under the ‘Services & APIs’ section for the application as the ‘Base64-encoded RSA public key’.

Bulk uploading purchase metadata to Google Play

There are two ways to upload your purchase metadata to Google Play:

1. Manually

Please note – as of Unibill 1.1.4, Unibill uses Google Play billing V3. With Google Play Billing V3, all the products that you create should be of type ‘managed’. Unibill will manage consumption of items for you; if you designate an item as being of type ‘Consumable’ within the inventory editor, Unibill will automatically consume the item before registering the purchase.

For details of how to manually define your purchases follow Google’s guide.

2. Automatically, using bulk upload

Note – subscriptions cannot be uploaded using this method, and must be created manually.

Unibill automatically generates a bulk upload CSV file for use with Google Play, located at Assets/Plugins/unibill/generated/googleplay/MassImportCSV.csv

To use bulk upload there are a couple of things you will need to configure in the inventory editor:

Screen Shot 2013-01-05 at 12.10.20

Default locale You must select the default locale that your application uses.
Autotranslate If checked, your item name and description will be automatically translated into all other locales.

For full details of the bulk upload process see Google’s guide.

Testing on an Android device

Before publishing your application, you must test your in App purchases on an Android device.

Note! You must publish your App as an Alpha or Beta distribution to test In App purchasing, testing from a draft published app is no longer supported by Google.

Your Alpha or Beta APK must be published to test your IAPs. This does not mean you have to make your App publicly available.

In order to perform a complete end to end test of your In App purchases, you must do so whilst signed into a device using a test account, because developers are prohibited from purchasing things from themselves.

For purchasing to work using a test account, note the following:

  • You MUST upload a signed, release version of your APK to Google Play (you do NOT have to publish it).
  • The version number of the APK that you upload MUST match the version number of the APK that you test with.
  • After entering your purchase metadata into the Google Play publisher console, it may take up to 24 hours before you are able to purchase your In App purchases using a test account.

Amazon Appstore

Entering your purchase metadata in the Amazon portal

You must enter your purchase metadata into the Amazon developer portal manually; there is no bulk upload facility. To do this you should follow the guide.

Testing using the Amazon test client

The Amazon SDK features an SDK tester that assists you with testing your purchases before you submit your app for review, documented here.

The SDK tester is a separate Android application that must be installed onto a test device alongside your application; you can install it from the Amazon App Store.

You must then select the ‘Use sandbox environment’ checkbox in the Unibill Inventory Editor:

Screen Shot 2013-01-06 at 14.54.51

When this box is ticked Unibill will automatically generate a JSON metadata file describing your purchases and write it to your device’s SD card when initialising. Be sure to untick this box before building the release version of your application.

You can use the Amazon SDK tester to thoroughly test your application, covering such scenarios as in app purchasing being disabled or otherwise unavailable. Simple launch the Amazon SDK tester application on the device to configure your test scenarios.

Apple App Store

Configuring your iOS SKU

You must enter your Application’s ‘SKU’ into the ‘iOS SKU’ field of the inventory editor, as it is configured in iTunes Connect:

Screen Shot 2013-01-06 at 14.59.35

Price tiers

This field is only relevant if you will be using the Application Loader and bulk upload template to enter your purchase metadata into iTunes Connect.

On iOS, prices are structured in tiers. You can set a purchasable’s tier using the slider within its ‘Apple App Store’ section.

Screen Shot 2013-01-06 at 15.07.44

Using the screenshot taker

On iOS, every In App purchase has to have an associated screenshot when being submitted to Apple for review. Unibill can help you prepare and submit these screenshots when using the Application Loader.

When running your application you can take a screenshot using ‘Window/Unibill/Take Screenshot“; screenshots are written to Assets/Plugins/unibill/screenshots/. The screenshot is taken of your game view; be sure you are running with a supported iTunes Connect screenshot resolution, such as 480 x 320 or 960 x 640.

You can then associate these screenshots with your purchasable items by assigning them to the ‘Screenshot’ fields in the Inventory Editor:

Screen Shot 2013-01-06 at 15.17.26

Uploading your purchase metadata using the Application loader

Note – subscriptions cannot be created using this method – they must be created manually in iTunes Connect.

Apple’s Application Loader lets you upload various aspects of your application to Apple, including binaries and details of your In App Purchases.

Unibill automatically generates a tab delimited bulk upload file describing your purchases, suitable for use with the Application loader. You can find this file at Assets/Plugins/unibill/generated/storekit/MassImportTemplate.

You can read the complete guide to the Application Loader here.

Please note that it may take several minutes between uploading your metadata and the metadata appearing in iTunes Connect.

Note for Unity iOS Standard users

Unity iOS standard does not support the post processing events Unibill uses to configure your xcode project automatically. You will therefore need to add the ‘Storekit.framework’ library to your XCode project, as in the following screenshot.

Screen Shot 2013-02-11 at 22.17.59

Testing on device

Testing on the iOS simulator is not supported.

To test on an iOS device you must be using an iTunes connect test user account; you can create these accounts in iTunes connect, then sign out of the app store on the device. You will be prompted to log in when you attempt a purchase or restore transactions.

Do not verify the email address of your test iTunes connect account! Doing so will make the account invalid for testing with the Apple sandbox environment.

If your products are being returned as unavailable for purchase, follow this checklist.

Mac App Store


Mac App Store purchasing follows a similar flow to that on iOS. You must be a registered Mac developer, create your Mac App store application in iTunes connect along with your in app purchase metadata.

You cannot use the same product identifiers for both iOS and Mac App store apps. Therefore, you will need to use the ‘override id’ functionality in the Inventory editor to specify the unique Mac App store identifiers you have entered into iTunes connect.

Testing In App Purchasing

When building a desktop Mac build you must select ‘Mac App Store validation’ within Unity’s build settings.

Once you have built your App, you must update its info.plist file with your bundle identifier and version strings. Right click on the .app file and click ‘show package contents’, locate the info.plist file and make the following modifications:

<string>[Your bundle identifier eg com.outlinegames.unibill]</string>

You must then sign, package and install your application. You will need to run the following commands from an OSX terminal:

codesign -f  –deep -s “3rd Party Mac Developer Application: [Your developer certificate name]” your.app

productbuild –component your.app /Applications –sign “3rd Party Mac Developer Installer: [Your installer certificate name]” your.pkg

In order to install the package correctly you must delete the unpackaged .app file before running the newly created package.

You must then launch your App from the Applications folder. The first time you do so, you will be prompted to enter your iTunes account details, for which you should enter your iTunes Connect test user account login. You will then be able to make test purchases against the sandbox environment.

You must sign, package, install your App and launch it from the Applications folder. If you do not do this you will not be able to make purchases.

You must not sign into the main App Store application using your test account or the test account will become invalid.

Windows Phone 8


There are two ways to test on Windows Phone 8; using Unibill’s inbuilt support for the WP8 Mock IAP framework, and by creating a beta distribution of your app. Both methods require a Windows Phone 8 device.


To test using the mock IAP framework, simply check the “Use mock windows phone” checkbox in the inventory editor. When using the mock framework all purchases succeed. Be sure to uncheck this when publishing.

To test your App as a beta App, create it as a Beta distribution in the windows phone dev centre. You will need to configure the App ID of the visual studio project Unity generates.

Windows 8.1


To test using the mock IAP framework, simply check the “Use mock windows 8” checkbox in the inventory editor. Be sure to uncheck this when publishing.

Samsung Apps


You must have a Samsung device with the Samsung Apps market app for testing on device!

You must register for a Samsung Apps seller account at seller.samsungapps.com, and enter your Samsung Apps Item Group in the inventory editor.

On Samsung Apps, your product identifiers are assigned for you by Samsung. You must tell Unibill what these identifiers are, by overriding the platform identifiers on samsung apps to these values, within the inventory editor:

Screen Shot 2014-02-19 at 22.16.26


In the inventory editor there are three modes that Unibill can run Samsung Apps with:

PRODUCTION Purchases are made against the live Samsung Apps service.You must select this mode to publish your APK
ALWAYS_SUCCEED Purchases will always succeed and a developer popup will show
ALWAYS_FAIL Purchases will always fail and a developer popup will show


*For all technical problems please include a trace from a device (using adb/XCode/Visual studio etc)*

Please direct all support queries to support@outlinegames.com.

Telephone support is available via Skype on request.


369 Responses to Unibill

  1. Lincoln Santos says:

    Hi, i’m updated unibill to the lastest version and now i’m getting this error:

    You must define your purchasable inventory within the inventory editor!
    StoreController:Start() (at Assets/Farting Fishes/Scripts/Controllers/StoreController.cs:31)

    I’ve opened the inventory editor and it seens all right but the error continues.

  2. Richard says:

    Are there any plans to make a javascript version?
    I am having nightmares trying to incorporate C# scripting and JS scripting together..

    • outlinegames says:

      What problems are you having? It ought to be fairly straightforward to call cs from js.

      • Richard says:

        I had it functioning, but then found that when trying to use GUI buttons that utilised international fonts in clones of the UniBillDemo.cs script,
        like this:
        if (GUI.Button (new Rect (aaa, bob,ccc,ddd), “सभी स्तरों पर पहुँचें”,GUIStyle)) { }
        then the international fonts would not show up for some reason…it would just display a row of question marks.
        So I put all the GUI functions into a javascript…which would display the fonts ….and then am trying to call initiatePurchase() .
        But am having a few problems seemingly due to script execution order.

        I was trying to use BroadcastMessage(“initiatePurchase”)

  3. Richard says:

    I have it working now…

  4. Oscar says:

    Hello, please, it works on Unity Free version?
    Thank you

  5. Willem Kokke says:

    I would like to be able to force the FakeBillingService to be used for some of my device builds (IOS Enterprise build for testing and review copies for journalists etc).

    What is the easiest way to support this?


    • outlinegames says:

      Look at the instantiateBillingSubsystem() method in BillerFactory.cs. You can just return the fake biller in your review builds.

      • Willem Kokke says:

        Thanks, that does the trick. I have added a preprocessor define (#if FORCE_FAKE_BILLING) around it so I can integrate it with my build server.

        If a vendor supported way to do this were to ever show up in the stock source code that would be great 😉

  6. sascha5d says:

    For reporting reasons I need to extract the price and currency symbol from the localizedPrice; does Unibill provide these values somewhere separately or does somebody know, how to achieve this in a reliable manner for all types of currencies and localizedPrices?

  7. escic says:

    i get a error with latest version.

    NullReferenceException: Object reference not set to an instance of an object
    InventoryEditor.OnGUI () (at Assets/Editor/unibill/src/InventoryEditor.cs:157)
    System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)

  8. Majid says:

    Any plans of adding Nokia X in app billing? It shouldn’t be difficult according to here ( http://developer.nokia.com/resources/library/nokia-x/nokia-in-app-payment/nokia-in-app-payment-porting-guide.html )

  9. bearback says:

    Any plans for adding Facebook support?

  10. Alain-Daniel says:

    I’m testing Hosted Config. The plugin pull the file correctly and then stores it. However, the new file is not applied until the *NEXT* start of the game. (Fetching the config file is an async call that purely saves the file to the disk).

    It kind of defeats the idea of pulling updated data from a server… How can I apply the next data immediately?

  11. Alexandre says:

    Do you have any plans to include paypal???
    I thing it’s the only thing that is missing in this plugin.

  12. Is there anyway to test that google play is sending back the correct localization prices for a local. Changing my language settings for instance to spanish still shows the same EN values from google play in the localizedpricedescription. Not sure how to try and force a different local.


    • outlinegames says:

      The locale is based on settings within google play, not the locale of your phone. I’m not entirely sure what it takes to change this, though google suggests a method based on rooting your phone and using a third party app to change it.

  13. MG says:

    How does Unibill work with NGUI? Do I have to have the latest version of NGUI?

  14. Lucky says:

    Great plugin! Is there any way to access the Currency mapping from code?

    I’ve specified how many “coins” are given by certain consumable purchases within the Currency mapping and I’d like to reference and display those numbers the player. Sounds straightforward and obvious, but I can’t seem to find a way to access that data. Thanks in advance!

    • outlinegames says:

      You can modify the biller to expose the ‘UnibillConfiguration’ member. You’ll see it has a list of ‘VirtualCurrency’ types, each of which has a list of mappings from Unibill ID to decimal (the amount given).

  15. Brent says:

    Hi, Would you consider supporting Facebook credits in the future?

  16. kumryung says:

    unibill is validates purchase receipts automatically.
    but, i want to check validate receipts on my server.
    what should I do?

    • outlinegames says:

      Google it. UniBill can’t do it for you, it just provides the receipt.

      • flenzine says:

        just a quick follow up on that comment, is there a way tell unibill to not automatically finish transactions (I think it’s ‘consumePurchase’ in Play Store and ‘reportFulfillment’ on Windows Store or something along this line) before the app finishes whatever it was doing (ex. Verification/delivering content).

        I’ve only done In-App purchase on iOS so I might be wrong thinking all the other Billing services allow the same sort of verification mechanism.

      • outlinegames says:

        No there is not, although I’m not sure why you would want to. Please contact support for these discussions, it’s much easier than a comments section.

  17. Zach says:

    Hi, I am concerned about which payment method is supported by Unibill? Paypal? debit/visa/master cards? or some other payment methods? Thnak you!

  18. Jody says:

    Hi, After the completion of purchase processing, when an application is completed before calling SendMessage, onPurchaseComplete may not be called.
    In this case, is acquisition of a receipt possible?
    Thank you.

  19. Majid says:

    Is it possible to not use the deviceidentifier id? the reason is that it adds READ PHONE STATE permission in the android and we are concern about the new Google Play Policy for using Advertising ID, this may make confusion and result removal of the game since we advertise in our games.

    Thank you.

    • outlinegames says:

      For non consumables, they could be restored via restoreTransactions() or, if the user tries to buy it again, onPurchaseComplete will fire and the user will not be charged.

      For consumables, there is no permanent receipt kept by google play post consumption; once it has been consumed Unibill cannot provide a receipt.

    • outlinegames says:

      Unibill does not add that permission.

      • Majid says:

        Actually in Unity whenever you use the following code:


        READ_PHONE_STATE will be added in the output APK automatically, it took us some time to find out why our latest update had that permission on Google Play.

        Once we removed this line from UnityUtil file in the Uniject folder, that permission vanished:

        public string DeviceId {
        get { return SystemInfo.deviceUniqueIdentifier; }

        Please investigate this.

  20. flenzine says:

    [Bug] Couldn’t remove currency mapping from Inventory Editor (I couldn’t find a place to file bug reports)

    If I hit the ‘x’ button on the top-right corner of each mapping and then ‘Save’, next time i open Inventory Editor those I just deleted are still present. Although I could remove the mapping from the generated json file.

  21. Flamingo2 says:

    Can inventory list be dynamic i.e. we can add new purchasable items to inventory at runtime without having to create a new build everytime we want to update inventory?

  22. John says:

    How could I use the “RestoreTransactions” feature for currency?
    In my game you can only purchase currency, then you purchase stuff with that currency using DebitBalance.

    if I delete the game, reinstall it and want to do a RestoreTransactions to get back my remaining currency, how would I do that?

  23. John says:

    is there somewhere a documentation about “Use Hosted config” ?
    or a sample file how this would look on the inside?

  24. John says:

    for some reason my Currency section is populated badly.
    the first Item appears 4 times. even if I delete them and save it down, as soon as I press Play it will populate it with some duplicates again.
    you can check the screenshot here: https://www.dropbox.com/s/n7j84y5mo1tfdgc/Capture.PNG

    also in the json I have this:
    currencies”: {
    “gems”: {
    “com.outlinegames.250goldcoins”: 250.0,
    “com.outlinegames.100goldcoins”: 100.0,
    “100gems”: 100.0,
    “250gems”: 250.0,
    “600gems”: 600.0,
    “2000gems”: 2000.0,
    “5000gems”: 5000.0

    even tho I don’t have the first 2 ones and the 250gems one.
    I tried deleting the json and also the folders in the “generated” folder but still recreates all that.

  25. Chris Hoopes says:

    I’m having a bit of a problem with getting Unibiller running on an Amazon Kindle Fire device. I’ve set up my IAP in the Amazon dashboard (and it’s been approved) but whenever I run my apk on device I get a “Running against SANDBOX Amazon environment” when Unibiller initializes even though the sandbox check box is off and useAmazonSandbox is set to “false” in unibillInventory.json.

    Because of this when I click on any IAP interaction I get an error telling me to wait until Unibiller is finished initializing so nothing ever works. What can I do to pull it out of sandbox mode and get this working?

  26. yeti says:

    Hi, just wondering how you could use unibiller to create sale items? Say if I have a purchasable item that cost $10 and at certain times I would like to reduce the price by 50%. From the app developer settings I can adjust the pricing tier for a set period of time, is there a unibiller API to query the price so I can change the way the item is presented in game? Alternatively would you create an additional purchasable item for each item at different prices?

  27. tk says:

    Hi, I have been testing unibill and now i want to reset the local store (or db) that contains information about how many items i test purchased. How do I do the reset?
    In other words, where is the file saved that i need to delete?

  28. stephen says:

    Does unibill support ios 6.x?

  29. Lea Hayes says:

    What is the correct way to programmatically select the active Android billing platform? We want to add this into our automated build pipeline.

  30. Konstantin says:

    Hi, I’ve been trying to use hosted inventory, but get error ” malformed” all the time. The URL I’ve set is “http:///Inventory.json.txt”.

  31. DFG says:

    Will you be supporting Xbox One down the line?

  32. Olaf S. says:

    Will you support a way to handle wp8 and w8 trial packages in your sdk? So far we have to do an extra handling for those platforms and retrieve licence information explicitly (i guess you sdk access the apps licence info already?! )

  33. Olaf S. says:

    My guess here is, that for those platforms you have a platform specific handling ( to access the microsoft store ) and in this class, you have access to the stores license information. Beside of all containing IAP products, this class contains the IsTrial property as well, which can be easily delegated to us (SDK users).

    You are definitly right, that, in a strict observation, this isn’t related to IAP – but since your sdk already enumerates through the available product ( EnumerateLicenses() ) i thought it could be kind of easy to add a method here.

    Anyway, thanks for the really FAST answer 🙂

  34. Jaguar says:

    Does unibill support IOS 7.1?

    • outlinegames says:

      Yes. Apple are highly unlikely to release an update that are not backwards compatibility with their existing In App Purchase APIs or they would break In App Purchase across countless apps in their own app store.

  35. Hi! What version of Samsung IAP SDK is bundled with Unibill?

  36. Xiaodong Weng says:

    How should I re-initialize the Unibiller state?
    My scenario is that when In-App purchase is turned off on iOS, we’d get STOREKIT_BILLING_UNAVAILABLE when initializing Unibill, but I’d like to be able to re-initialize the Unibiller when Application resumes from pause (In case user re-enabled In-app purchase then comes back to the app)

  37. tk says:

    I am confused on how i can test before submitting review for iOS.
    I delivered by in-app purchase package using application loader and made sure store kit framework is required in Xcode but i am still getting “orekit requestProducts returned no products.” Do I have to submit it for review and approved for the in-app purchase product to be visible? if so how can i test before releasing the game to the public?

  38. Xiaodong Weng says:

    It wouldn’t do anything, since the internal ‘Unibiller’ reference is already initialized, it’d just skip initialization. It won’t be calling OnBillerReady callback neither

    • Xiaodong Weng says:

      that was @Albert Timashev…
      looks like you can’t reply to a reply of a reply

    • Can you add a method to clean/reset the state of Unibiller completely, e.g. Unibiller.Reset() or something like that, so we may call it to reset everything and try to call Unibiller.Initialise() again?

      • Xiaodong Weng says:

        Sure, I need to add something like that, except I don’t know what will be in that function (C# side and platform specific code).

  39. Hi great tool. Noticed something strange with apple/mobile devices. Using a device only on wifi and then shutting wifi off. Purchase something. No confirmation window etc as expected since no connection to internet. Leave the app. Turn back on wifi. Get a bunch of confirmation prompts for any purchases i made while off line. If I accept purchase then launch app I dont get the items until i do another purchase (even if I cancel it). Should I be doing something different on launch to protect for this kinda of strange edge case?


    • BTW something that would trigger onpurchase which is what is happening now in the scenario above. It appears when I do another purchases unibiller is then detecting somehow that a purchase was made but never processed and then triggers onpurchase success.

  40. adrian says:

    Can Unibill work for alternative Android Storefronts ex: SlideMe?

  41. ssd710 says:

    Hello, one of out tester reported that the unibiller don’t work on ios7(I didn’t get the detail error info). Though the ios7 is not released publickly, could you check if it’s ok on ios7?

  42. Subash says:

    I am facing some issue with new version of Unibill (Ver No: 1.7). The purchase is successful and the purchase receipt is not getting in jSon format. Its look like encrypted.
    This issue happening only on IOS 7.x or higher. The same build is working fine on IOS 6.x devices. (We are getting json format receipt for IOS 6.x devices)
    Anyone have idea regarding this?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: