Springboot Notification Module Skill logo

Springboot Notification Module Skill

Community
jiushiwon
springboot-notification-module-skill

Spring Boot 通知模块技能。面向已有 Spring Boot 项目的开发者,提供短信发送、邮件推送、站内消息、推送通知等能力的快速集成。触发词:"短信验证码"、"发送短信"、"发送邮件"、"站内消息"、"通知模块"、"notification module"、"sms"、"email"、"mail"。

Overview

Publisherjiushiwon
Repositorywg-skills
Skill namespringboot-notification-module-skill
Stars
123
Forks
38
Bundled files
1
LicenseApache-2.0
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 1 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by jiushiwon on GitHub. Read the source before you install it.

Installation

Install the Springboot Notification Module Skill AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/jiushiwon/wg-skills/tree/main/vibeCoding/backend/java/springboot-module/springboot-notification-module-skill
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/jiushiwon/wg-skills.git /tmp/wg-skills
mkdir -p .claude/skills
cp -r /tmp/wg-skills/vibeCoding/backend/java/springboot-module/springboot-notification-module-skill .claude/skills/springboot-notification-module-skill
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Springboot Notification Module Skill in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Springboot Notification Module Skill on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Springboot Notification Module Skill is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Spring Notification Module Skill

面向已有 Spring Boot 项目的开发者,快速集成通知能力。

能力清单

能力说明
短信发送验证码/通知短信
邮件推送HTML/文本邮件/模板邮件
站内消息系统通知/未读消息
推送通知极光/信鸽/个推
消息模板模板管理和渲染

触发场景

用户说"帮我加短信"或"集成通知"时触发。

核心实现

依赖配置

xml
<!-- 短信 -->
<dependency>
    <groupId>com.aliyun</groupId>
    <artifactId>dysmsapi20170525</artifactId>
</dependency>

<!-- 邮件 -->
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-mail</artifactId>
</dependency>

<!-- 站内消息 -->
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-data-redis</artifactId>
</dependency>

配置

yaml
# 短信配置
sms:
  aliyun:
    access-key: ${SMS_ACCESS_KEY:}
    secret-key: ${SMS_SECRET_KEY:}
    sign-name: ${SMS_SIGN_NAME:}
    template-code: ${SMS_TEMPLATE_CODE:}

# 邮件配置
spring:
  mail:
    host: ${MAIL_HOST:smtp.qq.com}
    port: 587
    username: ${MAIL_USERNAME:}
    password: ${MAIL_PASSWORD:}
    properties:
      mail:
        smtp:
          auth: true
          starttls:
            enable: true

# 站内消息配置
notification:
  redis-key-prefix: notification:

实体类

java
// 站内消息
@Entity
@Table(name = "wg_notification")
public class Notification {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;
    
    private String userId;
    
    private String title;
    
    @Column(columnDefinition = "text")
    private String content;
    
    @Enumerated(EnumType.STRING)
    private NotificationType type;
    
    private String link;
    
    private Integer isRead;
    
    private LocalDateTime createdAt;
}

public enum NotificationType { SYSTEM, SMS, EMAIL, PUSH }

@Entity
@Table(name = "wg_sms_code")
public class SmsCode {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;
    
    private String phone;
    
    private String code;
    
    private String templateCode;
    
    private LocalDateTime expireTime;
    
    private Integer used;
    
    private LocalDateTime createdAt;
}

服务层

java
@Service
public class NotificationService {
    
    @Autowired
    private SmsTemplate smsTemplate;
    
    @Autowired
    private SpringMailSender mailSender;
    
    @Autowired
    private NotificationRepository notificationRepository;
    
