SDKsReact NativeEnterprise
Delete friend requests
Batch remove friend request historical records from the application list using the OpenIM React Native SDK.
Batch remove friend application records from the local history list:
await OpenIMSDK.deleteFriendRequests([
{ fromUserID, toUserID },
]);Parameters
Accepts an array of application target descriptors:
| Parameter | Type | Required | Description |
|---|---|---|---|
fromUserID | string | Yes | User ID of the applicant who initiated the friend request. |
toUserID | string | Yes | User ID of the recipient of the friend request. |
Return value
A resolved Promise confirms that the designated friend application records were deleted.
Deleting an application record does not reject the request or affect existing friendships. Deletion triggers the OnFriendApplicationDeleted event. Remove items from the local friend application list using the composite key fromUserID:toUserID. For event listeners, see Get received friend applications.
Was this page helpful?