Get Product Pricing
Get the product pricing based on the customer's data.
Post
https://store.payproglobal.com/api/Products/GetProductPricingRequest Parameters
application/jsonGetProductPricingRequestModel
objectcouponCodes
array[string]optional
The coupon codes to you want to apply to the product.
useTestMode
booleanoptional
Possible values are true or false.
If true, the test mode will be applied, false otherwise.
It is false by default.
If true, the test mode will be applied, false otherwise.
It is false by default.
secretKey
stringconditional
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.
account > Store settings > General settings > Integration tab.
It is required only if useTestMode is true. Null by default.
paymentMethod
integeroptional
The payment method ID you want to apply.
The list of payment methods with IDs can be found here.
The list of payment methods with IDs can be found here.
ipAddress
stringoptional
The customer's IP address. It is used for detecting billingCountry
and currency. Based on it the product pricing will be calculated.
and currency. Based on it the product pricing will be calculated.
currency
stringoptional
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.
on billingCountry. The product pricing results will be displayed in this currency.
The list of available currency codes can be found here.
language
stringoptional
The language code. If it is defined,
name will be returned in this language. billingCountry
stringoptional
The customer's billing country code. If skipped, it is detected based on ipAddress.
The list of countries with codes can be found here.
The list of countries with codes can be found here.
billingState
stringoptional
The customer's billing state code. The list of states with codes can be found here.
billingZip
stringoptional
The customer's billing zip code.
products
array[object]The list of the products for which you want to receive the pricing details.
productId
integerrequired
The product ID for which you want to get the pricing details.
quantity
integeroptional
The quantity of the product for which you want to get the pricing details.
vendorAccountId
integerrequired
The vendor account ID identifies your PayPro Global account.
It can be found in Account settings > Business info.
It can be found in Account settings > Business info.
apiSecretKey
stringrequired
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.
that was generated specifically for authenticating API requests.
It can be found in Store settings > General settings > Integration tab.
Response Parameters
application/jsonGetProductPricingResponseModel
objectresponse
objectuseTestMode
booleanPossible values are true or false. If true, the test mode
was applied, false otherwise. It is false by default.
was applied, false otherwise. It is false by default.
paymentMethod
integerThe payment method ID you applied. The list of payment methods can be found here.
language
stringThe language code. The list of languages with codes can be found here.
ipAddress
stringThe customer's IP address. It is used for detecting billingCountry
and currency. Based on it the product pricing will be calculated.
and currency. Based on it the product pricing will be calculated.
ipAddressCountry
stringThe country code detected by customer's IP address. The list of countries with codes can be found here.
billingCountry
stringThe customer's billing country code. If skipped,
it is detected based on ipAddress. The list of countries with codes can be found here.
it is detected based on ipAddress. The list of countries with codes can be found here.
billingState
stringThe customer's billing state code. The list of states with codes can be found here.
billingZip
stringThe customer's billing zip code.
billingCurrency
stringThe billing currency code. It will be used for the transaction processing.
displayCurrency
stringThe 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
integerThe product ID that was used for the pricing calculations.
logoUrl
stringThe logo relative path.
recurring
objectThe properties of the recurring item.
selections
array[object]Selection items properties.
name
stringThe product name.
quantity
integerThe product quantity.
billingUnitPrice
numberThe unit price in the billing currency.
billingPriceBeforeDiscount
numberThe price before the discount in the billing currency.
billingDiscount
numberThe discount amount in the billing currency.
billingPrice
numberThe price with the discount in the billing currency.
billingTaxes
numberThe tax amount in the billing currency.
billingPriceWithTaxes
numberThe price with the tax amount in the billing currency.
displayUnitPrice
numberThe unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
numberThe price before the discount in the currency that was provided in displayCurrency.
displayDiscount
numberThe discount amount in the currency that was provided in the displayCurrency.
displayPrice
numberThe price with the discount in the currency that was provided in displayCurrency.
displayTaxes
numberThe tax amount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
numberThe price with the tax amount in the currency that was provided in displayCurrency.
sku
stringThe product SKU value.
appliedCouponCode
stringThe coupon code that was applied.
name
stringThe product name.
quantity
integerThe product quantity.
billingUnitPrice
numberThe unit price in the billing currency.
billingPriceBeforeDiscount
numberThe price before the discount in the billing currency.
billingDiscount
numberThe discount amount in the billing currency.
billingPrice
numberThe price with the discount in the billing currency.
billingTaxes
numberThe tax amount in the billing currency.
billingPriceWithTaxes
numberThe price with the tax amount in the billing currency.
displayUnitPrice
numberThe unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
numberThe price before the discount in the currency that was provided in displayCurrency.
displayDiscount
numberThe discount amount in the currency that was provided in displayCurrency.
displayPrice
numberThe price with the discount in the currency that was provided in displayCurrency.
displayTaxes
numberThe tax amount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
numberThe price with the tax amount in the currency that was provided in displayCurrency.
sku
stringThe product SKU value.
appliedCouponCode
stringThe coupon code that was applied.
selections
array[object]Selection items properties.
name
stringThe product name.
quantity
integerThe product quantity.
billingUnitPrice
numberThe unit price in the billing currency.
billingPriceBeforeDiscount
numberThe price before the discount in the billing currency.
billingDiscount
numberThe discount amount in the billing currency.
billingPrice
numberThe price with the discount in the billing currency.
billingTaxes
numberThe tax amount in the billing currency.
billingPriceWithTaxes
numberThe tax amount in the billing currency.
displayUnitPrice
numberThe unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
numberThe price before the discount in the currency that was provided in displayCurrency.
displayDiscount
numberThe discount amount in the currency that was provided in displayCurrency.
displayPrice
numberThe price with the discount in the currency that was provided in displayCurrency.
displayTaxes
numberThe price with the discount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
numberThe price with the tax amount in the currency that was provided in displayCurrency.
sku
stringThe product SKU value.
appliedCouponCode
stringThe coupon code that was applied.
name
stringThe product name.
quantity
integerThe product quantity.
billingUnitPrice
numberThe unit price in the billing currency.
billingPriceBeforeDiscount
numberThe price before the discount in the billing currency.
billingDiscount
numberThe discount amount in the billing currency.
billingPrice
numberThe price with the discount in the billing currency.
billingTaxes
numberThe tax amount in the billing currency.
billingPriceWithTaxes
numberThe tax amount in the billing currency.
displayUnitPrice
numberThe unit price in the currency that was provided in displayCurrency.
displayPriceBeforeDiscount
numberThe price before the discount in the currency that was provided in displayCurrency.
displayDiscount
numberThe discount amount in the currency that was provided in displayCurrency.
displayPrice
numberThe price with the discount in the currency that was provided in displayCurrency.
displayTaxes
numberThe price with the discount in the currency that was provided in displayCurrency.
displayPriceWithTaxes
numberThe price with the tax amount in the currency that was provided in displayCurrency.
sku
stringThe product SKU value.
appliedCouponCode
stringThe 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.
the coupon codes were not applied, they are not included.
request
objectcouponCodes
array[string]Coupon codes to apply.
useTestMode
booleanUse test mode.
secretKey
stringTest mode secret key.
paymentMethod
integerPayment method id. Defaults to Credit Card.
ipAddress
stringCustomer IP address. Used for BillingCountry first and then Currency detection.
currency
stringCurrency code. Detected based on BillingCountry if omitted.
language
stringLanguage code.
billingCountry
stringBilling country code. Detected based on IpAddress if omitted.
billingState
stringBilling state code.
billingZip
stringBilling zip code.
products
array[object]Products list.
productId
integerProduct id.
quantity
integerProduct quantity.
vendorAccountId
integerVendor account id.
apiSecretKey
stringVendor account API secret key.
errors
array[object]propertyWithError
stringpropertyErrorMessages
array[string]isSuccess
booleanRequest Sample
{
"couponCodes": [
"coupon code 1",
"coupon code 2"
],
"useTestMode": true,
"secretKey": "your_secret_key",
"paymentMethod": 1,
"ipAddress": "192.168.0.1",
"currency": "USD",
"language": "en",
"billingCountry": "US",
"billingState": "US-AL",
"billingZip": "12345",
"products": [
{
"productId": 12345,
"quantity": 1
},
{
"productId": 12345,
"quantity": 1
}
],
"vendorAccountId": 123456,
"apiSecretKey": "your_api_secret_key"
}
Response Sample
{
"response": {
"useTestMode": true,
"paymentMethod": 2,
"language": "en",
"ipAddress": "192.168.0.1",
"ipAddressCountry": "US",
"billingCountry": "US",
"billingState": "US-AL",
"billingZip": "12345",
"billingCurrency": "USD",
"displayCurrency": "USD",
"appliedTaxNames": ["Sales Tax"],
"productPricings": [{
"productId": 12345,
"logoUrl": "your_logo_url",
"recurring": {
"selections": [],
"name": "Test_product",
"quantity": 1,
"billingUnitPrice": 100.0,
"billingPriceBeforeDiscount": 100.0,
"billingDiscount": 0.0,
"billingPrice": 100.0,
"billingTaxes": 8.0,
"billingPriceWithTaxes": 108.0,
"displayUnitPrice": 100.0,
"displayPriceBeforeDiscount": 100.0,
"displayDiscount": 0.0,
"displayPrice": 100.0,
"displayTaxes": 8.0,
"displayPriceWithTaxes": 108.0,
"sku": null,
"appliedCouponCode": null
},
"selections": [],
"name": "Test_product",
"quantity": 1,
"billingUnitPrice": 100.0,
"billingPriceBeforeDiscount": 100.0,
"billingDiscount": 20.0,
"billingPrice": 80.00,
"billingTaxes": 6.40,
"billingPriceWithTaxes": 86.40,
"displayUnitPrice": 100.0,
"displayPriceBeforeDiscount": 100.0,
"displayDiscount": 20.00,
"displayPrice": 80.00,
"displayTaxes": 6.40,
"displayPriceWithTaxes": 86.40,
"sku": null,
"appliedCouponCode": "coupon_code_2"
},{
"productId": 12345,
"logoUrl": "your_logo_url",
"recurring": {
"selections": [],
"name": "Test_product_2",
"quantity": 1,
"billingUnitPrice": 25.00,
"billingPriceBeforeDiscount": 25.00,
"billingDiscount": 0.0,
"billingPrice": 25.0,
"billingTaxes": 2.0,
"billingPriceWithTaxes": 27.00,
"displayUnitPrice": 25.00,
"displayPriceBeforeDiscount": 25.00,
"displayDiscount": 0.0,
"displayPrice": 25.00,
"displayTaxes": 2.0,
"displayPriceWithTaxes": 27.00,
"sku": null,
"appliedCouponCode": null
},
"selections": [],
"name": "Test_product_2",
"quantity": 1,
"billingUnitPrice": 10.00,
"billingPriceBeforeDiscount": 10.00,
"billingDiscount": 2.0,
"billingPrice": 8.0,
"billingTaxes": 0.64,
"billingPriceWithTaxes": 8.64,
"displayUnitPrice": 10.00,
"displayPriceBeforeDiscount": 10.00,
"displayDiscount": 2.0,
"displayPrice": 8.0,
"displayTaxes": 0.64,
"displayPriceWithTaxes": 8.64,
"sku": null,
"appliedCouponCode": "coupon_code_2"
}],
"appliedCouponCodes": ["coupon_code_2"]
},
"request": {
"couponCodes": [
"coupon_code_1",
"coupon_code_2"
],
"useTestMode": true,
"secretKey": "your_secret_key",
"paymentMethod": 1,
"ipAddress": "192.168.0.1",
"currency": "USD",
"language": "en",
"billingCountry": "US",
"billingState": "US-AL",
"billingZip": "12345",
"products": [{
"productId": 12345,
"quantity": 1
},{
"productId": 12345,
"quantity": 1
}],
"vendorAccountId": 123456,
"apiSecretKey": "your_api_secret_key"
},
"errors": [],
"isSuccess": true
}