Problem
The Bitrix24 REST API methods im.recent.* (recent chats list, pinning, read/unread) are not yet supported by the SDK. See https://apidocs.bitrix24.com/api-reference/chats/index.html.
Proposed solution
Add a new service src/Services/IM/Recent/Service/Recent.php that wraps the following REST methods, following patterns in other src/Services/<Scope>/ folders. Scope: im.
Methods to implement
Acceptance criteria
Part of #422.
Problem
The Bitrix24 REST API methods
im.recent.*(recent chats list, pinning, read/unread) are not yet supported by the SDK. See https://apidocs.bitrix24.com/api-reference/chats/index.html.Proposed solution
Add a new service
src/Services/IM/Recent/Service/Recent.phpthat wraps the following REST methods, following patterns in othersrc/Services/<Scope>/folders. Scope:im.Methods to implement
im.recent.get— list the user's recent chatsim.recent.hide— hide a dialog from the listim.recent.list— list recent dialogs with paginationim.recent.pin— pin/unpin a dialogim.recent.unread— toggle the "read" mark on a chatAcceptance criteria
Bitrix24\SDK\Services\IM\Recent\Service\Recentimplements each method with correct parameter mapping and#[ApiEndpointMetadata]/#[ApiServiceMetadata(new Scope(['im']))]attributesIMServiceBuilder::recent()exposes the new serviceRecentItemResultwith@property-readannotations covers all fields returned byim.recent.list/im.recent.gettests/Unit/Services/IM/Recent/Service/RecentTest.phppass (make test-unit)tests/Integration/Services/IM/Recent/Service/RecentTest.phppasstests/Integration/Services/IM/Recent/Result/RecentItemResultTest.phppasses (annotation completeness + type-cast checks)make test-integration-im-recenttarget added toMakefileand a suite added tophpunit.xml.distCHANGELOG.mdentry under## 3.2.0 – UNRELEASED→### Addedwith link to this issuePart of #422.