Kinguin term | API context |
---|---|
Merchant | Seller, who lists offers on their account. Merchants can be categorized into those integrated with the API and those who are using only the Merchant Dashboard. Integrated sellers can use API functions to manage offers, deliver orders, etc, while non-integrated merchants operate solely through the platform's interface. |
Buyer | User of the Kinguin platform purchasing offers. |
Product | A predefined item with a complete description, images, and other necessary details. Each product must be approved by customer support before becoming available on the platform. Products are integral to the creation of offers. |
Offer | Specific price proposal for a product. Each offer is associated with a specific product and includes details such as pricing, availability, and other relevant information. Merchants create and manage offers to showcase their products to potential buyers on the Kinguin platform. |
Order | A purchase made by a buyer, which may include various offers for different products in varying quantities. An order is the result of a buyer's selection from the available offers. |
Reservation | A reference to each purchased key. Number of reservations is equal to the number of bought keys in an order. |
Price | The amount charged for a key, specified in the API in eurocents. This is the price visible to buyers on the product page. |
Price IWTR | The amount the seller will receive for selling a key. Price IWTR is specified in the API in eurocents. |
Product page | The page on the Kinguin platform that provides a comprehensive description of the product, along with a list of available offers for that product, including prices. |
Webhook | Event informing about reservation status change sent to specific URLs set by the merchant. |
SPA | Smart Pricing Assistant – a bot for price adjustment. |
Within our API system, we provide support for two types of prices: price and priceIWTR (Price I Want To Receive). The prices consists of amount (in eurocents) and currency (always "EUR") fields.
Below you will find detailed information about these fields and their usage in API requests and responses.
1. Price The price field refers to the price visible to customers on the product page (it accounts for commissions). It represents the price customers will see before making a purchase. Sample structure of the price field in JSON format:
"price": {
"amount": 200, // Amount in cents
"currency": "EUR" // Currency (always EUR)
}
2. Price IWTR The priceIWTR field specifies the price the seller will ultimately receive for sold products. Sample structure of the priceIWTR field in JSON format:
"priceIWTR": {
"amount": 200, // Amount in cents
"currency": "EUR" // Currency (always EUR)
}
📌 Notes on price and currency format:
To determine the price from priceIWTR and vice versa, taking into account the Kinguin commission, please refer to the Commissions section for detailed calculations.
This section outlines the rules and processes related to various fees and charges that may apply to merchants.
For every price change (excluding the SPA functionality), a fee will be charged. Merchants are allowed 3 free price changes per offer per day.
Fee Details:
Fee for using the SPA functionality is charged once a week, based on the number of offers where the SPA was active during the previous week. Merchants can use the SPA functionality for free on up to 5 offers.
Fee Details:
Commission refers to the fee charged by the platform, deducted from the final price of the product before transferring funds to the seller. This commission is included in the final price seen on Kinguin product page. The price without commission, which is the amount the seller receives for selling the product, is represented by the priceIWTR field.
Commission is represented within an offer by the following field:
"commissionRule": {
"id": "86656332-4494-4834-87f2-1214a69ce70e",
"ruleName": "KinguinBaseCommssion",
"fixedAmount": 10,
"percentValue": 10
}
where
To calculate price from priceIWTR and vice versa (based on Kinguin commission), use the endpoint:
**See detailed documentation
curl -X GET \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/calculations/priceAndCommission?kpcProductId=[kpcProductId]&price=[price]
The system allows to calculate priceIWTR based on the final price. However, due to rounding to two decimal places, multiple distinct price values can result in the same priceIWTR. Example:Consider the following scenarios: price = 10524 -> priceIWTR = 10009 price = 10525 -> priceIWTR = 10010 price = 10526 -> priceIWTR = 10010 price = 10527 -> priceIWTR = 10011 In this example, both price values of 10525 and 10526 result in the same priceIWTR of 10010. Solution:To address this, the /priceAndCommission endpoint prioritizes priceIWTR as the primary price reference. Therefore, when a user queries this endpoint with a specific priceIWTR, the system returns the corresponding lowest price value that yields that priceIWTR after rounding. If a user queries /priceAndCommission with priceIWTR = 10010, the system will return price = 10525, as it is the lowest price that results in the desired priceIWTR after rounding. Conclusion:This approach ensures that each priceIWTR maps to a unique and predictable price value, maintaining consistency and accuracy within the system.
📌 Notes on commissions:
Date and time fields are represented in the format YYYY-MM-DDTHH:mm:ss.ms+0000 where +0000 is the GMT timezone.
Example of a date time field:
"createDate": "2021-08-31T13:00:38.914+0000"
Kinguin API is dedicated to sellers and enables the entire sales process to be conducted comprehensively, meaning that sellers can handle all stages of the transaction, from start to finish, using only our API - from creating an offer to sending the key to the buyer.
This integration enables sellers to easily create and modify offers, effectively manage their inventory of product keys, and utilize the "declared stock approach" for accurate inventory tracking and timely delivery to customers. Additionally, sellers have the option to engage in wholesale selling, with the ability to offer discounts based on the quantity of keys purchased.
To create an offer use the endpoint with required productId and price fields:
**See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"productId": "${PRODUCT_ID}", "price": {"amount": 2, "currency": "EUR"}}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers
response:
{
"id": "660691850f65d000010da229",
"productId": "60d990172adc85b8f1b1ee96",
"name": "Forspoken EU PS5 CD Key",
"sellerId": 1066100,
"status": "ACTIVE",
"block": null,
"priceIWTR": {
"amount": 1500,
"currency": "EUR"
},
"price": {
"amount": 1660,
"currency": "EUR"
},
"commissionRule": {
"id": "86656332-4494-4834-87f2-1214a69ce70e",
"ruleName": "super-deal",
"fixedAmount": 10,
"percentValue": 10
},
"declaredStock": 0,
"maxDeliveryDate": null,
"declaredTextStock": 0,
"reservedStock": 0,
"availableStock": 0,
"buyableStock": 0,
"updatedAt": "2024-03-29T10:01:42.177+0000",
"createdAt": "2024-03-29T10:01:41.733+0000",
"wholesale": {
"name": "Default",
"enabled": true,
"tiers": [
{
"discount": 0,
"level": 1,
"price": {
"amount": 1590,
"currency": "EUR"
},
"priceIWTR": {
"amount": 1500,
"currency": "EUR"
}
},
{
"discount": 0,
"level": 2,
"price": {
"amount": 1530,
"currency": "EUR"
},
"priceIWTR": {
"amount": 1500,
"currency": "EUR"
}
},
{
"discount": 0,
"level": 3,
"price": {
"amount": 1515,
"currency": "EUR"
},
"priceIWTR": {
"amount": 1500,
"currency": "EUR"
}
},
{
"discount": 0,
"level": 4,
"price": {
"amount": 1500,
"currency": "EUR"
},
"priceIWTR": {
"amount": 1500,
"currency": "EUR"
}
}
]
},
"sold": 0,
"productDetails": {
"metacritic": null,
"region": {
"id": 3,
"name": "Region Free"
},
"platform": {
"id": 13,
"name": "Other"
},
"imageUrl": "https://static.kinguin.net/media/images/products/_111.png",
"softwareMS": null,
"productType": {
"softwareMS": false,
"prePaid": true,
"skinsCSGO": false,
"randomProduct": false,
"indieValley": false,
"nft": false,
"businessStore": false
},
"marketingProductType": "GAME"
},
"preOrder": false,
"sold1d": 0,
"sold7d": 0,
"sold30d": 0,
"popularityBid": {
"amount": 0,
"currency": "EUR"
},
"popularityPosition": null,
"popularity": 0.0,
"buyButtonProbability": null,
"buyButtonBidEnabled": true,
"hasBuyButtonDeal": false,
"outOfStockIn1day": null,
"merchantType": "MERCHANT",
"salesBoosterActivationDate": null,
"salesBoosterRenewal": false,
"spaActive": false,
"favorite": null,
"bestWholesaleOffer": null,
"bestOffer": null
}
The optional status field in the request accepts values "ACTIVE" or "INACTIVE". If the field is not provided, it defaults to "ACTIVE".
Some products may undergo automatic system blocking. In such cases, the offer's status remain ACTIVE, but the block field will not be null or empty, indicating that the offer is unavailable for purchase by customers. For more details regarding blocked offers, please refer here.
The offer will be visible on the Kinguin product page after meeting the following criteria:
📌 Notes on offer creation:
To upload upfront stock, the offer must first be created. The uploaded key can be a type can be in the form of text or image (base64). Allowed request mime types: "text/plain", "image/jpeg", "image/png", "image/gif"
**See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"body": "key123", "mimeType": "text/plain"}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}/stock
response:
{
"id":"f64e66d5-e26c-426a-ba8b-cfeb220972ff",
"productId":"${PRODUCT_ID}",
"offerId":"${OFFER_ID}",
"sellerId":5005408,
"status":"AVAILABLE"
}
Stock status description:
There are 4 fields describing your AVAILABLE stock:
{
[...]
"availableStock": 2, // upfront uploaded stock
"buyableStock": 22, // actual available for purchase stock
"declaredStock": 20, // declared stock, not physically added to Kinguin's stock
"reserverdStock": 4, // purchased stock but not yet paid or delivered - reserved keys before finalizing the transaction
[...]
}
📌 Notes on stock upload:
There is no possibility to delete the key from the stock via API, you can do it manually in the Merchant Panel in the offer edition tab and this operation requires Two Factor Authentication (2FA).
The declared stock approach is an automation of the key delivery process. To fully automate this process, merchants should listen to the webhooks sent by Kinguin and respond accordingly, including delivering keys to paid orders.
Declared stock
You can specify the declaredStock for an offer when creating it:
**See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"productId": "${PRODUCT_ID}", "price": {"amount": 2, "currency": "EUR"}, "declaredStock": 100}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers
or updating an existing one:
**See detailed documentation
curl -i -X PATCH \
-H "Authorization: Bearer ${BEARER}" \
-H "Content-Type: application/json" \
-d '{"declaredStock": 100}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}
Declared text stock
Some of our clients and sales channels require keys to be delivered in text format. To accommodate such cases effectively, it's necessary not only to track the quantity of available text stock but also to ensure the provision of this type of key upon customer request during order placement. To manage this process seamlessly, alongside specifying the quantity of available stock, ensure to set the value in the declaredTextStock field. If a customer orders a text stock (identifiable by the 'requestedKeyType=TEXT' field in webhook events), you should provide a text stock and additionally include the reservation reference via the reservationId field.
The field means how much of the stock set in the declaredStock is of the text type. so its value should be lower or equal (when all all the available stock is text) than declaredStock.
You can specify the declaredTextStock for an offer when creating it:
**See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"productId": "${PRODUCT_ID}", "price": {"amount": 2, "currency": "EUR"}, "declaredStock": 100, "declaredTextStock": 20}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers
or updating an existing one:
**See detailed documentation
curl -i -X PATCH \
-H "Authorization: Bearer ${BEARER}" \
-H "Content-Type: application/json" \
-d '{"declaredStock": 100, "declaredTextStock": 20}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}
A fee may apply for undelivered orders due to a Cancel_Out_of_Stock alert. Fees may vary between retail and wholesale orders. Please contact your account manager for the latest pricing details.
Webhooks are events sent to specific URLs set by the merchant. These events are associated with changes in reservation status (for individual purchased keys). Webhooks are sent for individual keys to handle wholesale scenarios and cases where the merchant has part of the stock uploaded previously and part declared, which must be delivered after purchase.
Webhooks subscription To be able to handle the declared stock approach, setting up URLs for webhooks is required. This can be done either by sending a request: **See detailed documentation
curl -i -X POST \
https://gateway.kinguin.net/envoy2/api/v1/subscription \
-H 'authorization: Bearer ${BEARER}' \
-H 'content-type: application/json' \
-d '{
"endpoints": {
"reserve": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"give": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"cancel": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"delivered": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"outofstock": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"returned": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"reversed": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"refunded": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"processingpreorder": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"offerblocked": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"processingingame": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"chatmessage": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c",
"orderprocessing": "https://webhook.site/6e8ab695-872b-46a2-affe-218ac3b35c5c"
},
"headers": [{"name":"X-Auth-Token", "value":"xxxx"}]
}'
or using the Merchant Panel:
The preview of the configured subscription is available at the endpoint
Each webhook request is attempted up to 3 times upon receiving a reservation status change. Subsequent attempts occur at intervals: 1st attempt is made immediatelly, 2nd attempt after 5 minutes from the last failure, 3rd after 15 minutes.
Notes on webhooks subscription:
Webhooks description
Webhook name | Reservation status | Description |
---|---|---|
reserve | BUYING | When a user initiates the purchasing process (proceeds to the payment gateway). |
give | BOUGHT | When payment confirmation is received. |
cancel | CANCELED | When a reservation is canceled, such as during a payment gateway cancellation process. This event can only occur before the key is delivered. |
delivered | DELIVERED | When key is delivered to the buyer. |
returned | RETURNED | When the user returned the key before seeing it. The user has 24 hours to do so, during which they receive a refund, and the key returns to the seller's offer stock to be resold in a subsequent order. |
outofstock | OUT_OF_STOCK | When a reservation is in the BOUGHT status and the key could not be delivered from the seller's offer stock. Upon receiving this event, the seller should deliver the key. Failure to deliver the key within the specified time results in the offer being blocked. |
refunded | REFUNDED | When the user receives a refund after lodging a complaint about the key. A complaint indicates that the user has viewed the key, therefore the key cannot be returned to the seller's offer stock. |
reversed | REVERSED | When payment for the order was reversed. |
processingpreorder | PROCESSING_PREORDER | When a reservation for pre-order product is in the BOUGHT status. The webhook informs, that the key needs to be delivered at the time of game release. Failure to provide the key on the game's release date results in the outofstock webhook being sent. |
offerblocked | OFFER_BLOCKED | When the offer is blocked. The block reason is visible under the block field and the blocked date under the blockedAt field. |
chatmessage | When the customer sends a message to the ingame-product chat | |
orderprocessing | When the customer creates an order that will enter the processing status |
For webhooks related to reservation status (reserve, give, cancel, delivered, returned, outofstock, refunded, reversed, processingpreorder) the body structure remains consistent, with the status field corresponding to the reservation status as outlined in the table above.
{
"name": "Testowe CD Key",
"price": {
"amount":2,
"currency":"EUR"
},
"priceIWTR": {
"amount":2,
"currency":"EUR"
},
"commissionRule": {"fixedAmount":0,"percentValue":0.0,"ruleName":"Zero"},
"productId": "${PRODUCT_ID}",
"offerId": "${OFFER_ID}",
"status": "BUYING",
"reservationId": "${RESERVATION_ID}",
"availableStock": 0,
"buyableStock": 0,
"declaredStock": 1,
"reservedStock": 1,
"requestedKeyType": null,
"updatedAt": "2020-03-06T15:58:49.088+0000",
"popularityBid":{
"amount": 0,
"currency": "EUR"
}
}
The body structure of offerblocked webhook corresponds to the offer structure, similar to the response structure obtained when querying offer details.
The body structure of chatmessage webhook
{
"senderName": "name",
"message": "test message",
"createdAt": "2020-03-06T15:58:49.088+0000"
}
The body structure of orderprocessing webhook
{
"orderId": "123",
"productId": "321",
"qtyOrdered": "20"
}
Merchants utilizing the declared stock approach can review the history of webhooks sent to them under the designated endpoint: **See detailed documentation
curl -X GET \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
https://gateway.kinguin.net/envoy2/api/v1/requests
The body of the webhook that was sent is visible as a string in the request.toSent.body field, while the reservation ID is specified in the request.toSent.bodyId field. The number of webhook send attempts is visible in the request.deployAttempts field.
Purchase Initiation
Delivery process
Complaint Handling
Upload to the offer’s stock
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"body": "cd key", "mimeType": "text/plain"}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}/stock
Upload to the reservation. You can use this field always when you want to fully control how keys are distributed across all orders.
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"body": "cd key", "mimeType": "text/plain", "reservationId": ${RESERVATION_ID}}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}/stock
Offers on our platform may encounter situations necessitating temporary or permanent blocking due to various reasons. To address these diverse scenarios comprehensively, our system incorporates multiple types of blocks. Blocks rare categorized as follows:
Automatic Blocks These blocks are automatically set during offer creation and are related to the type of product for which the offer is created. Admin-Set Blocks Blocks manually set by Kinguin administrators. Sales-Related Blocks Blocks associated with offer sales, such as blocks due to reported issues with the offer or undelivered keys.
Block on an offer is reflected in the block field within the offer response. Below, we provide an example JSON snippet illustrating an offer along with the block field.
{
"id": "65d36ed879c2842175958bb2",
"name": "XBOX Game Pass Core 3 Months Subscription Card",
"status": "ACTIVE",
"block": "MANUAL_VERIFICATION_PREPAID_PRODUCT",
...
}
Description of automatic blocks that requires manual verification by our Customer Support:
Block | Condition to block the offer |
---|---|
MANUAL_VERIFICATION_SOFTWARE_PRODUCT | The offer is a Software product |
MANUAL_VERIFICATION_PREPAID_PRODUCT | The offer is a Prepaid product |
MANUAL_VERIFICATION_RANDOM_PRODUCT | The offer is a Random product |
MANUAL_VERIFICATION_INDIE_VALLEY_PRODUCT | The offer can be blocked for selling and needs verification |
MANUAL_VERIFICATION_NFT_PRODUCT | The offer is a NFT product |
TOO_MANY_REPORTS_24H_CNT | Too many key reports for the offer |
TOO_MANY_REPORTS_PERCENTAGE_24H_CNT | Too many key reports for the offer |
MERCHANT_ACCOUNT_BLOCKED | The merchant's account has been blocked |
STOCK_NOT_UPLOADED | At least one key was not delivered with the order within 19 minutes of payment. Please note that this issue applies only to merchants integrated via API, who have declared stock for the offer |
In our system, there is no hard delete option available for offers. To deactivate an offer, you must set its status to INACTIVE.
**See detailed documentation
curl -i -X PATCH \
-H "Authorization: Bearer ${BEARER}" \
-H "Content-Type: application/json" \
-d '{"status": "INACTIVE"}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}
Returns Buyers may return a key and receive an immediate refund only if they haven't claimed the key. In such cases, a returned webhook is sent after the buyer's action.
Complaints In case a buyer has concerns or issues regarding a purchased key, they have the option to open a report. This action initiates the creation of a case in the Resolution Center, where the seller and the buyer can work towards resolving the matter between themselves or escalate it to the customer support team if necessary. In the merchant panel, this functionality can be accessed through the Customer Support tab -> Resolution Center.
Offers can be configured to be sold wholesale. There are four tiers available, each offering decreasing prices based on the quantity of keys purchased: Level 1: 0 to 10 pcs Level 2: Above 10 to 20 pcs Level 3: Above 20 to 50 pcs Level 4: Above 50 pcs
To enable an offer for wholesale, its enabled field must be set to true and sell tiers need to be defined (level + discount that represents a percentage discount off the offer's IWTR price).
**See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{
"productId": "${PRODUCT_ID}",
"price": {"amount": 200, "currency": "EUR"},
"wholesale": {
"enabled": true,
"name": "custom",
"tiers": [
{"level": 1,"discount": 3},
{"level": 2,"discount": 4},
{"level": 3,"discount": 5},
{"level": 4,"discount": 7}
]
}
}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers
response
{
"id": "660691850f65d000010da229",
[ ... ]
"priceIWTR": {
"amount": 200,
"currency": "EUR"
},
"price": {
"amount": 230,
"currency": "EUR"
},
"wholesale": {
"name": "custom",
"enabled": true,
"tiers": [
{
"discount": 3,
"level": 1,
"price": {
"amount": 206,
"currency": "EUR"
},
"priceIWTR": {
"amount": 194,
"currency": "EUR"
}
},
{
"discount": 4,
"level": 2,
"price": {
"amount": 196,
"currency": "EUR"
},
"priceIWTR": {
"amount": 192,
"currency": "EUR"
}
},
{
"discount": 5,
"level": 3,
"price": {
"amount": 192,
"currency": "EUR"
},
"priceIWTR": {
"amount": 190,
"currency": "EUR"
}
},
{
"discount": 7,
"level": 4,
"price": {
"amount": 186,
"currency": "EUR"
},
"priceIWTR": {
"amount": 186,
"currency": "EUR"
}
}
]
},
[ ... ]
}
To disable wholesale for offer, please set wholesale enabled attibute to false:
**See detailed documentation
curl -i -X PATCH \
-H "Authorization: Bearer ${BEARER}" \
-H "Content-Type: application/json" \
-d '{"wholesale":{"enabled":false,"name":"dontSell"}}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}
📌 Notes on wholesale:
Pre-orders are special products with a predetermined release date specified in advance. These products typically include 'PRE-ORDER' in their name. Upon purchase of such an offer, the processingpreorder webhook is sent to the seller. When the release date is reached, the sold keys must be promptly delivered.
Pre-purchase offers are a type of offer that can be created for any product that is not a pre-order. This offer allows setting a maximum delivery date by which the seller commits to deliver the keys.
To create such an offer, simply include the maxDeliveryDate field in the request.
**See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"productId": "${PRODUCT_ID}", "price": {"amount": 2, "currency": "EUR", "maxDeliveryDate":"2025-08-30"}}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers
📌 Notes on pre-purchase:
The Smart Pricing Assistant (SPA) is a feature designed to empower merchants by automating the process of adjusting offer prices. With SPA, merchants can optimize their pricing strategies effortlessly, ensuring competitiveness and profitability. This chapter provides an in-depth look into the main features and processes of the SPA tool, along with examples of how to use it effectively.
Automated Price Adjustments SPA allows merchants to automate the adjustment of their offer prices based on predefined criteria. By utilizing the provided APIs, merchants can set specific conditions under which prices should be modified. SPA then continuously monitors these conditions and applies the necessary price changes, freeing merchants from the manual price adjustment process.
Precise Control Merchants have full control over the price adjustment parameters. These parameters include:
Real-time Updates SPA operates in real-time, ensuring that price adjustments are promptly applied whenever the predefined conditions are met. This guarantees that merchants remain competitive and responsive to market dynamics without delays.
The Smart Pricing Assistant (SPA) operates on a sophisticated logic designed to optimize the position of a merchant's offer on Kinguin. SPA's primary objective is to enhance the competitiveness and profitability of the merchant by automating price adjustments based on market conditions. The key pricing principles of SPA are outlined below.
Competitive Positioning SPA aims to position the merchant's offer as competitively as possible. It achieves this by pricing the offer just 0,01 Euro below the competing offer.
Outbidding Competitive Price If a competitive offer is found, SPA will automatically reduce the price of the offer to be 0.01 Euro lower than the competitive price, as long as this reduction still falls within the minimum price set by the user.
No Outbidding Competitive Price If the minimum price set by the user is higher than the found competitive offer but lower than the current user price, SPA will increase the user's price by 0,01 Euro to make it 1 cent lower than the offer that is one position below. This adjustment is made to maintain the current offer position while obtaining a higher price for it.
Best Possible Position SPA always strives to secure the best available position for the merchant's offer. However, this positioning is subject to certain constraints: the key cost and the minimum profit amount defined by the merchant.
Flexibility If the merchant's offer cannot attain the first position due to higher key costs or minimum profit requirements, SPA adjusts the offer's price to be 0.01 Euro below the next available position. This flexibility ensures that the offer remains competitive while adhering to the merchant's pricing strategy.
Activating SPA for Offers SPA can be activated on a single offer up to 5 times per day. To activate the Smart Pricing Assistant for a specific offer, the following API call can be used: **See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '[{"offerId":"63e21a36814762653336ba8f","keyCost":300,"minProfitAmount":40,"minPriceIWTR":{"amount":340,"currency":"EUR"}, "maxProfitAmount":90}]' \
https://gateway.kinguin.net/pizzaportal/api/v1/spa/offers
Request allows to activate SPA in more than 1 offer at the time (array of offers in a body request). Once activated, SPA will automatically adjust the offer's price based on the defined criteria. Detailed description of the body request:
Field name | Description |
---|---|
keyCost | Cost per key (euro cents) |
minProfitAmount | The minimum profit per key (euro cents) |
minPriceIWTR * {amount, currency} | the minimum amount that can be obtained for a key in euro cents (IWTR - I Want To Receive - the net price that the seller will receive) *optional field - if not provided it will be calculated from the formula keyCost + minProfitAmount |
maxProfitAmount * | the maximum profit per key (euro cents) *optional field - if not provided it will be calculated by the system, field is required if maxPriceIWTR provided |
maxPriceIWTR * {amount, currency} | the maximum amount that can be obtained for a key in euro cents (IWTR - I Want To Receive - the net price that the seller will receive) *optional field - if not provided it will be calculated from the formula keyCost + maxProfitAmount |
Updating Minimum Price
Merchants can update the minimum price, key cost, and minimum profit amount for an offer with the following API call:
curl -X PUT \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"minPriceIWTR":{"amount":344,"currency":"EUR"},"keyCost":300,"minProfitAmount":44}' \
https://gateway.kinguin.net/pizzaportal/api/v1/spa/offers/${OFFER_ID}
This API call allows merchants to modify the price adjustment parameters, thereby influencing SPA's automated pricing decisions.
Detailed description of the body request:
Field name | Description |
---|---|
keyCost | Cost per key (euro cents) |
minProfitAmount | The minimum profit per key (euro cents) |
minPriceIWTR * {amount, currency} | the minimum amount that can be obtained for a key in euro cents (IWTR - I Want To Receive - the net price that the seller will receive) *optional field - if not provided it will be calculated from the formula keyCost + minProfitAmount |
maxProfitAmount * | the maximum profit per key (euro cents) *optional field - if not provided it will be calculated by the system, field is required if maxPriceIWTR provided |
maxPriceIWTR * {amount, currency} | the maximum amount that can be obtained for a key in euro cents (IWTR - I Want To Receive - the net price that the seller will receive) *optional field - if not provided it will be calculated from the formula keyCost + maxProfitAmount |
Deactivating SPA for an Offer
To deactivate SPA for a specific offer, merchants can use the following API call:
curl -X DELETE \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
https://gateway.kinguin.net/pizzaportal/api/v1/spa/offers/deactivate/${OFFER_ID}"
Smart Pricing Assistant operates based on a set of internal states that determine whether the functionality is actively managing the offer’s price. There are three possible SPA statuses: ACTIVE – SPA is actively running and updating the offer's price. PAUSED – SPA is temporarily not running when the offer becomes non-buyable (e.g., inactive status, no stock, or the offer is blocked). INACTIVE – SPA is disabled for the offer.
SPA Activation Rules:
Automatic Status Transitions:
Manual Deactivation:
SPA Billing Exclusion: Offers that remain non-buyable and PAUSED for the entire billing period are excluded from the weekly Smart Pricing Assistant fee calculation.
The SPA bot automatically adjusts prices in response to several actions that occur on offers of a specific product.
Price Decrease
Price Increase
SPA Bot Trigger
Fees Related to the Use of Smart Pricing Assistant (SPA) Functionality Fees for using the Smart Pricing Assistant (SPA) functionality are charged once a week based on the number of offers on which the SPA functionality was active during the previous week.
When is the SPA functionality considered active? The SPA functionality is considered active when:
Fee Collection Schedule The fee is charged once a week, every Monday at 00:00 UTC.
Fee Structure Fees for using the SPA functionality are charged according to the following tier structure, depending on the number of offers where the functionality was active:
Tier | Number of offers where SPA was active | Price |
---|---|---|
TIER 1 | 0 - 5 | 0 € |
TIER 2 | 6 - 100 | 24,99 € |
TIER 3 | 101 - 8 000 | 37,99 € |
TIER 4 | more than 8 000 | 62,99 € |
Examples
Scenario 1:
Scenario 2:
Scenario 3:
📌 Notes on SPA pricing:
Sales Booster is an innovative tool tailored for merchants who seek enhanced visibility on the Kinguin’s product page buy button despite price-related limitations. This chapter delves into the key features and processes of the Sales Booster, demonstrating how merchants can strategically leverage this tool to increase their presence and boost sales on the platform.
Visibility Enhancement Sales Booster is designed to give merchants an opportunity to stand out on Kinguin, even when they can't compete purely on price. By utilizing the provided endpoints, merchants can strategically bid for better positioning on the buy button, allowing them to catch the attention of potential customers.
Strategic Bidding Merchants have the flexibility to place bids for improved positioning based on their marketing strategy and budget. This enables them to allocate resources effectively to enhance their offer’s visibility.
Requesting Visibility Boost
To enhance the visibility of an offer using the Sales Booster, merchants can send a POST request to the following endpoint:
**See detailed documentation
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"maxBid": 10, "salesBoosterRenewal": true}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/{OFFER_ID}/popularity
This API call allows merchants to strategically place bids to improve their offer's visibility on the buy button. The offer ID should be replaced with the corresponding offer's identifier.
Checking Position and Bid Impact
Merchants can assess the potential impact of their bid on their offer's position using the following GET request:
curl -X GET \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/{OFFER_ID}/position?bid={BID}&price={PRICE}
This API call provides merchants with insights into how their offer's position would change based on the specified bid and price parameters. It's a valuable tool to make informed decisions regarding bid amounts.
Besides selling keys on Kinguin, there is also the option to sell Steam accounts. To unlock this possibility, please contact your account manager. For such products, the product page displays the following information for the buyer: This is not a product key. A NEW ACCOUNT will be created for you, and the purchased content will be available there.
Kinguin platform supports the listing and sale of in-game products, including items and in-game currency. These products cater to gamers who wish to buy or sell virtual goods directly related to specific games. To begin selling in-game products, you must first contact your account manager to unlock this feature on your account.
The purchase and delivery workflow for offers on our platform involves several steps, primarily involving manual actions on the Kinguin site. Here’s a detailed overview of the process:
1. Order Payment and Notification
2. Creating a Communication Channel
3. Proof of Delivery
4. Order Closure
This process ensures that each transaction is handled with transparency and efficiency, facilitating effective communication between buyers and sellers and ensuring that products are delivered as promised.
Create an in-game offer To create an offer, you need to send a request with specific required parameters for in-game goods.
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{
"productId": "66d8320d77a097501e74a356",
"price": {
"amount": 200, // price for the quantity specified in minQuantity
"currency": "EUR"
},
"declaredStock": 999999999,
"status": "ACTIVE",
"deliveryMethods": [
"FACE_TO_FACE"
],
"minQuantity": 1000, // the price field corresponds to this quantity
"description": "Short description.",
"deliveryTime": "2h"
}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers
Detailed description of the body request:
Field name | Type / Allowed values | Description |
---|---|---|
productId | String | ID of an existing product for which the offer is to be created |
price {amount, currency} | price: Long (max: 1000000), currency: "EUR" | The price IWTR for purchasing the keys in the quantity specified by minQuantity (always in cents and EUR) |
declaredStock | Integer (max: 999999999) | The quantity of items the seller is able to deliver |
status | "ACTIVE" / "INACTIVE" | Status of the offer |
deliveryMethods | ["FACE_TO_FACE", "GUILD_BANK", "EMAIL", "AUCTION_HOUSE"] | Possible delivery methods |
minQuantity | Integer | Minimum order amount. The price field corresponds to this quantity |
description | String (max 2000 chars) | The description of the offer |
deliveryTime | "1h" / "2h" / "3h" / "4h" / "5h" / "6h" / "7h" / "8h" / "9h" / "10h" / "11h" / "12h" | The time within which the seller is able to deliver the purchased products |
Update an in-game offer
curl -i -X PATCH \
-H "Authorization: Bearer ${BEARER}" \
-H "Content-Type: application/json" \
-d '{"declaredStock": 1000000}' \
https://gateway.kinguin.net/sales-manager-api/api/v1/offers/${OFFER_ID}
To create a sandbox account, proceed with the same steps like for production, using https://sandbox.kinguin.net.
To use API sandbox endpoints please use https://gateway.sandbox.kinguin.net e.g.
curl -X POST \
-H "Authorization: Bearer ${TOKEN}" \
-H "Content-Type: application/json" \
-d '{"productId": "${PRODUCT_ID}", "price": {"amount": 2, "currency": "EUR"}}' \
https://gateway.sandbox.kinguin.net/sales-manager-api/api/v1/offers
Follow the guide below to implement and configure checkout SDK on your website and start accepting payments via our checkout flow. The SDK automatically detects user's device and browser and starts the checkout flow in an iframe if supported or in a new browser window if not.
If you would like to implement this SDK on your website, please contact us to discuss the details.
Content-Security-Policy: frame-src https://www.kinguin.net;
The SDK might be occasionally updated to provide the best possible experience. To ensure that you are using the latest version and all functionalities work properly, please use the script URL provided in this documentation. You will be informed by our team in case a new version is released.
To use the SDK on your website, you need to include the following script tag in the head section of your HTML document:
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Example HTML< /title>
<script defer src="https://static.kinguin.net/checkout/sdk/sdk-1.2.0.min.js">< /script>
</head>
The defer attribute ensures that the script is loaded and executed after the HTML document has been parsed, preventing potential rendering issues.
Once your products are visible and ready to be selected, you should initialize the SDK using the function below, which will add click handlers to the product elements and handle opening the iframe or new browser window upon selection.
To initialize the SDK, use the function below:
window.kinguinCheckoutSDK.init();
In the HTML example below, the SDK is initialized after DOM content has loaded.
<body>
<script>
document.addEventListener('DOMContentLoaded', function () {
window.kinguinCheckoutSDK.init();
});
< /script>
</body>
Please remember that you must initialize the SDK once all of your product elements are already in the DOM, as otherwise the event handlers will not be added.
You can customize some of the options by passing a config object to the init function. The available options are listed below:
Option | Default Value | Type | Description |
---|---|---|---|
wrapperSelector | "#kinguinIframeWrapper" | string | CSS selector for the wrapper element where the iframe will be injected. |
productsSelector | ".productElement" | string | CSS selector for elements representing products that will trigger the checkout flow upon selection. |
productUrlAttribute | "data-product" | string | Attribute name on product elements that contains the URL to the product page in our store. |
apmId | empty string | string | Payment method ID from Kinguin. If provided, only this payment method will be available to the customer. If the method is invalid or inactive on Kinguin, the customer will not be able to make a purchase. It can also be passed manually as a query parameter in the productUrlAttribute value (e.g. https://www.kinguin.net/category/12345?apmid=methodIdFromKinguin). Please contact with our team for the desired method ID or keep it empty to show all available payment methods to the customer. |
iframeId | "kinguinCheckoutIframe" | string | ID attribute for the injected iframe element. |
iframeWidth | "100%" | string | Width of the iframe. |
iframeHeight | "900px" | string | Height of the iframe. |
popupWidth | 800 | number | Width of the popup window in pixels when opening in a new window. |
popupHeight | 900 | number | Height of the popup window in pixels when opening in a new window. |
translations | { popupOpenFail: 'Failed to open popup. Please try again.' } | object | Object containing messages which can be translated to the language currently used on your website. |
discount | empty string | string | Kinguin discount code to be applied automatically on checkout. |
language | empty string | string | Language which will be used on our checkout. Leave empty to automatically apply language based on user's browser and country. The allowed values are: en, pl, it, fr, de, pt, br, tr, es, cs, cn. |
currency | empty string | string | Currency which will be used on our checkout. Leave empty to automatically apply language based on user's country. The value must be a valid ISO 4217 code, eg: EUR, USD, PLN, etc. |
empty string | string | Customer email which will be automatically used in our checkout flow. |
Example initialization with provided configuration object:
window.kinguinCheckoutSDK.init({
wrapperSelector: '#myIframeWrapper',
productsSelector: '.myProductElement',
productUrlAttribute: 'data-product-url',
iframeId: 'myCheckoutIframe',
iframeWidth: '80%',
iframeHeight: '700px',
popupWidth: 900,
popupHeight: 1000,
translations: {
popupOpenFail: 'Window could not be opened, please try again.',
},
discount: 'test123',
language: 'de',
currency: 'USD',
email: 'test@test.com'
});
You can also pass fewer options instead of the whole object:
window.kinguinCheckoutSDK.init({
wrapperSelector: '#myIframeWrapper',
productsSelector: '.myProductElement',
productUrlAttribute: 'data-product-url',
currency: 'USD',
});
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Example HTML< /title>
<script
defer
src="https://static.kinguin.net/checkout/sdk/sdk-1.2.0.min.js"
>< /script>
</head>
<body>
<div id="kinguinIframeWrapper"></div>
<div
class="productCard"
data-product="https://www.kinguin.net/category/12345"
>
Product 1
</div>
<div
class="productCard"
data-product="https://www.kinguin.net/category/67890"
>
Product 2
</div>
<script>
document.addEventListener('DOMContentLoaded', function () {
window.kinguinCheckoutSDK.init({
productsSelector: '.productCard',
});
});
< /script>
</body>
</html>