S_calculatePrice
Supported arguments
The following arguments are supported by S_calculatePrice query:
Field | Type | Description |
---|---|---|
input | S_API_CalculatePriceInput! |
Return type
The query returns theS_API_CalculatedAuctionPrice
type.
Example usage
You can calculate auction prices with this query
Query
Calculate auction price to set
query {
S_calculatePrice(input: {
price: {
amount: 10000,
currency: "EUR"
},
productId: "ffffffff-691e-11ea-afc4-ffffffffffff"
}) {
priceWithCommission { amount currency }
priceWithoutCommission { amount currency }
commission {
label
rate { amount currency }
}
}
}
Result
{
"data": {
"S_calculatePrice": {
"priceWithCommission": {
"amount": 10663,
"currency": "EUR"
},
"priceWithoutCommission": {
"amount": 9375,
"currency": "EUR"
},
"commission": {
"label": "Games, DLCs and software equal to and above 5 EUR (6% + €0.25)",
"rate": {
"amount": 625,
"currency": "EUR"
}
}
}
}
}