cURL
curl -X GET \
/user/api-tokens \
--header "Authorization: Bearer <token>"import requests
url = "https://coreapi.io/user/api-tokens"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://coreapi.io/user/api-tokens', 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://coreapi.io/user/api-tokens",
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;
}{
"data": [
{
"id": "A1B2C3D4E5F6G7H8I9J0",
"description": "My API token",
"expiresAt": "2021-01-01T00:00:00+00:00",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00",
"apiToken": "**********"
}
],
"meta": {
"pagination": {
"totalItems": 123,
"itemsPerPage": 123,
"currentPage": 123,
"lastPage": 123,
"pageTotalItems": 123
}
}
}Api Tokens
Get all api tokens
Get all api tokens
Required permissions:user:api-token:readGET
/
user
/
api-tokens
cURL
curl -X GET \
/user/api-tokens \
--header "Authorization: Bearer <token>"import requests
url = "https://coreapi.io/user/api-tokens"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://coreapi.io/user/api-tokens', 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://coreapi.io/user/api-tokens",
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;
}{
"data": [
{
"id": "A1B2C3D4E5F6G7H8I9J0",
"description": "My API token",
"expiresAt": "2021-01-01T00:00:00+00:00",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00",
"apiToken": "**********"
}
],
"meta": {
"pagination": {
"totalItems": 123,
"itemsPerPage": 123,
"currentPage": 123,
"lastPage": 123,
"pageTotalItems": 123
}
}
}Autorisierungen
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Abfrageparameter
The collection page number
The number of items per page
Erforderlicher Bereich:
0 <= x <= 100War diese Seite hilfreich?
⌘I