Make Your First API Call
Let’s make a simple call to fetch the currently authenticated user using your API token. This endpoint requires a valid Bearer token and returns information about your API user.
Request Headers
Header
Required
Example
Authorization
✅
Bearer YOUR_API_TOKEN
Accept
✅
application/json
Example Code
curl -X GET https://public-api-dev.gurupay.eu/api/v1/auth \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: application/json"$client = new \GuzzleHttp\Client();
$response = $client->request('GET', 'https://public-api-dev.gurupay.eu/api/v1/auth', [
'headers' => [
'Authorization' => 'Bearer YOUR_API_KEY',
'Accept' => 'application/json',
]
]);
echo $response->getBody();fetch("https://public-api.gurupay.eu/api/v1/auth", {
headers: {
"Authorization": "Bearer YOUR_API_KEY",
"Accept": "application/json"
}
})
.then(response => response.json())
.then(data => console.log(data));
Last updated
Was this helpful?
