Overview
GET
/friends/requestsfriendsPending friend requests — ?direction=received (default, the caller's inbox) | sent
List requests.
Auth: bearerAuth — calls run as the authenticated user.
Parameters
- directionquery · optional"received" | "sent"
- pagequery · optionalstring
- pageSizequery · optionalstring
Responses
200
A page of pending friend requests, newest first
- itemsFriendship[]
- totalinteger
- pageinteger
- pageSizeinteger
Example
{
"items": [
{
"id": "string",
"ecosystemId": "string",
"requesterId": "string",
"addresseeId": "string",
"status": "pending",
"createdAt": "string",
"updatedAt": "string"
}
],
"total": 0,
"page": 0,
"pageSize": 0
}400
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}401
Error
- erroroptionalobject
Example
{
"error": {
"message": "string",
"code": "string"
}
}Code examples
cURL
curl -X GET "https://api.agenticdeveloperhub.com/friends/requests" \
-H "Authorization: Bearer YOUR_TOKEN"JavaScript
const res = await fetch("https://api.agenticdeveloperhub.com/friends/requests", {
method: "GET",
headers: {
"Authorization": "Bearer YOUR_TOKEN"
},
});
const data = await res.json();