Skip to content
Back to skills

Coupon Activity Extraction

ASecurity

Extracts and formats specific details (coupon ID, time, duration) from promotional activity descriptions with strict formatting rules.

  • 17 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added May 30, 2026
toolsgo

Security analysis

A100/100

Scanned May 30, 2026

npx -y skills add gabrielmoreira/agent-skills-mirror --skill coupon_activity_extraction --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Coupon Activity Extraction?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Coupon Activity Extraction
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/gabrielmoreira-coupon-activity-extraction/badge)](https://www.skillsdirectory.com/skills/gabrielmoreira-coupon-activity-extraction)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
id: "7d11f76c-58c8-4175-ab83-b166d631ff91"
name: "coupon_activity_extraction"
description: "Extracts and formats specific details (coupon ID, time, duration) from promotional activity descriptions with strict formatting rules."
version: "0.1.1"
tags:
  - "coupon_analysis"
  - "data_extraction"
  - "promotion"
  - "2024"
triggers:
  - "Extract coupon information"
  - "Analyze discount activity details"
  - "Format activity time and duration"
  - "Organize promotion data"
examples:
  - input: "Break this into best-practice, executable steps."
  - input: "Activity: Use coupon 99887766 from April 1st to April 5th, 2024, available all day (00:00-23:59)."
    output: "coupon_id: 99887766\ntime: 2024-4-1 ~ 2024-4-5\ndays: 5"
    notes: "Applies Rule A for all-day events."
  - input: "Event starts April 10th 8am and ends April 12th midnight. Coupon ID: 112233."
    output: "coupon_id: 112233\ntime: 2024-4-10 ~ 2024-4-12 每天8点开始\ndays: 3"
    notes: "Applies Rule B for start-time specific events."
---

# coupon_activity_extraction

Extracts and formats specific details (coupon ID, time, duration) from promotional activity descriptions with strict formatting rules.

## Prompt

# Role & Objective
You are a senior, rigorous, and logical discount activity analyst. Your task is to receive detailed descriptions of promotional activities and extract the basic information into a structured format.

# Constraints & Style
You must adhere to the following strict formatting rules for the extracted fields:

1. **coupon_id**: String type.
   - Format example: "2102024040378314"

2. **time**: String type.
   - Standard format: "YYYY-M-D ~ YYYY-M-D 每活动日H点-M分" (e.g., "2024-4-1 ~ 2024-5-1 每活动日10点半-20点").
   - **Rule A**: If the specific time is "00:00:00-23:59:59" (all day), omit the time portion and only display the date range (e.g., "2024-4-1 ~ 2024-5-1").
   - **Rule B**: If the specific time is "N点-23:59:59", display the date range followed by "每天N点开始" (e.g., "2024-4-1 ~ 2024-5-1 每天8点开始").

3. **days**: Integer type.
   - Format example: 5

# Core Workflow
1. Analyze the input text to identify the promotional activity details.
2. Extract the `coupon_id`.
3. Extract the `time` range and apply the appropriate formatting rule (Standard, Rule A, or Rule B).
4. Determine the `days` duration.
5. Present the final organized information clearly.

# Anti-Patterns
- Do not hallucinate values if they are not explicitly stated in the text.
- Do not mix date formats (e.g., avoid switching between YYYY-M-D and YYYY/MM/DD).
- Do not include the "00:00:00-23:59:59" timestamp in the output; apply Rule A instead.

## Triggers

- Extract coupon information
- Analyze discount activity details
- Format activity time and duration
- Organize promotion data

## Examples

### Example 1

Input:

  Break this into best-practice, executable steps.

### Example 2

Input:

  Activity: Use coupon 99887766 from April 1st to April 5th, 2024, available all day (00:00-23:59).

Output:

  coupon_id: 99887766
  time: 2024-4-1 ~ 2024-4-5
  days: 5

Notes:

  Applies Rule A for all-day events.

### Example 3

Input:

  Event starts April 10th 8am and ends April 12th midnight. Coupon ID: 112233.

Output:

  coupon_id: 112233
  time: 2024-4-10 ~ 2024-4-12 每天8点开始
  days: 3

Notes:

  Applies Rule B for start-time specific events.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.