New command: teams callrecord get. Closes #6738#6851
Conversation
|
Thanks Martin, we'll try to review it soon. |
|
@MartinM85, could you align this PR with the latest version of Zod? This will improve the review process. |
19876fe to
6d1b8be
Compare
Rebased with the main. |
There was a problem hiding this comment.
Pull request overview
This pull request adds a new command teams callrecord get to retrieve detailed information about a specific Microsoft Teams call record using the Microsoft Graph API. The implementation follows the established codebase patterns for application-only commands and includes comprehensive test coverage and documentation.
Changes:
- New command implementation for retrieving Teams call records by ID with expanded session and participant data
- Test suite with validation tests, success scenarios, and error handling
- Documentation page with usage examples and important remarks about the 30-day retention limit
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/m365/teams/commands/callrecord/callrecord-get.ts | Implements the new command that retrieves call records with two API calls to expand both sessions/segments and participants_v2 |
| src/m365/teams/commands/callrecord/callrecord-get.spec.ts | Comprehensive test suite covering validation, successful retrieval, and error handling scenarios |
| src/m365/teams/commands.ts | Adds the new CALLRECORD_GET command constant to the commands registry |
| docs/src/config/sidebars.ts | Adds the new command to the documentation sidebar navigation |
| docs/docs/cmd/teams/callrecord/callrecord-get.mdx | Complete documentation page with usage, options, examples, and response formats |
| npm-shrinkwrap.json | Contains unrelated changes adding "peer": true flags to several packages |
Files not reviewed (1)
- npm-shrinkwrap.json: Language not supported
milanholemans
left a comment
There was a problem hiding this comment.
Nice work Martin! During review I had a few remarks we should take a look at first.
6d1b8be to
e0124f8
Compare
|
|
||
| it('handles random API error', async () => { | ||
| const errorMessage = 'Could not find the requested call record. Records about calls or online meetings that started more than 30 days ago are not available.'; | ||
| sinon.stub(request, 'get').rejects(new Error(errorMessage)); |
There was a problem hiding this comment.
The structure of this error does not match the structure that the Graph API throws. Usually, the error message is wrapped into an error object like:
{
"error": {
"message": "Error occurred."
}
}
Closes #6738