Get User Profile API
Retrieve the details and current wallet balance of the authenticated user.
Get User Details
Fetch your profile and balance using your API key.
GET
https://accessvtu.com.ng/api/user
curl -X GET "https://accessvtu.com.ng/api/user" \
-H "Authorization: Token YOUR_API_KEY" \
-H "Content-Type: application/json"
<?php
$url = 'https://accessvtu.com.ng/api/user';
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Token YOUR_API_KEY',
'Content-Type: application/json',
]
]);
$response = curl_exec($ch);
curl_close($ch);
print_r(json_decode($response, true));
?>
Response
✓ 200 OK
{
"status": "success",
"wallet": "5000",
"balance": "5000",
"user": {
"id": 1,
"name": "John Doe",
"email": "johndoe@example.com",
"phone": "08012345678",
"wallet": "5000.00",
"type": "Reseller"
}
}