Get current user
curl --request GET \
--url https://api.4casters.io/user/getMe \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.4casters.io/user/getMe"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.4casters.io/user/getMe', 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://api.4casters.io/user/getMe",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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://api.4casters.io/user/getMe"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.4casters.io/user/getMe")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.4casters.io/user/getMe")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"user": {
"id": "<string>",
"username": "<string>",
"displayBalance": 123,
"creditLimit": 123,
"liability": 123,
"commissionCharged": 123,
"maxLiability": 123,
"matchedVolume": {},
"openInterest": {},
"isAdmin": true,
"hasMarketMakerAccess": true,
"isPro": true,
"isDeposit": true,
"isAlphaUser": true,
"sportsbookDefault": true,
"defaultRotationNumbers": true,
"displayRotationNumbers": true,
"viewOddsWithCommission": true,
"defaultExpiry": 123,
"defaultOffer": 123,
"defaultSendOrderMessage": true,
"sportsbookMinimumDisplay": 123,
"showChatLastMessage": true,
"yesNoSummary": true,
"accessCode": "<string>",
"code": "<string>",
"p2pCode": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"emailConfirmation": true
}
}
}User
Get current user
Read the authenticated account
GET
/
user
/
getMe
Get current user
curl --request GET \
--url https://api.4casters.io/user/getMe \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.4casters.io/user/getMe"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.4casters.io/user/getMe', 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://api.4casters.io/user/getMe",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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://api.4casters.io/user/getMe"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.4casters.io/user/getMe")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.4casters.io/user/getMe")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"user": {
"id": "<string>",
"username": "<string>",
"displayBalance": 123,
"creditLimit": 123,
"liability": 123,
"commissionCharged": 123,
"maxLiability": 123,
"matchedVolume": {},
"openInterest": {},
"isAdmin": true,
"hasMarketMakerAccess": true,
"isPro": true,
"isDeposit": true,
"isAlphaUser": true,
"sportsbookDefault": true,
"defaultRotationNumbers": true,
"displayRotationNumbers": true,
"viewOddsWithCommission": true,
"defaultExpiry": 123,
"defaultOffer": 123,
"defaultSendOrderMessage": true,
"sportsbookMinimumDisplay": 123,
"showChatLastMessage": true,
"yesNoSummary": true,
"accessCode": "<string>",
"code": "<string>",
"p2pCode": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"emailConfirmation": true
}
}
}Returns the currently-authenticated user’s account information including balance, credit limit, current liability, default odds format, and access flags.
Request
GET /user/getMe
This endpoint takes no parameters. Authentication is required (see Authentication).
curl https://api.4casters.io/user/getMe \
-H "Authorization: Bearer YOUR_TOKEN"
Response
object
Show data
Show data
object
Show user
Show user
string
User id.
string
Account username.
string
Account type —
free, p2p, marketmaker, or agent.string
Default odds format.
american or decimal.number
Current balance (display value).
number
Credit limit (negative for credit accounts).
number
Current open liability across all games.
number
Commission rate charged to this account.
number
Account-level cap on liability.
boolean
Whether the account can access market-maker features.
boolean
boolean
boolean
boolean
integer
Default order expiry, in minutes.
null for “no default”.number
Default offer size when placing orders.
boolean
number
boolean
boolean
boolean
boolean
boolean
boolean
string
Sign-up code on the account.
string
If this is a P2P agent account, the code their referrals use at sign-up.
string
ISO 8601 account-creation timestamp.
boolean
Whether the account’s email is confirmed.
Example
{
"data": {
"user": {
"id": "5fe37acbb5a23600123662c1",
"username": "your_username",
"type": "p2p",
"oddsFormat": "american",
"displayBalance": 1250.50,
"creditLimit": 500,
"liability": -125.00,
"commissionCharged": 0.01,
"hasMarketMakerAccess": false,
"isAdmin": false,
"isPro": false,
"createdAt": "2020-12-23T17:14:09.000Z",
"emailConfirmation": true
}
}
}
Was this page helpful?
⌘I