@oneshot-agent/mcp-server 0.13.0 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/dist/index.js +1 -1
- package/dist/tools/analytics.d.ts +2 -0
- package/dist/tools/analytics.js +32 -6
- package/dist/tools/domains.js +1 -1
- package/dist/tools/email.js +7 -1
- package/dist/tools/index.js +3 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -196,6 +196,8 @@ Use oneshot_email:
|
|
|
196
196
|
- from_name: "Jane Doe" (optional display name → "Jane Doe <jane@domain>")
|
|
197
197
|
- from_mailbox: "jane" (optional local-part, defaults to "agent")
|
|
198
198
|
- from_domain: "acme.com" (optional, defaults to "oneshotagent.com")
|
|
199
|
+
- mailbox_mode: "mailbox" (optional, 'relay' (default) | 'mailbox' — dedicated per-address
|
|
200
|
+
mailbox; only when first provisioning a new from_domain)
|
|
199
201
|
```
|
|
200
202
|
|
|
201
203
|
### Make a Phone Call
|
package/dist/index.js
CHANGED
|
@@ -26,7 +26,7 @@ async function main() {
|
|
|
26
26
|
// Create MCP server
|
|
27
27
|
const server = new Server({
|
|
28
28
|
name: "oneshot-mcp",
|
|
29
|
-
version: "0.
|
|
29
|
+
version: "0.15.0", // keep in sync with package.json; guarded by version.test.ts
|
|
30
30
|
}, {
|
|
31
31
|
capabilities: {
|
|
32
32
|
tools: {},
|
|
@@ -4,7 +4,9 @@ export declare const spendBreakdownTool: Tool;
|
|
|
4
4
|
export declare const rocsTool: Tool;
|
|
5
5
|
export declare const receiptsListTool: Tool;
|
|
6
6
|
export declare const tagReceiptValueTool: Tool;
|
|
7
|
+
export declare const rocsByGoalTool: Tool;
|
|
7
8
|
export declare function handleSpendBreakdown(agent: OneShot, args: Record<string, unknown>): Promise<import("@oneshot-agent/sdk").SpendBreakdown>;
|
|
8
9
|
export declare function handleRocs(agent: OneShot, args: Record<string, unknown>): Promise<import("@oneshot-agent/sdk").RoCSResult>;
|
|
9
10
|
export declare function handleReceiptsList(agent: OneShot, args: Record<string, unknown>): Promise<import("@oneshot-agent/sdk").ReceiptsListResult>;
|
|
11
|
+
export declare function handleRocsByGoal(agent: OneShot, args: Record<string, unknown>): Promise<import("@oneshot-agent/sdk").RoCSByGoalResult>;
|
|
10
12
|
export declare function handleTagReceiptValue(agent: OneShot, args: Record<string, unknown>): Promise<void>;
|
package/dist/tools/analytics.js
CHANGED
|
@@ -35,20 +35,36 @@ export const receiptsListTool = {
|
|
|
35
35
|
};
|
|
36
36
|
export const tagReceiptValueTool = {
|
|
37
37
|
name: "oneshot_tag_receipt_value",
|
|
38
|
-
description: "Tag
|
|
39
|
-
"
|
|
38
|
+
description: "Tag business value (revenue, lead, conversion, savings, engagement) to feed RoCS. " +
|
|
39
|
+
"Address it three ways: receipt_id (rcpt_…), request_id from the original tool call, " +
|
|
40
|
+
"or goal_id — a correlation key that attributes a whole cadence's outcome (a closed deal " +
|
|
41
|
+
"across the intro email + follow-ups + find/verify/enrich calls sharing decisionContext.goalId) " +
|
|
42
|
+
"in one call. Read goal-level rollups back with oneshot_rocs_by_goal. Free.",
|
|
40
43
|
inputSchema: {
|
|
41
44
|
type: "object",
|
|
42
45
|
properties: {
|
|
43
|
-
receipt_id: { type: "string", description: "Receipt id (rcpt_…) to tag. Provide
|
|
44
|
-
request_id: { type: "string", description: "request_id/job_id from the original tool call.
|
|
45
|
-
|
|
46
|
+
receipt_id: { type: "string", description: "Receipt id (rcpt_…) to tag. Provide one of receipt_id / request_id / goal_id." },
|
|
47
|
+
request_id: { type: "string", description: "request_id/job_id from the original tool call." },
|
|
48
|
+
goal_id: { type: "string", description: "Cadence correlation key (decisionContext.goalId). Attributes the outcome to the whole group at once." },
|
|
49
|
+
type: { type: "string", description: "Value type: 'revenue', 'lead', 'conversion', 'savings', or 'engagement'" },
|
|
46
50
|
amount: { type: "number", description: "Value amount (e.g. USD)" },
|
|
47
51
|
label: { type: "string", description: "Optional human label for the value" },
|
|
48
52
|
},
|
|
49
53
|
required: ["type"],
|
|
50
54
|
},
|
|
51
55
|
};
|
|
56
|
+
export const rocsByGoalTool = {
|
|
57
|
+
name: "oneshot_rocs_by_goal",
|
|
58
|
+
description: "Per-cadence RoCS rollup: spend (receipts) vs. value (outcomes) grouped by goal_id. " +
|
|
59
|
+
"Answers 'what did this cadence cost vs. earn' in one query. Free.",
|
|
60
|
+
inputSchema: {
|
|
61
|
+
type: "object",
|
|
62
|
+
properties: {
|
|
63
|
+
period: { type: "number", description: "Lookback window in days" },
|
|
64
|
+
goal_id: { type: "string", description: "Optional — restrict the rollup to a single cadence correlation key." },
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
};
|
|
52
68
|
export async function handleSpendBreakdown(agent, args) {
|
|
53
69
|
return agent.spendBreakdown({ period: args.period });
|
|
54
70
|
}
|
|
@@ -65,8 +81,18 @@ export async function handleReceiptsList(agent, args) {
|
|
|
65
81
|
until: args.until,
|
|
66
82
|
});
|
|
67
83
|
}
|
|
84
|
+
export async function handleRocsByGoal(agent, args) {
|
|
85
|
+
return agent.rocsByGoal({
|
|
86
|
+
period: args.period,
|
|
87
|
+
goalId: args.goal_id,
|
|
88
|
+
});
|
|
89
|
+
}
|
|
68
90
|
export async function handleTagReceiptValue(agent, args) {
|
|
69
|
-
return agent.tagReceiptValue({
|
|
91
|
+
return agent.tagReceiptValue({
|
|
92
|
+
receiptId: args.receipt_id,
|
|
93
|
+
requestId: args.request_id,
|
|
94
|
+
goalId: args.goal_id,
|
|
95
|
+
}, {
|
|
70
96
|
type: args.type,
|
|
71
97
|
amount: args.amount,
|
|
72
98
|
label: args.label,
|
package/dist/tools/domains.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export const listDomainsTool = {
|
|
2
2
|
name: "oneshot_list_domains",
|
|
3
|
-
description: "List the agent's sending domains
|
|
3
|
+
description: "List the agent's sending domains. Each has default_from (canonical default sender, e.g. agent@domain — billed like any address on its first send), addresses[] (mailboxes already provisioned — {address, status, warmup_state}; empty means none yet), pool_status (rotation eligibility: active|paused|removed), warmup_state (reputation health: warming|warmed|degraded), pause_reason (warming|low_reputation|manual|null), warmup_score, and daily send limits. A domain can be paused AND warming — reputation pauses auto-recover once warmed; manual pauses need a resume. Free.",
|
|
4
4
|
inputSchema: { type: "object", properties: {} },
|
|
5
5
|
};
|
|
6
6
|
export const pauseDomainTool = {
|
package/dist/tools/email.js
CHANGED
|
@@ -26,12 +26,17 @@ export const emailTool = {
|
|
|
26
26
|
},
|
|
27
27
|
from_mailbox: {
|
|
28
28
|
type: "string",
|
|
29
|
-
description: "Sender mailbox / local-part (optional, defaults to 'agent', i.e. agent@from_domain)",
|
|
29
|
+
description: "Sender mailbox / local-part (optional, defaults to 'agent', i.e. agent@from_domain). You can use any local-part — a new address is auto-provisioned on first use (starts unwarmed, warms over time). The FIRST send from any address — including the default 'agent@' — adds a one-time mailbox_provisioning_fee to the quote; it's free only once that address is already provisioned (active). See the domains list for each domain's default_from and existing addresses.",
|
|
30
30
|
},
|
|
31
31
|
from_name: {
|
|
32
32
|
type: "string",
|
|
33
33
|
description: "Display name shown to the recipient (optional), e.g. 'Jane Doe' renders as 'Jane Doe <jane@domain>'",
|
|
34
34
|
},
|
|
35
|
+
mailbox_mode: {
|
|
36
|
+
type: "string",
|
|
37
|
+
enum: ["relay", "mailbox"],
|
|
38
|
+
description: "How this domain sends (optional, defaults to 'relay'). 'relay' = header send, no per-address mailbox, no mailbox fee. 'mailbox' = a real dedicated mailbox per address (better deliverability + per-address warmup); each new address adds a one-time mailbox_provisioning_fee to the quote. Only applies when a domain is first set up — use it on a new from_domain; an existing domain keeps the mode it was created with.",
|
|
39
|
+
},
|
|
35
40
|
attachments: {
|
|
36
41
|
type: "array",
|
|
37
42
|
items: {
|
|
@@ -58,6 +63,7 @@ export async function handleEmail(agent, args) {
|
|
|
58
63
|
from_domain: args.from_domain,
|
|
59
64
|
from_mailbox: args.from_mailbox,
|
|
60
65
|
from_name: args.from_name,
|
|
66
|
+
mailbox_mode: args.mailbox_mode,
|
|
61
67
|
attachments: args.attachments,
|
|
62
68
|
});
|
|
63
69
|
}
|
package/dist/tools/index.js
CHANGED
|
@@ -17,7 +17,7 @@ import { deepResearchPersonTool, socialProfilesTool, articleSearchTool, personNe
|
|
|
17
17
|
import { companySearchTool, enrichCompanyTool, handleCompanySearch, handleEnrichCompany } from "./company.js";
|
|
18
18
|
import { computeTool, computeStatusTool, computeTasksTool, computeCancelTool, computeRespondTool, handleCompute, handleComputeStatus, handleComputeTasks, handleComputeCancel, handleComputeRespond } from "./compute.js";
|
|
19
19
|
import { listDomainsTool, pauseDomainTool, resumeDomainTool, handleListDomains, handlePauseDomain, handleResumeDomain } from "./domains.js";
|
|
20
|
-
import { spendBreakdownTool, rocsTool, receiptsListTool, tagReceiptValueTool, handleSpendBreakdown, handleRocs, handleReceiptsList, handleTagReceiptValue } from "./analytics.js";
|
|
20
|
+
import { spendBreakdownTool, rocsTool, rocsByGoalTool, receiptsListTool, tagReceiptValueTool, handleSpendBreakdown, handleRocs, handleRocsByGoal, handleReceiptsList, handleTagReceiptValue } from "./analytics.js";
|
|
21
21
|
// All available tools
|
|
22
22
|
export const tools = [
|
|
23
23
|
// Communication
|
|
@@ -70,6 +70,7 @@ export const tools = [
|
|
|
70
70
|
// Analytics
|
|
71
71
|
spendBreakdownTool,
|
|
72
72
|
rocsTool,
|
|
73
|
+
rocsByGoalTool,
|
|
73
74
|
receiptsListTool,
|
|
74
75
|
tagReceiptValueTool,
|
|
75
76
|
// Account
|
|
@@ -129,6 +130,7 @@ const handlers = {
|
|
|
129
130
|
// Analytics
|
|
130
131
|
"oneshot_spend_breakdown": handleSpendBreakdown,
|
|
131
132
|
"oneshot_rocs": handleRocs,
|
|
133
|
+
"oneshot_rocs_by_goal": handleRocsByGoal,
|
|
132
134
|
"oneshot_receipts_list": handleReceiptsList,
|
|
133
135
|
"oneshot_tag_receipt_value": handleTagReceiptValue,
|
|
134
136
|
// Account
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oneshot-agent/mcp-server",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "MCP server for OneShot - commercial actions for AI agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@coinbase/cdp-sdk": "1.45.0",
|
|
27
27
|
"@modelcontextprotocol/sdk": "1.27.1",
|
|
28
|
-
"@oneshot-agent/sdk": "^0.
|
|
28
|
+
"@oneshot-agent/sdk": "^0.23.0",
|
|
29
29
|
"zod": "3.25.76"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|