subscribe_intent
Subscribe to buyer intents for specific categories with optional budget and region filters. Receive notifications for matches, then use associated tools to view and respond with quotes.
Instructions
订阅特定品类的买家意图。有匹配意图时收到通知。用 get_incoming_intents 查看匹配到的意图,用 respond_to_intent 报价。
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| category_l1 | Yes | 一级品类(必填) | |
| category_l2 | No | 二级品类 | |
| min_budget | No | 最低预算过滤 | |
| max_budget | No | 最高预算过滤 | |
| regions | No | 地区过滤 |
Implementation Reference
- src/index.ts:987-990 (handler)The tool handler for subscribe_intent: parses input via SubscribeIntentSchema and calls the client's subscribeIntent method.
case 'subscribe_intent': { const p = S.SubscribeIntentSchema.parse(args); result = await client.subscribeIntent(p); break; - src/schemas.ts:112-118 (schema)Zod schema for subscribe_intent input validation. category_l1 is required; category_l2, min_budget, max_budget, and regions are optional.
export const SubscribeIntentSchema = z.object({ category_l1: z.string().min(1, 'category_l1 为必填项'), category_l2: z.string().optional(), min_budget: z.number().nonnegative().optional(), max_budget: z.number().positive().optional(), regions: z.string().optional(), }); - src/index.ts:594-609 (registration)Tool registration entry for subscribe_intent in the tools array, defining its name, description, and input JSON schema.
// ═══ 卖家 — 意图订阅 ═══ { name: 'subscribe_intent', description: '订阅特定品类的买家意图。有匹配意图时收到通知。用 get_incoming_intents 查看匹配到的意图,用 respond_to_intent 报价。', inputSchema: { type: 'object' as const, properties: { category_l1: { type: 'string', description: '一级品类(必填)' }, category_l2: { type: 'string', description: '二级品类' }, min_budget: { type: 'number', description: '最低预算过滤' }, max_budget: { type: 'number', description: '最高预算过滤' }, regions: { type: 'string', description: '地区过滤' }, }, required: ['category_l1'], }, }, - src/acap-client.ts:330-336 (helper)Client helper method that sends a POST request to /acap/v1/subscriptions with the subscription criteria.
async subscribeIntent(criteria: { category_l1?: string; category_l2?: string; min_budget?: number; max_budget?: number; regions?: string; notify_channel?: string; }) { return this.request('POST', '/acap/v1/subscriptions', criteria); } - src/index.ts:143-146 (registration)Tool grouped under 'subscription' category in the tool grouping configuration.
subscription: [ 'subscribe_intent', 'unsubscribe_intent', 'list_subscriptions', 'get_incoming_intents', ],