Get the tokens for a customerID. These can be onchain tokens, allowances or db tokens
curl --request GET \
--url https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}import requests
url = "https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}")
.asString();require 'uri'
require 'net/http'
url = URI("https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"isError": "0",
"Error": "",
"Data": {
"Tokens": [
{
"Total": 80.62,
"TokenSymbol": "BOLT",
"Guid": "5E5B9042-FA98-CBBE-9C92-E42F13FD8EBE",
"Name": "Bolts",
"Image": "https://...",
"Details": [
{
"Wallet": "0x2FEA74160714A5Cbc556A24fAe5cCa5F29a05000",
"Amount": "80.62",
"ChainName": "Ethereum",
"ContractGuid": "0x24BD97449b970421F2597071697FfC782F93d0AA",
"IsAllowance": false
}
]
}
]
}
}Player Endpoints
Tokens
GET
/
Tokens
/
{YourAPIKEY}
/
{ProjectGuid}
/
{CustomerID}
Get the tokens for a customerID. These can be onchain tokens, allowances or db tokens
curl --request GET \
--url https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}import requests
url = "https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}")
.asString();require 'uri'
require 'net/http'
url = URI("https://intern.payingame.io/rest/PayIngame/PublicAPI/Tokens/{YourAPIKEY}/{ProjectGuid}/{CustomerID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"isError": "0",
"Error": "",
"Data": {
"Tokens": [
{
"Total": 80.62,
"TokenSymbol": "BOLT",
"Guid": "5E5B9042-FA98-CBBE-9C92-E42F13FD8EBE",
"Name": "Bolts",
"Image": "https://...",
"Details": [
{
"Wallet": "0x2FEA74160714A5Cbc556A24fAe5cCa5F29a05000",
"Amount": "80.62",
"ChainName": "Ethereum",
"ContractGuid": "0x24BD97449b970421F2597071697FfC782F93d0AA",
"IsAllowance": false
}
]
}
]
}
}Get the tokens that a user has. The total amount as well as the details will be shown. It will contain the tokens onchain, allowance and db tokens.
⌘I