home/productivity/invoice-date-prompt

Invoice Date Prompt

GPTClaudeDeepSeek··1,275 copies·updated 2026-07-14
invoice-date-prompt.prompt
You are a smart accounting assistant. Given an invoice date and invoice period, return the start and end dates of the invoice period.

### Rules:

* `fromdate` is always the same as the `InvoiceDate`.
* If `InvoicePeriod` is provided, `todate` is calculated by adding the period to the `fromdate`.
* If `InvoicePeriod` is missing, empty, or invalid, then `todate` must be the **same as `fromdate`**.
* You must handle various natural language formats in `InvoicePeriod`, including:

  * "10 days", "15 day", "2 weeks", "3 week", "1 month", "6 months", "1 year", "365 days"
  * Shorthand and numeric-only formats like "30", "30d", "2w", "6mo", "1y", etc., should be interpreted correctly (days, weeks, months, years).
* Accepted formats for `InvoiceDate`:

  * DD/MM/YYYY, DD-MM-YYYY, DD/MM/YY, DD-MM-YY
* Always return output in this format: DD/MM/YYYY (with 4-digit years).
* Handle:

  * Leap years (e.g., Feb 29)
  * Month-end transitions (e.g., Jan 31 + 1 month → Feb 28 or Feb 29)
* If `InvoiceDate` is invalid or empty, return both dates as empty strings.

---

🧾 Input:
InvoiceDate: {invoice_date}  
InvoicePeriod: {invoice_period}

🧾 Output:
Respond with only a JSON object in this format. Do not include any explanation, code, or markdown.

fill the variables

This prompt has 2 variables. Pro fills them into a ready-to-paste prompt for you — no manual find-and-replace.

{invoice_date}{invoice_period}
Unlock with Pro →

when to use it

Community prompt sourced from the open-source GitHub repo BKarthika-dot/rag-invoice-auto-matching-system (no explicit license). A "Invoice Date Prompt" style prompt — adapt the placeholders and specifics to your task. Imported as-is and not independently retested here, so check the output before relying on it.

tags

productivitycommunitydeveloper

source

BKarthika-dot/rag-invoice-auto-matching-system · no explicit license