@withpica/mcp-server 2.1.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 +305 -0
- package/dist/config.d.ts +34 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +33 -0
- package/dist/config.js.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +34 -0
- package/dist/index.js.map +1 -0
- package/dist/pica-sdk.d.ts +1162 -0
- package/dist/pica-sdk.d.ts.map +1 -0
- package/dist/pica-sdk.js +1371 -0
- package/dist/pica-sdk.js.map +1 -0
- package/dist/prompts/index.d.ts +78 -0
- package/dist/prompts/index.d.ts.map +1 -0
- package/dist/prompts/index.js +513 -0
- package/dist/prompts/index.js.map +1 -0
- package/dist/resources/index.d.ts +64 -0
- package/dist/resources/index.d.ts.map +1 -0
- package/dist/resources/index.js +310 -0
- package/dist/resources/index.js.map +1 -0
- package/dist/resources/llms-primer.d.ts +2 -0
- package/dist/resources/llms-primer.d.ts.map +1 -0
- package/dist/resources/llms-primer.js +67 -0
- package/dist/resources/llms-primer.js.map +1 -0
- package/dist/server.d.ts +27 -0
- package/dist/server.d.ts.map +1 -0
- package/dist/server.js +140 -0
- package/dist/server.js.map +1 -0
- package/dist/tools/agreement-types.d.ts +37 -0
- package/dist/tools/agreement-types.d.ts.map +1 -0
- package/dist/tools/agreement-types.js +579 -0
- package/dist/tools/agreement-types.js.map +1 -0
- package/dist/tools/agreements.d.ts +21 -0
- package/dist/tools/agreements.d.ts.map +1 -0
- package/dist/tools/agreements.js +328 -0
- package/dist/tools/agreements.js.map +1 -0
- package/dist/tools/analytics.d.ts +20 -0
- package/dist/tools/analytics.d.ts.map +1 -0
- package/dist/tools/analytics.js +126 -0
- package/dist/tools/analytics.js.map +1 -0
- package/dist/tools/assets.d.ts +23 -0
- package/dist/tools/assets.d.ts.map +1 -0
- package/dist/tools/assets.js +220 -0
- package/dist/tools/assets.js.map +1 -0
- package/dist/tools/audio-files.d.ts +21 -0
- package/dist/tools/audio-files.d.ts.map +1 -0
- package/dist/tools/audio-files.js +358 -0
- package/dist/tools/audio-files.js.map +1 -0
- package/dist/tools/bulk.d.ts +16 -0
- package/dist/tools/bulk.d.ts.map +1 -0
- package/dist/tools/bulk.js +82 -0
- package/dist/tools/bulk.js.map +1 -0
- package/dist/tools/calendar.d.ts +15 -0
- package/dist/tools/calendar.d.ts.map +1 -0
- package/dist/tools/calendar.js +69 -0
- package/dist/tools/calendar.js.map +1 -0
- package/dist/tools/collaborators.d.ts +17 -0
- package/dist/tools/collaborators.d.ts.map +1 -0
- package/dist/tools/collaborators.js +133 -0
- package/dist/tools/collaborators.js.map +1 -0
- package/dist/tools/comparisons.d.ts +22 -0
- package/dist/tools/comparisons.d.ts.map +1 -0
- package/dist/tools/comparisons.js +86 -0
- package/dist/tools/comparisons.js.map +1 -0
- package/dist/tools/credits.d.ts +17 -0
- package/dist/tools/credits.d.ts.map +1 -0
- package/dist/tools/credits.js +136 -0
- package/dist/tools/credits.js.map +1 -0
- package/dist/tools/dashboard.d.ts +20 -0
- package/dist/tools/dashboard.d.ts.map +1 -0
- package/dist/tools/dashboard.js +156 -0
- package/dist/tools/dashboard.js.map +1 -0
- package/dist/tools/directory.d.ts +15 -0
- package/dist/tools/directory.d.ts.map +1 -0
- package/dist/tools/directory.js +108 -0
- package/dist/tools/directory.js.map +1 -0
- package/dist/tools/disputes.d.ts +18 -0
- package/dist/tools/disputes.d.ts.map +1 -0
- package/dist/tools/disputes.js +66 -0
- package/dist/tools/disputes.js.map +1 -0
- package/dist/tools/documents.d.ts +15 -0
- package/dist/tools/documents.d.ts.map +1 -0
- package/dist/tools/documents.js +38 -0
- package/dist/tools/documents.js.map +1 -0
- package/dist/tools/duplicates.d.ts +16 -0
- package/dist/tools/duplicates.d.ts.map +1 -0
- package/dist/tools/duplicates.js +72 -0
- package/dist/tools/duplicates.js.map +1 -0
- package/dist/tools/enrichment.d.ts +23 -0
- package/dist/tools/enrichment.d.ts.map +1 -0
- package/dist/tools/enrichment.js +207 -0
- package/dist/tools/enrichment.js.map +1 -0
- package/dist/tools/exports.d.ts +19 -0
- package/dist/tools/exports.d.ts.map +1 -0
- package/dist/tools/exports.js +155 -0
- package/dist/tools/exports.js.map +1 -0
- package/dist/tools/health.d.ts +17 -0
- package/dist/tools/health.d.ts.map +1 -0
- package/dist/tools/health.js +69 -0
- package/dist/tools/health.js.map +1 -0
- package/dist/tools/import-documents.d.ts +21 -0
- package/dist/tools/import-documents.d.ts.map +1 -0
- package/dist/tools/import-documents.js +191 -0
- package/dist/tools/import-documents.js.map +1 -0
- package/dist/tools/import.d.ts +29 -0
- package/dist/tools/import.d.ts.map +1 -0
- package/dist/tools/import.js +404 -0
- package/dist/tools/import.js.map +1 -0
- package/dist/tools/index.d.ts +48 -0
- package/dist/tools/index.d.ts.map +1 -0
- package/dist/tools/index.js +394 -0
- package/dist/tools/index.js.map +1 -0
- package/dist/tools/integrations.d.ts +15 -0
- package/dist/tools/integrations.d.ts.map +1 -0
- package/dist/tools/integrations.js +102 -0
- package/dist/tools/integrations.js.map +1 -0
- package/dist/tools/licensing.d.ts +40 -0
- package/dist/tools/licensing.d.ts.map +1 -0
- package/dist/tools/licensing.js +436 -0
- package/dist/tools/licensing.js.map +1 -0
- package/dist/tools/memory.d.ts +21 -0
- package/dist/tools/memory.d.ts.map +1 -0
- package/dist/tools/memory.js +121 -0
- package/dist/tools/memory.js.map +1 -0
- package/dist/tools/multimedia.d.ts +19 -0
- package/dist/tools/multimedia.d.ts.map +1 -0
- package/dist/tools/multimedia.js +293 -0
- package/dist/tools/multimedia.js.map +1 -0
- package/dist/tools/notes.d.ts +21 -0
- package/dist/tools/notes.d.ts.map +1 -0
- package/dist/tools/notes.js +126 -0
- package/dist/tools/notes.js.map +1 -0
- package/dist/tools/notifications.d.ts +17 -0
- package/dist/tools/notifications.d.ts.map +1 -0
- package/dist/tools/notifications.js +117 -0
- package/dist/tools/notifications.js.map +1 -0
- package/dist/tools/people.d.ts +53 -0
- package/dist/tools/people.d.ts.map +1 -0
- package/dist/tools/people.js +534 -0
- package/dist/tools/people.js.map +1 -0
- package/dist/tools/pica-score.d.ts +15 -0
- package/dist/tools/pica-score.d.ts.map +1 -0
- package/dist/tools/pica-score.js +30 -0
- package/dist/tools/pica-score.js.map +1 -0
- package/dist/tools/projects.d.ts +19 -0
- package/dist/tools/projects.d.ts.map +1 -0
- package/dist/tools/projects.js +142 -0
- package/dist/tools/projects.js.map +1 -0
- package/dist/tools/purchases.d.ts +15 -0
- package/dist/tools/purchases.d.ts.map +1 -0
- package/dist/tools/purchases.js +65 -0
- package/dist/tools/purchases.js.map +1 -0
- package/dist/tools/recordings.d.ts +41 -0
- package/dist/tools/recordings.d.ts.map +1 -0
- package/dist/tools/recordings.js +293 -0
- package/dist/tools/recordings.js.map +1 -0
- package/dist/tools/registration.d.ts +16 -0
- package/dist/tools/registration.d.ts.map +1 -0
- package/dist/tools/registration.js +52 -0
- package/dist/tools/registration.js.map +1 -0
- package/dist/tools/releases.d.ts +18 -0
- package/dist/tools/releases.d.ts.map +1 -0
- package/dist/tools/releases.js +138 -0
- package/dist/tools/releases.js.map +1 -0
- package/dist/tools/royalties.d.ts +23 -0
- package/dist/tools/royalties.d.ts.map +1 -0
- package/dist/tools/royalties.js +263 -0
- package/dist/tools/royalties.js.map +1 -0
- package/dist/tools/search.d.ts +30 -0
- package/dist/tools/search.d.ts.map +1 -0
- package/dist/tools/search.js +117 -0
- package/dist/tools/search.js.map +1 -0
- package/dist/tools/send.d.ts +18 -0
- package/dist/tools/send.d.ts.map +1 -0
- package/dist/tools/send.js +189 -0
- package/dist/tools/send.js.map +1 -0
- package/dist/tools/sessions.d.ts +18 -0
- package/dist/tools/sessions.d.ts.map +1 -0
- package/dist/tools/sessions.js +107 -0
- package/dist/tools/sessions.js.map +1 -0
- package/dist/tools/settings.d.ts +18 -0
- package/dist/tools/settings.d.ts.map +1 -0
- package/dist/tools/settings.js +98 -0
- package/dist/tools/settings.js.map +1 -0
- package/dist/tools/share-links.d.ts +19 -0
- package/dist/tools/share-links.d.ts.map +1 -0
- package/dist/tools/share-links.js +126 -0
- package/dist/tools/share-links.js.map +1 -0
- package/dist/tools/split-sheets.d.ts +24 -0
- package/dist/tools/split-sheets.d.ts.map +1 -0
- package/dist/tools/split-sheets.js +189 -0
- package/dist/tools/split-sheets.js.map +1 -0
- package/dist/tools/team.d.ts +22 -0
- package/dist/tools/team.d.ts.map +1 -0
- package/dist/tools/team.js +139 -0
- package/dist/tools/team.js.map +1 -0
- package/dist/tools/telegram.d.ts +20 -0
- package/dist/tools/telegram.d.ts.map +1 -0
- package/dist/tools/telegram.js +94 -0
- package/dist/tools/telegram.js.map +1 -0
- package/dist/tools/uploads.d.ts +17 -0
- package/dist/tools/uploads.d.ts.map +1 -0
- package/dist/tools/uploads.js +159 -0
- package/dist/tools/uploads.js.map +1 -0
- package/dist/tools/works.d.ts +53 -0
- package/dist/tools/works.d.ts.map +1 -0
- package/dist/tools/works.js +517 -0
- package/dist/tools/works.js.map +1 -0
- package/dist/utils/credit-gate.d.ts +17 -0
- package/dist/utils/credit-gate.d.ts.map +1 -0
- package/dist/utils/credit-gate.js +111 -0
- package/dist/utils/credit-gate.js.map +1 -0
- package/dist/utils/errors.d.ts +29 -0
- package/dist/utils/errors.d.ts.map +1 -0
- package/dist/utils/errors.js +114 -0
- package/dist/utils/errors.js.map +1 -0
- package/dist/utils/formatting.d.ts +63 -0
- package/dist/utils/formatting.d.ts.map +1 -0
- package/dist/utils/formatting.js +130 -0
- package/dist/utils/formatting.js.map +1 -0
- package/dist/utils/mpp.d.ts +78 -0
- package/dist/utils/mpp.d.ts.map +1 -0
- package/dist/utils/mpp.js +136 -0
- package/dist/utils/mpp.js.map +1 -0
- package/package.json +44 -0
|
@@ -0,0 +1,328 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agreements Tools - MCP tools for managing agreements and contracts
|
|
3
|
+
*/
|
|
4
|
+
import { formatAsText, formatList, formatSuccess, } from "../utils/formatting.js";
|
|
5
|
+
export class AgreementsTools {
|
|
6
|
+
pica;
|
|
7
|
+
constructor(pica) {
|
|
8
|
+
this.pica = pica;
|
|
9
|
+
}
|
|
10
|
+
getTools() {
|
|
11
|
+
return [
|
|
12
|
+
{
|
|
13
|
+
definition: {
|
|
14
|
+
name: "pica_agreements_list",
|
|
15
|
+
description: "List agreements with optional filters. Returns contracts, publishing deals, and other agreements.",
|
|
16
|
+
inputSchema: {
|
|
17
|
+
type: "object",
|
|
18
|
+
properties: {
|
|
19
|
+
query: {
|
|
20
|
+
type: "string",
|
|
21
|
+
description: "Search by title or party name",
|
|
22
|
+
},
|
|
23
|
+
agreement_type: {
|
|
24
|
+
type: "string",
|
|
25
|
+
description: "Filter by agreement type",
|
|
26
|
+
enum: [
|
|
27
|
+
"master_recording",
|
|
28
|
+
"library_music",
|
|
29
|
+
"publishing_admin",
|
|
30
|
+
"production",
|
|
31
|
+
"artist_contract",
|
|
32
|
+
"termination",
|
|
33
|
+
"report",
|
|
34
|
+
"other",
|
|
35
|
+
],
|
|
36
|
+
},
|
|
37
|
+
status: {
|
|
38
|
+
type: "string",
|
|
39
|
+
description: "Filter by status",
|
|
40
|
+
enum: [
|
|
41
|
+
"draft",
|
|
42
|
+
"pending_signature",
|
|
43
|
+
"partially_signed",
|
|
44
|
+
"fully_executed",
|
|
45
|
+
"active",
|
|
46
|
+
"completed",
|
|
47
|
+
"terminated",
|
|
48
|
+
"expired",
|
|
49
|
+
"cancelled",
|
|
50
|
+
"unknown",
|
|
51
|
+
],
|
|
52
|
+
},
|
|
53
|
+
party_name: {
|
|
54
|
+
type: "string",
|
|
55
|
+
description: "Filter by other party name",
|
|
56
|
+
},
|
|
57
|
+
limit: {
|
|
58
|
+
type: "number",
|
|
59
|
+
description: "Maximum results (default: 50, max: 100)",
|
|
60
|
+
},
|
|
61
|
+
offset: {
|
|
62
|
+
type: "number",
|
|
63
|
+
description: "Pagination offset (default: 0)",
|
|
64
|
+
},
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
executor: this.listAgreements.bind(this),
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
definition: {
|
|
72
|
+
name: "pica_agreements_get",
|
|
73
|
+
description: "Get a single agreement with full details including signature status and linked works.",
|
|
74
|
+
inputSchema: {
|
|
75
|
+
type: "object",
|
|
76
|
+
properties: {
|
|
77
|
+
id: {
|
|
78
|
+
type: "string",
|
|
79
|
+
description: "Agreement ID",
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
required: ["id"],
|
|
83
|
+
},
|
|
84
|
+
},
|
|
85
|
+
executor: this.getAgreement.bind(this),
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
definition: {
|
|
89
|
+
name: "pica_agreements_create",
|
|
90
|
+
description: "Create a new agreement. Requires title, type, and other party name.",
|
|
91
|
+
inputSchema: {
|
|
92
|
+
type: "object",
|
|
93
|
+
properties: {
|
|
94
|
+
title: {
|
|
95
|
+
type: "string",
|
|
96
|
+
description: "Agreement title",
|
|
97
|
+
},
|
|
98
|
+
agreement_type: {
|
|
99
|
+
type: "string",
|
|
100
|
+
description: "Type of agreement",
|
|
101
|
+
enum: [
|
|
102
|
+
"master_recording",
|
|
103
|
+
"library_music",
|
|
104
|
+
"publishing_admin",
|
|
105
|
+
"production",
|
|
106
|
+
"artist_contract",
|
|
107
|
+
"termination",
|
|
108
|
+
"report",
|
|
109
|
+
"other",
|
|
110
|
+
],
|
|
111
|
+
},
|
|
112
|
+
other_party_name: {
|
|
113
|
+
type: "string",
|
|
114
|
+
description: "Name of the other party (label, publisher, etc.)",
|
|
115
|
+
},
|
|
116
|
+
status: {
|
|
117
|
+
type: "string",
|
|
118
|
+
description: "Initial status (default: draft)",
|
|
119
|
+
enum: [
|
|
120
|
+
"draft",
|
|
121
|
+
"pending_signature",
|
|
122
|
+
"partially_signed",
|
|
123
|
+
"fully_executed",
|
|
124
|
+
"active",
|
|
125
|
+
"completed",
|
|
126
|
+
"terminated",
|
|
127
|
+
"expired",
|
|
128
|
+
"cancelled",
|
|
129
|
+
],
|
|
130
|
+
},
|
|
131
|
+
other_party_type: {
|
|
132
|
+
type: "string",
|
|
133
|
+
description: "Type of the other party (e.g., label, publisher, distributor)",
|
|
134
|
+
},
|
|
135
|
+
signing_date: {
|
|
136
|
+
type: "string",
|
|
137
|
+
description: "Date the agreement was signed (ISO 8601)",
|
|
138
|
+
},
|
|
139
|
+
start_date: {
|
|
140
|
+
type: "string",
|
|
141
|
+
description: "Start date of the agreement term (ISO 8601)",
|
|
142
|
+
},
|
|
143
|
+
end_date: {
|
|
144
|
+
type: "string",
|
|
145
|
+
description: "End date of the agreement term (ISO 8601)",
|
|
146
|
+
},
|
|
147
|
+
description: {
|
|
148
|
+
type: "string",
|
|
149
|
+
description: "Description of the agreement",
|
|
150
|
+
},
|
|
151
|
+
notes: {
|
|
152
|
+
type: "string",
|
|
153
|
+
description: "Internal notes",
|
|
154
|
+
},
|
|
155
|
+
},
|
|
156
|
+
required: ["title", "agreement_type", "other_party_name"],
|
|
157
|
+
},
|
|
158
|
+
},
|
|
159
|
+
executor: this.createAgreement.bind(this),
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
definition: {
|
|
163
|
+
name: "pica_agreements_update",
|
|
164
|
+
description: "Update an existing agreement. Status changes trigger notifications.",
|
|
165
|
+
inputSchema: {
|
|
166
|
+
type: "object",
|
|
167
|
+
properties: {
|
|
168
|
+
id: {
|
|
169
|
+
type: "string",
|
|
170
|
+
description: "Agreement ID",
|
|
171
|
+
},
|
|
172
|
+
title: {
|
|
173
|
+
type: "string",
|
|
174
|
+
description: "Updated title",
|
|
175
|
+
},
|
|
176
|
+
status: {
|
|
177
|
+
type: "string",
|
|
178
|
+
description: "Updated status",
|
|
179
|
+
enum: [
|
|
180
|
+
"draft",
|
|
181
|
+
"pending_signature",
|
|
182
|
+
"partially_signed",
|
|
183
|
+
"fully_executed",
|
|
184
|
+
"active",
|
|
185
|
+
"completed",
|
|
186
|
+
"terminated",
|
|
187
|
+
"expired",
|
|
188
|
+
"cancelled",
|
|
189
|
+
],
|
|
190
|
+
},
|
|
191
|
+
other_party_name: {
|
|
192
|
+
type: "string",
|
|
193
|
+
description: "Updated other party name",
|
|
194
|
+
},
|
|
195
|
+
signing_date: {
|
|
196
|
+
type: "string",
|
|
197
|
+
description: "Updated signing date (ISO 8601)",
|
|
198
|
+
},
|
|
199
|
+
start_date: {
|
|
200
|
+
type: "string",
|
|
201
|
+
description: "Updated start date (ISO 8601)",
|
|
202
|
+
},
|
|
203
|
+
end_date: {
|
|
204
|
+
type: "string",
|
|
205
|
+
description: "Updated end date (ISO 8601)",
|
|
206
|
+
},
|
|
207
|
+
description: {
|
|
208
|
+
type: "string",
|
|
209
|
+
description: "Updated description",
|
|
210
|
+
},
|
|
211
|
+
notes: {
|
|
212
|
+
type: "string",
|
|
213
|
+
description: "Updated internal notes",
|
|
214
|
+
},
|
|
215
|
+
},
|
|
216
|
+
required: ["id"],
|
|
217
|
+
},
|
|
218
|
+
},
|
|
219
|
+
executor: this.updateAgreement.bind(this),
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
definition: {
|
|
223
|
+
name: "pica_agreements_delete",
|
|
224
|
+
description: "Delete an agreement",
|
|
225
|
+
inputSchema: {
|
|
226
|
+
type: "object",
|
|
227
|
+
properties: {
|
|
228
|
+
id: {
|
|
229
|
+
type: "string",
|
|
230
|
+
description: "Agreement ID",
|
|
231
|
+
},
|
|
232
|
+
},
|
|
233
|
+
required: ["id"],
|
|
234
|
+
},
|
|
235
|
+
},
|
|
236
|
+
executor: this.deleteAgreement.bind(this),
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
definition: {
|
|
240
|
+
name: "pica_agreements_link_work",
|
|
241
|
+
description: "Link a work to an agreement. Optionally set a royalty split percentage.",
|
|
242
|
+
inputSchema: {
|
|
243
|
+
type: "object",
|
|
244
|
+
properties: {
|
|
245
|
+
agreement_id: {
|
|
246
|
+
type: "string",
|
|
247
|
+
description: "Agreement ID",
|
|
248
|
+
},
|
|
249
|
+
work_id: {
|
|
250
|
+
type: "string",
|
|
251
|
+
description: "Work ID to link",
|
|
252
|
+
},
|
|
253
|
+
royalty_split_percentage: {
|
|
254
|
+
type: "number",
|
|
255
|
+
description: "Royalty split percentage for this work (0-100)",
|
|
256
|
+
},
|
|
257
|
+
notes: {
|
|
258
|
+
type: "string",
|
|
259
|
+
description: "Notes about this work's inclusion in the agreement",
|
|
260
|
+
},
|
|
261
|
+
},
|
|
262
|
+
required: ["agreement_id", "work_id"],
|
|
263
|
+
},
|
|
264
|
+
},
|
|
265
|
+
executor: this.linkWork.bind(this),
|
|
266
|
+
},
|
|
267
|
+
{
|
|
268
|
+
definition: {
|
|
269
|
+
name: "pica_agreements_works",
|
|
270
|
+
description: "List all works linked to an agreement",
|
|
271
|
+
inputSchema: {
|
|
272
|
+
type: "object",
|
|
273
|
+
properties: {
|
|
274
|
+
agreement_id: {
|
|
275
|
+
type: "string",
|
|
276
|
+
description: "Agreement ID",
|
|
277
|
+
},
|
|
278
|
+
},
|
|
279
|
+
required: ["agreement_id"],
|
|
280
|
+
},
|
|
281
|
+
},
|
|
282
|
+
executor: this.getAgreementWorks.bind(this),
|
|
283
|
+
},
|
|
284
|
+
];
|
|
285
|
+
}
|
|
286
|
+
async listAgreements(args) {
|
|
287
|
+
const agreements = await this.pica.agreements.list({
|
|
288
|
+
query: args.query,
|
|
289
|
+
agreement_type: args.agreement_type,
|
|
290
|
+
status: args.status,
|
|
291
|
+
party_name: args.party_name,
|
|
292
|
+
includeWorkCounts: true,
|
|
293
|
+
limit: args.limit,
|
|
294
|
+
offset: args.offset,
|
|
295
|
+
});
|
|
296
|
+
return formatList(agreements, { total: agreements.length });
|
|
297
|
+
}
|
|
298
|
+
async getAgreement(args) {
|
|
299
|
+
const result = await this.pica.agreements.get(args.id);
|
|
300
|
+
return formatAsText(result);
|
|
301
|
+
}
|
|
302
|
+
async createAgreement(args) {
|
|
303
|
+
const agreement = await this.pica.agreements.create(args);
|
|
304
|
+
return formatSuccess("Agreement created", agreement);
|
|
305
|
+
}
|
|
306
|
+
async updateAgreement(args) {
|
|
307
|
+
const { id, ...updates } = args;
|
|
308
|
+
const agreement = await this.pica.agreements.update(id, updates);
|
|
309
|
+
return formatSuccess("Agreement updated", agreement);
|
|
310
|
+
}
|
|
311
|
+
async deleteAgreement(args) {
|
|
312
|
+
await this.pica.agreements.delete(args.id);
|
|
313
|
+
return formatSuccess(`Agreement ${args.id} deleted`);
|
|
314
|
+
}
|
|
315
|
+
async linkWork(args) {
|
|
316
|
+
const link = await this.pica.agreements.linkWork(args.agreement_id, {
|
|
317
|
+
work_id: args.work_id,
|
|
318
|
+
royalty_split_percentage: args.royalty_split_percentage,
|
|
319
|
+
notes: args.notes,
|
|
320
|
+
});
|
|
321
|
+
return formatSuccess("Work linked to agreement", link);
|
|
322
|
+
}
|
|
323
|
+
async getAgreementWorks(args) {
|
|
324
|
+
const works = await this.pica.agreements.getWorks(args.agreement_id);
|
|
325
|
+
return formatList(works, { agreement_id: args.agreement_id });
|
|
326
|
+
}
|
|
327
|
+
}
|
|
328
|
+
//# sourceMappingURL=agreements.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agreements.js","sourceRoot":"","sources":["../../src/tools/agreements.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH,OAAO,EACL,YAAY,EACZ,UAAU,EACV,aAAa,GACd,MAAM,wBAAwB,CAAC;AAEhC,MAAM,OAAO,eAAe;IAClB,IAAI,CAAa;IAEzB,YAAY,IAAgB;QAC1B,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;IACnB,CAAC;IAED,QAAQ;QACN,OAAO;YACL;gBACE,UAAU,EAAE;oBACV,IAAI,EAAE,sBAAsB;oBAC5B,WAAW,EACT,mGAAmG;oBACrG,WAAW,EAAE;wBACX,IAAI,EAAE,Q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,EAAE,SAAS,CAAC,CAAC;IACvD,CAAC;IAEO,KAAK,CAAC,eAAe,CAC3B,IAAyB;QAEzB,MAAM,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QAC3C,OAAO,aAAa,CAAC,aAAa,IAAI,CAAC,EAAE,UAAU,CAAC,CAAC;IACvD,CAAC;IAEO,KAAK,CAAC,QAAQ,CAAC,IAAyB;QAC9C,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,EAAE;YAClE,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,wBAAwB,EAAE,IAAI,CAAC,wBAAwB;YACvD,KAAK,EAAE,IAAI,CAAC,KAAK;SAClB,CAAC,CAAC;QACH,OAAO,aAAa,CAAC,0BAA0B,EAAE,IAAI,CAAC,CAAC;IACzD,CAAC;IAEO,KAAK,CAAC,iBAAiB,CAC7B,IAAyB;QAEzB,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;QACrE,OAAO,UAAU,CAAC,KAAK,EAAE,EAAE,YAAY,EAAE,IAAI,CAAC,YAAY,EAAE,CAAC,CAAC;IAChE,CAAC;CACF"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Analytics & Reporting Tools — carbon footprint, provenance, catalog diligence
|
|
3
|
+
*/
|
|
4
|
+
import { PicaClient } from "../pica-sdk.js";
|
|
5
|
+
import { ToolDefinition, ToolExecutor } from "./index.js";
|
|
6
|
+
export declare class AnalyticsTools {
|
|
7
|
+
private pica;
|
|
8
|
+
constructor(pica: PicaClient);
|
|
9
|
+
getTools(): Array<{
|
|
10
|
+
definition: ToolDefinition;
|
|
11
|
+
executor: ToolExecutor;
|
|
12
|
+
}>;
|
|
13
|
+
private carbonSummary;
|
|
14
|
+
private carbonLive;
|
|
15
|
+
private provenanceStats;
|
|
16
|
+
private provenanceWork;
|
|
17
|
+
private provenanceCertificate;
|
|
18
|
+
private catalogDiligence;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=analytics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"analytics.d.ts","sourceRoot":"","sources":["../../src/tools/analytics.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAC5C,OAAO,EAAE,cAAc,EAAE,YAAY,EAAc,MAAM,YAAY,CAAC;AAGtE,qBAAa,cAAc;IACzB,OAAO,CAAC,IAAI,CAAa;gBAEb,IAAI,EAAE,UAAU;IAI5B,QAAQ,IAAI,KAAK,CAAC;QAAE,UAAU,EAAE,cAAc,CAAC;QAAC,QAAQ,EAAE,YAAY,CAAA;KAAE,CAAC;YAkG3D,aAAa;YAKb,UAAU;YAKV,eAAe;YAOf,cAAc;YAKd,qBAAqB;YAYrB,gBAAgB;CAM/B"}
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Analytics & Reporting Tools — carbon footprint, provenance, catalog diligence
|
|
3
|
+
*/
|
|
4
|
+
import { formatAsText, formatSuccess } from "../utils/formatting.js";
|
|
5
|
+
export class AnalyticsTools {
|
|
6
|
+
pica;
|
|
7
|
+
constructor(pica) {
|
|
8
|
+
this.pica = pica;
|
|
9
|
+
}
|
|
10
|
+
getTools() {
|
|
11
|
+
return [
|
|
12
|
+
// --- Carbon footprint ---
|
|
13
|
+
{
|
|
14
|
+
definition: {
|
|
15
|
+
name: "pica_carbon_footprint",
|
|
16
|
+
description: "Get the carbon footprint summary for your catalog — " +
|
|
17
|
+
"streaming, physical distribution, and production emissions.",
|
|
18
|
+
inputSchema: {
|
|
19
|
+
type: "object",
|
|
20
|
+
properties: {},
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
executor: this.carbonSummary.bind(this),
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
definition: {
|
|
27
|
+
name: "pica_carbon_live",
|
|
28
|
+
description: "Get live/real-time carbon metrics for ongoing streaming and distribution activity.",
|
|
29
|
+
inputSchema: {
|
|
30
|
+
type: "object",
|
|
31
|
+
properties: {},
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
executor: this.carbonLive.bind(this),
|
|
35
|
+
},
|
|
36
|
+
// --- Provenance ---
|
|
37
|
+
{
|
|
38
|
+
definition: {
|
|
39
|
+
name: "pica_provenance_stats",
|
|
40
|
+
description: "Get provenance statistics — how many works have chain-of-title records, " +
|
|
41
|
+
"attestation coverage, and verification status.",
|
|
42
|
+
inputSchema: {
|
|
43
|
+
type: "object",
|
|
44
|
+
properties: {},
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
executor: this.provenanceStats.bind(this),
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
definition: {
|
|
51
|
+
name: "pica_provenance_work",
|
|
52
|
+
description: "Get the full provenance chain for a specific work — " +
|
|
53
|
+
"creation history, ownership transfers, attestations, and verification entries.",
|
|
54
|
+
inputSchema: {
|
|
55
|
+
type: "object",
|
|
56
|
+
properties: {
|
|
57
|
+
work_id: {
|
|
58
|
+
type: "string",
|
|
59
|
+
description: "The work ID to get provenance for",
|
|
60
|
+
},
|
|
61
|
+
},
|
|
62
|
+
required: ["work_id"],
|
|
63
|
+
},
|
|
64
|
+
},
|
|
65
|
+
executor: this.provenanceWork.bind(this),
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
definition: {
|
|
69
|
+
name: "pica_provenance_certificate",
|
|
70
|
+
description: "Generate a provenance certificate for a work — " +
|
|
71
|
+
"a downloadable chain-of-title document with attestation details.",
|
|
72
|
+
inputSchema: {
|
|
73
|
+
type: "object",
|
|
74
|
+
properties: {
|
|
75
|
+
work_id: {
|
|
76
|
+
type: "string",
|
|
77
|
+
description: "The work ID to generate a certificate for",
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
required: ["work_id"],
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
executor: this.provenanceCertificate.bind(this),
|
|
84
|
+
},
|
|
85
|
+
// --- Catalog diligence ---
|
|
86
|
+
{
|
|
87
|
+
definition: {
|
|
88
|
+
name: "pica_catalog_diligence",
|
|
89
|
+
description: "Generate a technical due diligence report for the catalog — " +
|
|
90
|
+
"ownership clarity, registration coverage, identifier completeness, " +
|
|
91
|
+
"and readiness for lending, licensing, or acquisition.",
|
|
92
|
+
inputSchema: {
|
|
93
|
+
type: "object",
|
|
94
|
+
properties: {},
|
|
95
|
+
},
|
|
96
|
+
},
|
|
97
|
+
executor: this.catalogDiligence.bind(this),
|
|
98
|
+
},
|
|
99
|
+
];
|
|
100
|
+
}
|
|
101
|
+
async carbonSummary(_args) {
|
|
102
|
+
const result = await this.pica.analytics.carbonSummary();
|
|
103
|
+
return formatSuccess("Carbon footprint summary", result);
|
|
104
|
+
}
|
|
105
|
+
async carbonLive(_args) {
|
|
106
|
+
const result = await this.pica.analytics.carbonLive();
|
|
107
|
+
return formatSuccess("Live carbon metrics", result);
|
|
108
|
+
}
|
|
109
|
+
async provenanceStats(_args) {
|
|
110
|
+
const result = await this.pica.analytics.provenanceStats();
|
|
111
|
+
return formatAsText(result);
|
|
112
|
+
}
|
|
113
|
+
async provenanceWork(args) {
|
|
114
|
+
const result = await this.pica.analytics.provenanceWork(args.work_id);
|
|
115
|
+
return formatAsText(result);
|
|
116
|
+
}
|
|
117
|
+
async provenanceCertificate(args) {
|
|
118
|
+
const result = await this.pica.analytics.provenanceCertificate(args.work_id);
|
|
119
|
+
return formatSuccess(`Provenance certificate generated for work ${args.work_id}`, result);
|
|
120
|
+
}
|
|
121
|
+
async catalogDiligence(_args) {
|
|
122
|
+
const result = await this.pica.analytics.catalogDiligence();
|
|
123
|
+
return formatSuccess("Catalog diligence report", result);
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
//# sourceMappingURL=analytics.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"analytics.js","sourceRoot":"","sources":["../../src/tools/analytics.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAErE,MAAM,OAAO,cAAc;IACjB,IAAI,CAAa;IAEzB,YAAY,IAAgB;QAC1B,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;IACnB,CAAC;IAED,QAAQ;QACN,OAAO;YACL,2BAA2B;YAC3B;gBACE,UAAU,EAAE;oBACV,IAAI,EAAE,uBAAuB;oBAC7B,WAAW,EACT,sDAAsD;wBACtD,6DAA6D;oBAC/D,WAAW,EAAE;wBACX,IAAI,EAAE,QAAQ;wBACd,UAAU,EAAE,EAAE;qBACf;iBACF;gBACD,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC;aACxC;YACD;gBACE,UAAU,EAAE;oBACV,IAAI,EAAE,kBAAkB;oBACxB,WAAW,EACT,oFAAoF;oBACtF,WAAW,EAAE;wBACX,IAAI,EAAE,QAAQ;wBACd,UAAU,EAAE,EAAE;qBACf;iBACF;gBACD,QAAQ,EAAE,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC;aACrC;YACD,qBAAqB;YACrB;gBACE,UAAU,EAAE;oBACV,IAAI,EAAE,uBAAuB;oBAC7B,WAAW,EACT,0EAA0E;wBAC1E,gDAAgD;oBAClD,WAAW,EAAE;wBACX,IAAI,EAAE,QAAQ;wBACd,UAAU,EAAE,EAAE;qBACf;iBACF;gBACD,QAAQ,EAAE,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC;aAC1C;YACD;gBACE,UAAU,EAAE;oBACV,IAAI,EAAE,sBAAsB;oBAC5B,WAAW,EACT,sDAAsD;wBACtD,gFAAgF;oBAClF,WAAW,EAAE;wBACX,IA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AO,aAAa,CAAC,qBAAqB,EAAE,MAAM,CAAC,CAAC;IACtD,CAAC;IAEO,KAAK,CAAC,eAAe,CAC3B,KAA0B;QAE1B,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,eAAe,EAAE,CAAC;QAC3D,OAAO,YAAY,CAAC,MAAM,CAAC,CAAC;IAC9B,CAAC;IAEO,KAAK,CAAC,cAAc,CAAC,IAAyB;QACpD,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACtE,OAAO,YAAY,CAAC,MAAM,CAAC,CAAC;IAC9B,CAAC;IAEO,KAAK,CAAC,qBAAqB,CACjC,IAAyB;QAEzB,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,qBAAqB,CAC5D,IAAI,CAAC,OAAO,CACb,CAAC;QACF,OAAO,aAAa,CAClB,6CAA6C,IAAI,CAAC,OAAO,EAAE,EAC3D,MAAM,CACP,CAAC;IACJ,CAAC;IAEO,KAAK,CAAC,gBAAgB,CAC5B,KAA0B;QAE1B,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,gBAAgB,EAAE,CAAC;QAC5D,OAAO,aAAa,CAAC,0BAA0B,EAAE,MAAM,CAAC,CAAC;IAC3D,CAAC;CACF"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Physical Assets Tools - MCP tools for managing equipment, instruments, and studio gear
|
|
3
|
+
*/
|
|
4
|
+
import { PicaClient } from "../pica-sdk.js";
|
|
5
|
+
import { ToolDefinition, ToolExecutor } from "./index.js";
|
|
6
|
+
export declare class AssetsTools {
|
|
7
|
+
private pica;
|
|
8
|
+
constructor(pica: PicaClient);
|
|
9
|
+
getTools(): Array<{
|
|
10
|
+
definition: ToolDefinition;
|
|
11
|
+
executor: ToolExecutor;
|
|
12
|
+
}>;
|
|
13
|
+
private listAssets;
|
|
14
|
+
private getAsset;
|
|
15
|
+
private createAsset;
|
|
16
|
+
private updateAsset;
|
|
17
|
+
private deleteAsset;
|
|
18
|
+
private assetStats;
|
|
19
|
+
private assetValuations;
|
|
20
|
+
private assetMarketCheck;
|
|
21
|
+
private assetExport;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=assets.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"assets.d.ts","sourceRoot":"","sources":["../../src/tools/assets.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAC5C,OAAO,EAAE,cAAc,EAAE,YAAY,EAAc,MAAM,YAAY,CAAC;AAOtE,qBAAa,WAAW;IACtB,OAAO,CAAC,IAAI,CAAa;gBAEb,IAAI,EAAE,UAAU;IAI5B,QAAQ,IAAI,KAAK,CAAC;QAAE,UAAU,EAAE,cAAc,CAAC;QAAC,QAAQ,EAAE,YAAY,CAAA;KAAE,CAAC;YAmL3D,UAAU;YAWV,QAAQ;YAKR,WAAW;YAKX,WAAW;YAMX,WAAW;YAKX,UAAU;YAKV,eAAe;YAOf,gBAAgB;YAOhB,WAAW;CAI1B"}
|