curl -X GET 'https://api.weir.ai/talent?page=1&limit=20' \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-H 'x-source: console'
{
"data": {
"talents": [
{
"talentId": "talent_123456789",
"fullname": "John Athlete",
"email": "[email protected]",
"status": "active",
"verified": true,
"createdAt": "2024-01-15T10:30:00Z"
}
],
"pagination": {
"page": 1,
"limit": 20,
"total": 50,
"totalPages": 3
}
},
"message": "Talent list retrieved successfully",
"status": "success"
}
Retrieve list of all talent
curl -X GET 'https://api.weir.ai/talent?page=1&limit=20' \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-H 'x-source: console'
{
"data": {
"talents": [
{
"talentId": "talent_123456789",
"fullname": "John Athlete",
"email": "[email protected]",
"status": "active",
"verified": true,
"createdAt": "2024-01-15T10:30:00Z"
}
],
"pagination": {
"page": 1,
"limit": 20,
"total": 50,
"totalPages": 3
}
},
"message": "Talent list retrieved successfully",
"status": "success"
}
curl -X GET 'https://api.weir.ai/talent?page=1&limit=20' \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-H 'x-source: console'
{
"data": {
"talents": [
{
"talentId": "talent_123456789",
"fullname": "John Athlete",
"email": "[email protected]",
"status": "active",
"verified": true,
"createdAt": "2024-01-15T10:30:00Z"
}
],
"pagination": {
"page": 1,
"limit": 20,
"total": 50,
"totalPages": 3
}
},
"message": "Talent list retrieved successfully",
"status": "success"
}
const getTalent = async (page, limit, accessToken) => {
const response = await fetch(`https://api.weir.ai/talent?page=${page}&limit=${limit}`, {
headers: {
'Authorization': `Bearer ${accessToken}`,
'x-source': 'console'
}
});
if (!response.ok) throw new Error(`HTTP error! status: ${response.status}`);
return await response.json();
};
Was this page helpful?