Hi Andrew Earl,
Thank you for reaching out to Microsoft!
When attempting to retrieve shared mailbox folders via the Graph API, it's necessary to share a specific folder from Outlook. While it's possible to share the Inbox and other folders, such as Sent Items, with other users through delegated access, the AllItems folder is not shared. This is the folder that is accessed via the endpoint users/******@company.com/messages, which may be causing the error you're encountering.
To retrieve all emails from a user's mailbox with a single API call, you can use Application permissions with the GET /users/{id | userPrincipalName}/messages/ endpoint. This enables you to access all emails in the user's mailbox through one API request.
Please ensure the application is granted the following permission to access messages: Mail.ReadBasic.All, Mail.Read
Documentation reference: https://learn.microsoft.com/en-us/graph/api/message-get?view=graph-rest-1.0&tabs=http
If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.