Skip to main content

Get Product Pricing

Get the product pricing based on the customer's data.

Request Parametersapplication/json
GetProductPricingRequestModel
object
couponCodes
array[string]
The coupon codes to you want to apply to the product.
useTestMode
boolean
Possible values are true or false.
If true, the test mode will be applied, false otherwise.
It is false by default.
secretKey
string
The unique secret key. It can be found in your
account > Store settings > General settings > Integration tab.
It is required only if useTestMode is true. Null by default.
paymentMethod
integer
The payment method ID you want to apply.
The list of payment methods with IDs can be found here.
ipAddress
string
The customer's IP address. It is used for detecting billingCountry
and currency. Based on it the product pricing will be calculated.
currency
string
The currency code you want to apply. If skipped, it is detected based
on billingCountry. The product pricing results will be displayed in this currency.
The list of available currency codes can be found here.
language
string
The language code. If it is defined, name will be returned in this language.
billingCountry
string
The customer's billing country code. If skipped, it is detected based on ipAddress.
The list of countries with codes can be found here.
billingState
string
The customer's billing state code. The list of states with codes can be found here.
billingZip
string
The customer's billing zip code.
products
array[object]
The list of the products for which you want to receive the pricing details.
productId
integer
required
The product ID for which you want to get the pricing details.
quantity
integer
The quantity of the product for which you want to get the pricing details.
vendorAccountId
integer
required
The vendor account ID identifies your PayPro Global account.
It can be found in Account settings > Business info.
apiSecretKey
string
required
The vendor account API secret key is a unique key
that was generated specifically for authenticating API requests.
It can be found in Store settings > General settings > Integration tab.
Response Parametersapplication/json
GetProductPricingResponseModel
object
response
object
useTestMode
boolean
Possible values are true or false. If true, the test mode
was applied, false otherwise. It is false by default.
paymentMethod
integer
The payment method ID you applied. The list of payment methods can be found here.
language
string
The language code. The list of languages with codes can be found here.
ipAddress
string
The customer's IP address. It is used for detecting billingCountry
and currency. Based on it the product pricing will be calculated.
ipAddressCountry
string
The country code detected by customer's IP address. The list of countries with codes can be found here.
billingCountry
string
The customer's billing country code. If skipped,
it is detected based on ipAddress. The list of countries with codes can be found here.
billingState
string
The customer's billing state code. The list of states with codes can be found here.
billingZip
string
The customer's billing zip code.
billingCurrency
string
The billing currency code. It will be used for the transaction processing.
displayCurrency
string
The currency code displayed to the customer if it differs from the billingCurrency.
appliedTaxNames
array[string]
A list of the applied tax names (e.g., "VAT" for Europe, "GST, PST, HTS" for Canada, etc.).
productPricings
array[object]
A list of the calculated product pricings according to customer's information.
productId
integer
The product ID that was used for the pricing calculations.
logoUrl
string
The logo relative path.
recurring
object
The properties of the recurring item.
selections
array[object]
Selection items properties.
name
string
The product name.
quantity
integer
The product quantity.
billingUnitPrice
number
The unit price in the billing currency.
billingPriceBeforeDiscount
number
The price before the discount in the billing currency.
billingDiscount
number
The discount amount in the billing currency.
billingPrice
number
The price with the discount in the billing currency.
billingTaxes
number
The tax amount in the billing currency.
billingPriceWithTaxes
number
The price with the tax amount in the billing currency.
displayUnitPrice
number
The unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
number
The price before the discount in the currency that was provided in displayCurrency.
displayDiscount
number
The discount amount in the currency that was provided in the displayCurrency.
displayPrice
number
The price with the discount in the currency that was provided in displayCurrency.
displayTaxes
number
The tax amount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
number
The price with the tax amount in the currency that was provided in displayCurrency.
sku
string
The product SKU value.
appliedCouponCode
string
The coupon code that was applied.
name
string
The product name.
quantity
integer
The product quantity.
billingUnitPrice
number
The unit price in the billing currency.
billingPriceBeforeDiscount
number
The price before the discount in the billing currency.
billingDiscount
number
The discount amount in the billing currency.
billingPrice
number
The price with the discount in the billing currency.
billingTaxes
number
The tax amount in the billing currency.
billingPriceWithTaxes
number
The price with the tax amount in the billing currency.
displayUnitPrice
number
The unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
number
The price before the discount in the currency that was provided in displayCurrency.
displayDiscount
number
The discount amount in the currency that was provided in displayCurrency.
displayPrice
number
The price with the discount in the currency that was provided in displayCurrency.
displayTaxes
number
The tax amount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
number
The price with the tax amount in the currency that was provided in displayCurrency.
sku
string
The product SKU value.
appliedCouponCode
string
The coupon code that was applied.
selections
array[object]
Selection items properties.
name
string
The product name.
quantity
integer
The product quantity.
billingUnitPrice
number
The unit price in the billing currency.
billingPriceBeforeDiscount
number
The price before the discount in the billing currency.
billingDiscount
number
The discount amount in the billing currency.
billingPrice
number
The price with the discount in the billing currency.
billingTaxes
number
The tax amount in the billing currency.
billingPriceWithTaxes
number
The tax amount in the billing currency.
displayUnitPrice
number
The unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
number
The price before the discount in the currency that was provided in displayCurrency.
displayDiscount
number
The discount amount in the currency that was provided in displayCurrency.
displayPrice
number
The price with the discount in the currency that was provided in displayCurrency.
displayTaxes
number
The price with the discount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
number
The price with the tax amount in the currency that was provided in displayCurrency.
sku
string
The product SKU value.
appliedCouponCode
string
The coupon code that was applied.
name
string
The product name.
quantity
integer
The product quantity.
billingUnitPrice
number
The unit price in the billing currency.
billingPriceBeforeDiscount
number
The price before the discount in the billing currency.
billingDiscount
number
The discount amount in the billing currency.
billingPrice
number
The price with the discount in the billing currency.
billingTaxes
number
The tax amount in the billing currency.
billingPriceWithTaxes
number
The tax amount in the billing currency.
displayUnitPrice
number
The unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
number
The price before the discount in the currency that was provided in displayCurrency.
displayDiscount
number
The discount amount in the currency that was provided in displayCurrency.
displayPrice
number
The price with the discount in the currency that was provided in displayCurrency.
displayTaxes
number
The price with the discount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
number
The price with the tax amount in the currency that was provided in displayCurrency.
sku
string
The product SKU value.
appliedCouponCode
string
The coupon code that was applied.
appliedCouponCodes
array[string]
The coupon codes that were applied. If any of provided
the coupon codes were not applied, they are not included.
request
object
couponCodes
array[string]
Coupon codes to apply.
useTestMode
boolean
Use test mode.
secretKey
string
Test mode secret key.
paymentMethod
integer
Payment method id. Defaults to Credit Card.
ipAddress
string
Customer IP address. Used for BillingCountry first and then Currency detection.
currency
string
Currency code. Detected based on BillingCountry if omitted.
language
string
Language code.
billingCountry
string
Billing country code. Detected based on IpAddress if omitted.
billingState
string
Billing state code.
billingZip
string
Billing zip code.
products
array[object]
Products list.
productId
integer
Product id.
quantity
integer
Product quantity.
vendorAccountId
integer
Vendor account id.
apiSecretKey
string
Vendor account API secret key.
errors
array[object]
propertyWithError
string
propertyErrorMessages
array[string]
isSuccess
boolean
Request Sample
{
"couponCodes": [
"sample string 1",
"sample string 2"
],
"useTestMode": true,
"secretKey": "sample string 1",
"paymentMethod": 1,
"ipAddress": "sample string 2",
"currency": "sample string 3",
"language": "sample string 4",
"billingCountry": "sample string 5",
"billingState": "sample string 6",
"billingZip": "sample string 7",
"products": [
{
"productId": 37491,
"quantity": 1
},
{
"productId": 37491,
"quantity": 1
}
],
"vendorAccountId": 123456,
"apiSecretKey": "your_api_secret_key"
}
Response Sample
{
"response": {
"useTestMode": true,
"paymentMethod": 2,
"language": "sample string 3",
"ipAddress": "sample string 4",
"ipAddressCountry": "sample string 5",
"billingCountry": "sample string 6",
"billingState": "sample string 7",
"billingZip": "sample string 8",
"billingCurrency": "sample string 9",
"displayCurrency": "sample string 10",
"appliedTaxNames": [
"sample string 1",
"sample string 2"
],
"productPricings": [
{
"productId": 37491,
"logoUrl": "sample string 2",
"recurring": {
"selections": [
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
},
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
}
],
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
},
"selections": [
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
},
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
}
],
"name": "John Doe",
"quantity": 4,
"billingUnitPrice": 5.0,
"billingPriceBeforeDiscount": 13.0,
"billingDiscount": 6.0,
"billingPrice": 7.0,
"billingTaxes": 8.0,
"billingPriceWithTaxes": 9.0,
"displayUnitPrice": 10.0,
"displayPriceBeforeDiscount": 23.0,
"displayDiscount": 11.0,
"displayPrice": 12.0,
"displayTaxes": 13.0,
"displayPriceWithTaxes": 14.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 16"
},
{
"productId": 37491,
"logoUrl": "sample string 2",
"recurring": {
"selections": [
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
},
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
}
],
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
},
"selections": [
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
},
{
"name": "John Doe",
"quantity": 2,
"billingUnitPrice": 3.0,
"billingPriceBeforeDiscount": 9.0,
"billingDiscount": 4.0,
"billingPrice": 5.0,
"billingTaxes": 6.0,
"billingPriceWithTaxes": 7.0,
"displayUnitPrice": 8.0,
"displayPriceBeforeDiscount": 19.0,
"displayDiscount": 9.0,
"displayPrice": 10.0,
"displayTaxes": 11.0,
"displayPriceWithTaxes": 12.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 14"
}
],
"name": "John Doe",
"quantity": 4,
"billingUnitPrice": 5.0,
"billingPriceBeforeDiscount": 13.0,
"billingDiscount": 6.0,
"billingPrice": 7.0,
"billingTaxes": 8.0,
"billingPriceWithTaxes": 9.0,
"displayUnitPrice": 10.0,
"displayPriceBeforeDiscount": 23.0,
"displayDiscount": 11.0,
"displayPrice": 12.0,
"displayTaxes": 13.0,
"displayPriceWithTaxes": 14.0,
"sku": "ABF-478-5297-RI",
"appliedCouponCode": "sample string 16"
}
],
"appliedCouponCodes": [
"sample string 1",
"sample string 2"
]
},
"request": {
"couponCodes": [
"sample string 1",
"sample string 2"
],
"useTestMode": true,
"secretKey": "sample string 1",
"paymentMethod": 1,
"ipAddress": "sample string 2",
"currency": "sample string 3",
"language": "sample string 4",
"billingCountry": "sample string 5",
"billingState": "sample string 6",
"billingZip": "sample string 7",
"products": [
{
"productId": 37491,
"quantity": 1
},
{
"productId": 37491,
"quantity": 1
}
],
"vendorAccountId": 123456,
"apiSecretKey": "your_api_secret_key"
},
"errors": [
{
"propertyWithError": "orderId",
"propertyErrorMessages": [
"Error message 1",
"Error message 2"
]
},
{
"propertyWithError": "orderId",
"propertyErrorMessages": [
"Error message 1",
"Error message 2"
]
}
],
"isSuccess": false
}