FreeFireMerchantTopup
Last Updated 11th May, 2025
The FreeFireMerchantTopup mutation allows merchant clients to top up Free Fire Diamonds using their merchant key. It deducts the merchant's balance and query count, validates the product, and logs the transaction.
π‘ Merchant accounts benefit from discounted pricing β products are charged at 80% of the usual retail price.
π Endpoint URL: https://api.vscgames.com/graphql Method: POST Content-Type: application/json
π Mutation Structure
mutation FreeFireMerchantTopup($productId: String!, $playerID: String!) {
FreeFireMerchantTopup(productId: $productId, playerID: $playerID) {
code
message
orderId
playerID
player_name
productId
name
amount
status
timestamp
}
}
π Parameters
productId
String
Yes
ID of the Free Fire top-up product
playerID
String
Yes
Player ID to receive the top-up
β Successful Response
{
"data": {
"FreeFireMerchantTopup": {
"code": 200,
"message": "Top-up placed successfully",
"orderId": "FFM123456",
"playerID": "2265245647",
"player_name": "JJ_MUCH",
"productId": "1",
"name": "Free Fire 110 Diamonds",
"amount": 1.28,
"status": "pending",
"timestamp": "2025-05-11T12:00:00Z"
}
}
}
π« Error Codes
401
Merchant key required
Missing or invalid merchant header
403
Invalid merchant key
Merchant not found
402
Insufficient merchant query balance
Merchant has 0 remaining query credits
404
Top-up product not found
The product ID is not valid
503
Topup failed
Internal operation failed to process
500
Transaction not found
No record matched after placement
πͺ Code Examples Python
import requests
url = "https://api.vscgames.com/graphql"
headers = {"Content-Type": "application/json", "merchantkey": "YOUR_MERCHANT_KEY"}
query = """
mutation FreeFireMerchantTopup($productId: String!, $playerID: String!) {
FreeFireMerchantTopup(productId: $productId, playerID: $playerID) {
code
message
orderId
playerID
player_name
productId
name
amount
status
timestamp
}
}
"""
variables = {
"productId": "1",
"playerID": "2265245647"
}
response = requests.post(url, json={"query": query, "variables": variables}, headers=headers)
print(response.json())
JavaScript
const fetch = require("node-fetch");
const query = `
mutation FreeFireMerchantTopup($productId: String!, $playerID: String!) {
FreeFireMerchantTopup(productId: $productId, playerID: $playerID) {
code
message
orderId
playerID
player_name
productId
name
amount
status
timestamp
}
}`;
const variables = {
productId: "1",
playerID: "2265245647"
};
fetch("https://api.vscgames.com/graphql", {
method: "POST",
headers: {
"Content-Type": "application/json",
"merchantkey": "YOUR_MERCHANT_KEY"
},
body: JSON.stringify({ query, variables })
})
.then(res => res.json())
.then(data => console.log(data));
Last updated