实时活动授权

Live Activity Skill

让智能助手把取餐码和提醒放上灵动岛

Create iPhone Live Activities from your AI assistant

上岛记实时活动授权支持取餐码、取件码、瑞幸 MCP、天气早报和提醒。外部工具只需要提交业务字段,内部实时活动内容由服务端维护。

The PinToIsland Live Activity Skill works with compatible AI assistants to create pickup-code activities, courier-code activities, Luckin order activities, weather briefings, and reminders. It sends business fields only.

适合做什么

What It Handles

取餐码 Pickup Codes

把餐号、店名、商品名放到手机实时活动和灵动岛。

Show the pickup code, store name, and product name in Live Activity and Dynamic Island.

提醒 Reminders

让智能助手按时间创建天气早报、日程出发、喝水吃药等简短提醒;标题默认使用纯文本,emoji 图标单独放在 noteIcon,避免重复显示。

Ask your assistant to create weather briefings, departure reminders, hydration or medication reminders. Titles use plain text by default, with the emoji stored separately in noteIcon to avoid duplication.

瑞幸 MCP Luckin MCP

接入瑞幸 MCP 后,可把瑞幸取餐信息映射成上岛记实时活动。

With a Luckin MCP, pickup details can be mapped into PinToIsland.

Codex 插件安装

Install For Codex

适合在 Codex 里通过插件市场安装。

Use the GitHub marketplace flow to install the plugin in Codex.

命令行 Terminal
codex plugin marketplace add wulonglin/shangdaoji-live-activity
codex plugin add shangdaoji-live-activity@pintoisland

通用能力包安装

Install As A Skill

其他兼容能力包的智能助手可以使用源码仓库,或下载这个轻量能力包。

Other compatible AI assistants can use the GitHub repository or download this small skill package.

命令行 Terminal
mkdir -p ~/.codex/skills
curl -L https://shangdaoji.com/agent.skill.zip -o /tmp/shangdaoji-live-activity.skill.zip
unzip -o /tmp/shangdaoji-live-activity.skill.zip -d ~/.codex/skills

应用配置

App Setup

1

在应用商店下载上岛记,打开应用,完成登录,并允许通知和实时活动。

Download PinToIsland from the App Store, open the app, sign in, and allow notifications and Live Activities.

2

进入设置页,打开 智能助手授权。首次使用先点 重新生成授权,之后可直接点 复制授权指令

Open settings and choose AI Assistant Authorization. Tap Regenerate Authorization once, then use Copy Authorization Instructions.

3

把复制出的授权指令发给兼容的智能助手,让它保存其中的 p2ia_... 令牌。

Paste the copied authorization instructions into a compatible AI assistant and ask it to save the p2ia_... token.

快捷指令与自动化

Shortcuts And Automation

快捷指令、自动化平台或脚本不需要安装能力包。只要能发请求、设置授权头和请求体,就能调用同一个接口。

Shortcuts, n8n, Make, Zapier, or scripts do not need the skill package. If they can send POST requests with an Authorization header and a JSON body, they can use the same API.

请求示例 HTTP Example
curl -X POST "https://wulonglin.xyz/api/agent_activity.php" \
  -H "Authorization: Bearer <p2ia_token>" \
  -H "Content-Type: application/json" \
  -d '{"type":"meal","pickup_code":"A123"}'

使用示例

Examples

保存授权 Save Token

请保存这个上岛记实时活动令牌:<粘贴授权指令>

Save this PinToIsland Live Activity token: <paste authorization instructions>

创建取餐码 Create Pickup Code

用上岛记创建一个取餐码 A123,店名瑞幸咖啡。

Use PinToIsland to create pickup code A123 for Luckin Coffee.

创建提醒 Create Reminder

用上岛记提醒我 13:30 出发去滨江会议室,图标用 🚕。

Use PinToIsland to remind me at 13:30 to leave for the Binjiang meeting room with the 🚕 icon.

更新实时活动 Update Live Activity

把上岛记实时活动 123 更新为取餐码 B456,店名瑞幸咖啡。

Update PinToIsland Live Activity 123 to pickup code B456 for Luckin Coffee.

天气早报 Weather Briefing

每天早上 7:30 用上岛记给我发天气早报,包含温度、降雨概率和穿衣建议。

Use PinToIsland at 7:30 every morning for a weather briefing with temperature, rain chance, and outfit advice.