openclaw 网盘下载
OpenClaw

技能详情(站内镜像,无评论)

首页 > 技能库 > ShipStation Orders

Monitor ShipStation orders, detect issues, and send alerts. For e-commerce businesses using ShipStation for order fulfillment across multiple platforms (Amaz...

开发与 DevOps

作者:Chris Price @cprice70

许可证:MIT-0

MIT-0 ·免费使用、修改和重新分发。无需归因。

版本:v1.1.0

统计:⭐ 0 · 438 · 1 current installs · 1 all-time installs

0

安装量(当前) 1

🛡 VirusTotal :良性 · OpenClaw :良性

Package:shipstation-orders

安全扫描(ClawHub)

  • VirusTotal :良性
  • OpenClaw :良性

OpenClaw 评估

The skill's code, instructions, and required credentials are consistent with a ShipStation order-monitoring tool and do not request unrelated access or contact unknown endpoints.

目的

The name/description match what the files implement: polling ShipStation orders, detecting conditions (stuck, on-hold, expedited), and writing local state. The required env vars (SHIPSTATION_API_KEY, SHIPSTATION_API_SECRET) and node runtime are appropriate for this purpose.

说明范围

SKILL.md and the scripts instruct the agent to read a local .env, call ShipStation's API, and write local state files (state.json, shipping-state.json). There are no instructions to read unrelated system files, exfiltrate data to third-party endpoints, or access other credentials.

安装机制

No install spec is provided (instruction-only), but the package includes JS scripts. This is coherent: the skill expects node to be available and runs local scripts. Note: Node version compatibility (global fetch used) may require a recent Node (v18+) but that's an operational, not a security, issue.

证书

Only ShipStation API credentials are requested and used. The code loads .env from the skill directory and also checks process.env in one script; it does not request or access unrelated secrets or service credentials.

持久

The skill writes/reads its own local state files to track processed orders. It does not request elevated or system-wide privileges, does not modify other skills/configs, and is not configured with always:true.

综合结论

This skill appears to do exactly what it says: poll ShipStation and flag order issues. Before installing: (1) Only provide ShipStation API key/secret — do not reuse high-privilege keys from other services. (2) Keep the .env file out of version control (SKILL.md advises adding it to .gitignore). (3) Expect local state files (state.json, shipping-state.json) to be created in the skill directory; they contain processed order IDs but not credentia…

安装(复制给龙虾 AI)

将下方整段复制到龙虾中文库对话中,由龙虾按 SKILL.md 完成安装。

请把本段交给龙虾中文库(龙虾 AI)执行:为本机安装 OpenClaw 技能「ShipStation Orders」。简介:Monitor ShipStation orders, detect issues, and send alerts. For e-commerce busi…。
请 fetch 以下地址读取 SKILL.md 并按文档完成安装:https://raw.githubusercontent.com/openclaw/skills/refs/heads/main/skills/cprice70/shipstation-orders/SKILL.md
(来源:yingzhi8.cn 技能库)

SKILL.md

打开原始 SKILL.md(GitHub raw)

---
name: shipstation-orders
description: Monitor ShipStation orders, detect issues, and send alerts. For e-commerce businesses using ShipStation for order fulfillment across multiple platforms (Amazon, Etsy, Shopify, TikTok, etc.).
metadata:
  {
    "openclaw": {
      "requires": { 
        "bins": ["node"],
        "env": ["SHIPSTATION_API_KEY", "SHIPSTATION_API_SECRET"]
      }
    }
  }
---

# ShipStation Order Monitor

Monitor ShipStation for new orders and issues. Perfect for e-commerce businesses using ShipStation to aggregate orders from multiple marketplaces.

## Features

- ✅ New order notifications
- ⚠️ Alert for orders stuck in processing (>48h)
- 🛑 Flag orders on hold
- 🚚 Immediate alert for expedited/2-day/priority orders
- 📊 Daily summary reports
- 🔄 Automatic state tracking (avoids duplicate alerts)

## Requirements

- ShipStation account with API access
- Node.js (included with OpenClaw)

## Setup

### 1. Get ShipStation API Credentials

1. Log into ShipStation
2. Go to **Settings** → **Account** → **API Settings**
3. Use **Legacy API** (V1) - generate API Key + API Secret

### 2. Configure Credentials

Create `.env` file in your workspace:

```bash
SHIPSTATION_API_KEY=your_api_key_here
SHIPSTATION_API_SECRET=your_api_secret_here
```

### 3. Test the Monitor

```bash
node check-orders.js
```

Output shows:
- Total orders in last 24h
- New orders detected
- Any alerts

Exit codes:
- `0` - Success, no alerts
- `1` - Success, alerts found
- `2` - Error (API failure, bad credentials)

### 4. Set Up Heartbeat Monitoring (Optional)

Add to your agent's `HEARTBEAT.md`:

```markdown
## Check Orders

Every 15 minutes:

1. Run: `node check-orders.js`
2. Parse results
3. If new orders or alerts → notify via sessions_send
4. If nothing → HEARTBEAT_OK
```

Or use a cron job for scheduled checks.

## Usage

### Manual Check

```bash
node check-orders.js
```

### In Agent Heartbeat

```javascript
const { exec } = require('child_process');

exec('node check-orders.js', (error, stdout, stderr) => {
  const results = JSON.parse(stdout);
  
  if (results.newOrdersList.length > 0) {
    // Notify about new orders
  }
  
  if (results.alerts.length > 0) {
    // Notify about issues
  }
});
```

## Alert Conditions

**New Orders:**
- Any order in `awaiting_shipment` or `awaiting_payment` status

**Issues Flagged:**
- Orders awaiting shipment > 48 hours
- Orders on hold (payment verification, address issues, etc.)

**API Errors:**
- Authentication failures
- Rate limit exceeded
- Network issues

## State Management

The script maintains `state.json` to track:
- Last check timestamp
- Processed order IDs (prevents duplicate alerts)
- Pending alerts
- Inventory warnings (future feature)

State file auto-prunes to last 1000 orders.

## Customization

Edit `check-orders.js` to adjust:

**Alert Thresholds:**
```javascript
// Line ~70: Change from 48 hours to 24 hours
if (order.orderStatus === 'awaiting_shipment' && ageHours > 24) {
```

**Time Window:**
```javascript
// Line ~60: Change from 24 hours to 12 hours
const yesterday = new Date(Date.now() - 12 * 60 * 60 * 1000).toISOString();
```

**Additional Checks:**
Add custom logic for your business needs (high-value orders, specific products, etc.)

## API Reference

Uses [ShipStation API V1](https://www.shipstation.com/docs/api/)

**Rate Limits:**
- 40 requests per minute
- Script uses 1 request per check

**Key Endpoints Used:**
- `GET /orders?modifyDateStart={date}&pageSize=100`

## Troubleshooting

**Error: "API credentials not configured"**
- Check `.env` file exists in same directory
- Verify credentials don't contain placeholder text

**Error: "ShipStation API error: 401"**
- Credentials are incorrect
- Regenerate API key in ShipStation

**Error: "ShipStation API error: 429"**
- Rate limit exceeded
- Reduce check frequency

**No new orders detected but they exist:**
- Check `modifyDateStart` window (default: 24h)
- Verify orders have been modified recently in ShipStation
- Check `state.json` - might already be processed

## Files

- `check-orders.js` - Main order monitoring script
- `check-shipping.js` - Expedited shipping alert monitor
- `state.json` - Auto-generated order state tracking
- `shipping-state.json` - Auto-generated shipping state tracking
- `.env` - Your credentials (add to .gitignore!)

## License

MIT

## Author

Built for [OpenClaw](https://openclaw.ai) multi-agent systems.