Bug
gmail.get extracts only Subject, From, To and Date when format is metadata or full, and silently discards Cc, Bcc and Reply-To. Callers cannot see who a message was copied to without falling back to format: "raw" and decoding the RFC 822 payload themselves.
This is easy to mistake for ground truth: the response simply has no cc field, so a consumer (human or LLM) concludes the email had no CC recipients. In my case this produced a confidently wrong "this email was not CCed to X" determination that only format: "raw" disproved.
Cause
workspace-server/src/services/GmailService.ts (the get handler):
const subject = getHeader('Subject');
const from = getHeader('From');
const to = getHeader('To');
const date = getHeader('Date');
No Cc/Bcc/Reply-To extraction, and the response object only includes the four fields above.
Secondary nit: getHeader matches header names case-sensitively (h.name === name), but header names are case-insensitive per RFC 5322.
Expected
metadata and full responses include cc, bcc and replyTo when those headers are present on the message.
Fix
PR incoming: adds the three headers (omitted from the JSON when absent, preserving current response shape otherwise), makes header matching case-insensitive, and adds tests for present/absent/case-variant headers.
Bug
gmail.getextracts onlySubject,From,ToandDatewhenformatismetadataorfull, and silently discardsCc,BccandReply-To. Callers cannot see who a message was copied to without falling back toformat: "raw"and decoding the RFC 822 payload themselves.This is easy to mistake for ground truth: the response simply has no
ccfield, so a consumer (human or LLM) concludes the email had no CC recipients. In my case this produced a confidently wrong "this email was not CCed to X" determination that onlyformat: "raw"disproved.Cause
workspace-server/src/services/GmailService.ts(thegethandler):No
Cc/Bcc/Reply-Toextraction, and the response object only includes the four fields above.Secondary nit:
getHeadermatches header names case-sensitively (h.name === name), but header names are case-insensitive per RFC 5322.Expected
metadataandfullresponses includecc,bccandreplyTowhen those headers are present on the message.Fix
PR incoming: adds the three headers (omitted from the JSON when absent, preserving current response shape otherwise), makes header matching case-insensitive, and adds tests for present/absent/case-variant headers.