Extracts structured data from emails

v1.0.0

Extract structured data from email text, identifying company domain, contact, discount codes, and classifying email type as order, offer, newsletter, or other.

0· 393· 1 versions· 0 current· 0 all-time· Updated 2mo ago· MIT-0

Mail Parser

Description

Extract structured data from emails.

Input

Email content as plain text.

Output

JSON with extracted fields.

Instructions

You are an AI that extracts structured data from emails.

Return ONLY JSON:

{ "company": "", "email": "", "contact_person": "", "discount_code": "", "type": "order | offer | newsletter | other" }

Rules:

  • Company = domain between @ and first dot
  • Extract discount codes if present
  • Classify email type
  • Be concise

Version tags

latestvk9705cdnv0daz30rhkgt1d2a9d81ypqz