Player Item Management - Get Payment Token

NOTE: This is a Legacy Economy API, and is in bugfix-only mode. All new Economy features are being developed only for version 2. For payments flows where the provider requires playfab (the fulfiller) to initiate the transaction, but the client completes the rest of the flow. In the Xsolla case, the token returned here will be passed to Xsolla by the client to create a cart. Poll GetPurchase using the returned OrderId once you've completed the payment.

POST https://titleId.playfabapi.com/Client/GetPaymentToken

Request Header

Name Required Type Description
X-Authorization True

string

This API requires a client session ticket, available from any Client Login function.

Request Body

Name Required Type Description
TokenProvider True

string

The name of service to provide the payment token. Allowed Values are: xsolla

Responses

Name Type Description
200 OK

GetPaymentTokenResult

400 Bad Request

ApiErrorWrapper

This is the outer wrapper for all responses with errors

Security

X-Authorization

This API requires a client session ticket, available from any Client Login function.

Type: apiKey
In: header

Definitions

Name Description
ApiErrorWrapper

The basic wrapper around every failed API response

GetPaymentTokenRequest
GetPaymentTokenResult

ApiErrorWrapper

The basic wrapper around every failed API response

Name Type Description
code

integer

Numerical HTTP code

error

string

Playfab error code

errorCode

integer

Numerical PlayFab error code

errorDetails

object

Detailed description of individual issues with the request object

errorMessage

string

Description for the PlayFab errorCode

status

string

String HTTP code

GetPaymentTokenRequest

Name Type Description
TokenProvider

string

The name of service to provide the payment token. Allowed Values are: xsolla

GetPaymentTokenResult

Name Type Description
OrderId

string

PlayFab's purchase order identifier.

ProviderToken

string

The token from provider.

Error Codes

Name Code
InvalidPaymentProvider 1063
NoPartnerEnabled 1192