In-App Purchase

Integrated Payment Experience Inside Your Application

Purpose

The In-AppPurchase method is used to initiate a payment process directly within your own app or website—keeping the customer fully on your platform. All required payment details, including sensitive card information, are collected by your application and securely submitted to the myPOS Checkout API.

This method supports both initial payments with card details and recurring payments with a stored card token.

If you're handling card data directly (i.e., not using a stored token), your solution must be PCI DSS SAQ-D compliant. You’re also responsible for managing 3D Secure communication (e.g., via an MPI plugin).

Alternatively, you can store the card using IPCPurchase with CardTokenRequest = 1, and later use IPCIAPurchase with the CardToken.

Security Validations by myPOS The API will validate the following:

  • Valid myPOS Client number (WalletNumber)
  • Valid Store ID (SID)
  • Checkout status is enabled
  • Correct currency and amount
  • Proper KeyIndex and signature

Request Parameters

ParameterExampleTypeRequiredDescription
OrderID20120331999999StringYESPlaceholder for the merchant. Used to recognize the order (max 80 characters).
Amount23.45DoubleYESThe amount of payment requested.
CurrencyEURA(3)YESISO 3-character currency code. Must be registered and approved.
SID000000000000010StringYESStore ID (SID) - Reference number for the Merchant Store in the myPOS system.
WalletNumber61938166610StringYESmyPOS Client Number.
KeyIndex1IntYESIndicates which key pair is being used.
CardType1N(1)ConditionalRequired when CardToken is not provided. See Card Types.
PANByte[] (BASE64)BASE64ConditionalRequired when CardToken is not provided.
CardholderNameJohn SmithString (30)ConditionalRequired when CardToken is not provided.
ExpDateByte[] (BASE64)BASE64ConditionalRequired when CardToken is not provided.
CVCByte[] (BASE64)BASE64ConditionalRequired when CardToken is not provided.
ECI6N(1)ConditionalRequired when CardToken is not provided.
AVVByte[] (BASE64)BASE64ConditionalRequired when CardToken is not provided and the card is 3DS enabled.
XIDByte[] (BASE64)BASE64ConditionalRequired when CardToken is not provided and the card is 3DS enabled.
CardTokenByte[] (BASE64)BASE64ConditionalRequired when the card is already stored and no additional card data is sent.
AccountSettlement11111111119N(11)NOAccount for payment settlement.
NoteStringNOText associated with the purchase.
CartItems2IntYESNumber of items in the cart. Add fees/taxes as new items.
CartLogical HolderLogical RecordYESArray describing the shopping cart content.
OutputFormatXMLStringNOOutput format: “XML” or “JSON”. Defaults to “XML”.
PartnerIDmps-p-XXXXXXXXStringConditionalRequired if you are part of the Partners Program (API version 1.4.1+).
ApplicationIDmps-app-XXXXXXXXStringConditionalRequired if you are part of the Partners Program (API version 1.4.1+).

Cart Item Parameters

PropertyExampleTypeDescription
Article_1HP ProBook 6360b stickerStringName of an article in the shopping cart.
Quantity_12IntHow many pieces of an article.
Price_12.34DoublePrice of a single unit.
Amount_14.68DoubleQuantity × Price for the article.
Currency_1EURA(3)Should be the same currency as in the purchase.

Response Parameters

PropertyExampleTypeDescription
Amount23.45DoubleEcho from IPCIAPurchase
CurrencyEURA(3)Echo from IPCIAPurchase
OrderID201203319999999StringEcho from IPCIAPurchase
IPC_Trnref12345678923StringUnique transaction ID in IPC; used for refunds/reversals
PaymentReferenceMTCOR0123456XXK7StringPayment Reference of the transaction

Important Notes

  • Use IPCIAPurchase for in-app or direct payments (initial or recurring).
  • You must be PCI SAQ-D compliant if handling card data.
  • Use a stored token for easier compliance and less liability.
  • Validate all response data and signatures for secure processing.

Partner Identification

If you are part of our Partners Program, you will need to submit these two additional parameters with each of your requests to the API. This will provide you with analytics about the usage in your myPOS Partners Portal account and help our support teams assist you better.

This requires you to set the API version of your requests to 1.4.1. No other changes in the code/requests are necessary.

PropertyExampleTypeDescription
PartnerIDmps-p-XXXXXXXXStringIdentical number for the partner
ApplicationIDmps-app-XXXXXXXXStringIdentical number for the application

Example Request

<ipc_response is-array="true">
<IPCmethod>IPCIAPurchase</IPCmethod>
<IPC_Trnref>131753</IPC_Trnref>
<PaymentReference>MTCOR0124565XXK7</PaymentReference>
<Amount>50</Amount>
<Currency>EUR</Currency>
<Status>0</Status>
<StatusMsg>Success</StatusMsg>
<Signature>K6E5HZd21zGWVB4aEBwVOp1XuQMwGZiVk57FFu3sSnkD/M0v30XHFYL3dh7yKifKeOICQIrmzi3XKgnhwPMb/TgeNCOafgZ4EW9I4faP0TTmM0QrvAoayZjb4PG/tIcMgFiUKBr+K/Cbqcw7yLkDEzavfWBy5IT4Hmv92CAPKo8=</Signature>
</ipc_response>