Confidential clients authenticate via the client credentials flow (i.e. client secret or certificate), user IDs are not involved. If you are indeed authenticating via client credentials, and thus running in the application context, you need additional permissions in order to access any given mailbox. In particular, the Mail.Read or Mail.ReadBasic application permission would do.
The URL seems fine, assuming you're passing the correct user ID. This should be the UPN of your user or its GUID. You cannot use other values, such as any of the email addresses assigned, unless it matches the UPN.