    // 发送短信验证码
    public void sendSmsCode(String phone, String templateCode) {
        String code = generateCode(6);
        
        // 调用短信API
        SendSmsRequest request = new SendSmsRequest()
            .setPhoneNumbers(phone)
            .setSignName("您的签名")
            .setTemplateCode(templateCode)
            .setTemplateParam("{\"code\":\"" + code + "\"}");
        smsTemplate.send(request);
        
        // 保存验证码
        SmsCode smsCode = new SmsCode();
        smsCode.setPhone(phone);
        smsCode.setCode(code);
        smsCode.setTemplateCode(templateCode);
        smsCode.setExpireTime(LocalDateTime.now().plusMinutes(5));
        smsCodeRepository.save(smsCode);
    }
    
    // 发送邮件
    public void sendEmail(String to, String subject, String content) {
        SimpleMailMessage message = new SimpleMailMessage();
        message.setFrom("noreply@example.com");
        message.setTo(to);
        message.setSubject(subject);
        message.setText(content);
        mailSender.send(message);
    }
    
    // 发送站内消息
    public void sendNotification(String userId, String title, String content, NotificationType type) {
        Notification notification = new Notification();
        notification.setUserId(userId);
        notification.setTitle(title);
        notification.setContent(content);
        notification.setType(type);
        notification.setIsRead(0);
        notification.setCreatedAt(LocalDateTime.now());
        notificationRepository.save(notification);
        
        // Redis 推送
        redisTemplate.convertAndSend("notification:" + userId, notification);
    }
}

Controller

java
@RestController
@RequestMapping("/api/notification")
public class NotificationController {
    
    @Autowired
    private NotificationService notificationService;
    
    // 发送短信验证码
    @PostMapping("/sms/send")
    public ApiResponse<Void> sendSms(@RequestParam String phone) {
        notificationService.sendSmsCode(phone, "SMS_123456789");
        return ApiResponse.ok(null);
    }
    
    // 验证短信验证码
    @PostMapping("/sms/verify")
    public ApiResponse<Boolean> verifySms(@RequestParam String phone, @RequestParam String code) {
        boolean valid = notificationService.verifySmsCode(phone, code);
        return ApiResponse.ok(valid);
    }
    
    // 发送邮件
    @PostMapping("/email/send")
    public ApiResponse<Void> sendEmail(@RequestBody SendEmailRequest request) {
        notificationService.sendEmail(request.getTo(), request.getSubject(), request.getContent());
        return ApiResponse.ok(null);
    }
    
    // 发送站内消息
    @PostMapping("/send")
    public ApiResponse<Void> sendNotification(@RequestBody SendNotificationRequest request) {
        notificationService.sendNotification(
            request.getUserId(),
            request.getTitle(),
            request.getContent(),
            NotificationType.valueOf(request.getType())
        );
        return ApiResponse.ok(null);
    }
    
    // 查询未读消息
    @GetMapping("/unread")
    public ApiResponse<List<Notification>> getUnread(@RequestParam String userId) {
        List<Notification> list = notificationService.getUnreadNotifications(userId);
        return ApiResponse.ok(list);
    }
}

不做

  • 不负责短信/邮件服务商账号配置
  • 不处理复杂的推送策略
  • 不提供 UI 相关代码

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Springboot Notification Module Skill AI skill do?

Spring Boot 通知模块技能。面向已有 Spring Boot 项目的开发者,提供短信发送、邮件推送、站内消息、推送通知等能力的快速集成。触发词:"短信验证码"、"发送短信"、"发送邮件"、"站内消息"、"通知模块"、"notification module"、"sms"、"email"、"mail"。

Why use Springboot Notification Module Skill on TypingMind?

Because you install it once and use it with any model. Springboot Notification Module Skill is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Springboot Notification Module Skill in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/jiushiwon/wg-skills/tree/main/vibeCoding/backend/java/springboot-module/springboot-notification-module-skill. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Springboot Notification Module Skill?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Springboot Notification Module Skill?

As many as you like. As long as a model supports skills, you can use Springboot Notification Module Skill with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Springboot Notification Module Skill AI skill free?

Yes. It is published on GitHub by jiushiwon under the Apache-2.0 license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