List sent friend requests
Read friend requests sent by the current account.
getFriendApplicationListAsApplicant() queries friend applications sent by the current account and returns OpenIMFriendApplicationListResult or null.
Parameters
The parameter object can be omitted. To request an explicit page, use:
| Parameter | Type | Required | Description |
|---|---|---|---|
offset | number or null | No | Pagination offset; use 0 for the first page. |
count | number or null | No | Number of applications requested. |
import { getFriendApplicationListAsApplicant } from '@/uni_modules/unix-openim-sdk'
const result = await getFriendApplicationListAsApplicant({ offset: 0, count: 50 })
renderSentApplications(result?.applications ?? [])After Promise success, applications contains the current page of sent OpenIMFriendApplicationItem[]. See Get received friend applications for the fields. This query does not trigger an application event.
Pagination can change while it is loading. Merge events by fromUserID:toUserID instead of array position. If an event arrives during paging, reset pagination and requery when necessary. Complete friend-application listeners live on the received-applications page. Rebuild this snapshot after App restoration, re-login, or any period in which events may have been missed.
Was this page helpful?