Services Overview

Sce.PlayStation.Core.Services provides a feature for network services.

Account Information

AccountInformation is a static class representing information about a network account.

AccountInformation holds a unique 16 byte number per account. This value can be used to identify an account and to encrypt save data. Note that on the PC simulator, a dummy value will be returned based on the user name.

In-App Purchase dialog

InAppPurchaseDialog is a dialog class for processing In-App Purchase, and it inherits the ICommonDialog interface. In-App Purchase is mainly processed according to access to the server, and the billing contents display and user input processing are also performed as necessary.

InAppPurchaseDialog retains the list of products. This is read from metadata (app.xml), but pricing, tickets, and other information not included in app.xml will not be read. That information must be obtained from the server.

InAppPurchaseDialog can access the server by opening the dialog. To open the dialog, use the GetProductInfo(), GetTicketInfo(), Purchase(), and Consume() functions. Note that the Open() function cannot be used.

  • GetProductInfo() : Obtains the product information. (Required before purchase)
  • GetTicketInfo(): Obtains the ticket information. (Required before purchase and consumption)
  • Purchase(): Purchases the product.
  • Consume(): Consumes the ticket.

Basically the same usage as the ICommonDialog interface, such as waiting for completion of dialog processing and confirming whether dialog processing was successful. When dialog processing is successful, the information stored in the product list is updated.

Purchasing and consumption may be processed by the server, even if dialog processing result is Error or Aborted. This occurs due to network disconnection after sending of a request. Therefore, if the result of dialog processing is Error or Aborted, use GetTicketInfo() to obtain ticket information in advance, and confirm whether purchasing and consumption have been processed by the server.

About the Development Environment

The InAppPurchaseDialog behaves differently in the development environment and in the end user environment.

  • Not connected to the server
  • Purchase information is saved to a local file.
  • User input is required every time an API is called.
  • An error can be generated via the error button in the dialog.
  • The product label string is stored to the product price string.

In a developer environment, In-App Purchase operates as pseudo emulation. The status is recorded in the local file without connecting to the server. To clear purchase information in the developer environment, execute the following.

  • PC simulator: click the [Reset] button of the dialog displayed when the API is called.
  • PlayStation(R)Vita: use the PlayStation(R)Mobile Development Assistant menu.

Moreover, in the development environment, user input is required every time an API is called. Click the error button in the dialog to confirm the behavior of the application upon a network error occurrence. In the end user environment, user input is only required where it is necessary.

Moreover, in the development environment, the product label string is stored in the product price string as a precautionary measure to prevent incorrect price displays.