profound-mcp 0.7.1 → 0.8.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/package.json +2 -2
- package/server.js +1 -1
- package/server.mjs +1 -1
- package/src/server.ts +1 -1
- package/src/tools/logs/raw/bots-logs-raw.ts +416 -75
- package/src/tools/logs/raw/logs-logs-raw.ts +436 -64
- package/src/tools/prompts/answers-prompts.ts +181 -57
- package/src/tools/reports/citations-reports.ts +344 -74
- package/src/tools/reports/sentiment-reports.ts +257 -62
- package/src/tools/reports/visibility-reports.ts +215 -62
- package/tools/logs/raw/bots-logs-raw.d.mts.map +1 -1
- package/tools/logs/raw/bots-logs-raw.d.ts.map +1 -1
- package/tools/logs/raw/bots-logs-raw.js +416 -71
- package/tools/logs/raw/bots-logs-raw.js.map +1 -1
- package/tools/logs/raw/bots-logs-raw.mjs +416 -71
- package/tools/logs/raw/bots-logs-raw.mjs.map +1 -1
- package/tools/logs/raw/logs-logs-raw.d.mts.map +1 -1
- package/tools/logs/raw/logs-logs-raw.d.ts.map +1 -1
- package/tools/logs/raw/logs-logs-raw.js +436 -60
- package/tools/logs/raw/logs-logs-raw.js.map +1 -1
- package/tools/logs/raw/logs-logs-raw.mjs +436 -60
- package/tools/logs/raw/logs-logs-raw.mjs.map +1 -1
- package/tools/prompts/answers-prompts.d.mts.map +1 -1
- package/tools/prompts/answers-prompts.d.ts.map +1 -1
- package/tools/prompts/answers-prompts.js +181 -54
- package/tools/prompts/answers-prompts.js.map +1 -1
- package/tools/prompts/answers-prompts.mjs +181 -54
- package/tools/prompts/answers-prompts.mjs.map +1 -1
- package/tools/reports/citations-reports.d.mts.map +1 -1
- package/tools/reports/citations-reports.d.ts.map +1 -1
- package/tools/reports/citations-reports.js +344 -70
- package/tools/reports/citations-reports.js.map +1 -1
- package/tools/reports/citations-reports.mjs +344 -70
- package/tools/reports/citations-reports.mjs.map +1 -1
- package/tools/reports/sentiment-reports.d.mts.map +1 -1
- package/tools/reports/sentiment-reports.d.ts.map +1 -1
- package/tools/reports/sentiment-reports.js +257 -59
- package/tools/reports/sentiment-reports.js.map +1 -1
- package/tools/reports/sentiment-reports.mjs +257 -59
- package/tools/reports/sentiment-reports.mjs.map +1 -1
- package/tools/reports/visibility-reports.d.mts.map +1 -1
- package/tools/reports/visibility-reports.d.ts.map +1 -1
- package/tools/reports/visibility-reports.js +215 -59
- package/tools/reports/visibility-reports.js.map +1 -1
- package/tools/reports/visibility-reports.mjs +215 -59
- package/tools/reports/visibility-reports.mjs.map +1 -1
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { maybeFilter } from 'profound-mcp/filtering';
|
|
4
3
|
import { Metadata, asTextContentResult } from 'profound-mcp/tools/types';
|
|
5
4
|
|
|
6
5
|
import { Tool } from '@modelcontextprotocol/sdk/types.js';
|
|
@@ -17,8 +16,7 @@ export const metadata: Metadata = {
|
|
|
17
16
|
|
|
18
17
|
export const tool: Tool = {
|
|
19
18
|
name: 'citations_reports',
|
|
20
|
-
description:
|
|
21
|
-
"When using this tool, always use the `jq_filter` parameter to reduce the response size and improve performance.\n\nOnly omit if you're sure you don't need the data.\n\nGet citations for a given category.\n\n# Response Schema\n```json\n{\n $ref: '#/$defs/report_citations_response',\n $defs: {\n report_citations_response: {\n type: 'object',\n title: 'CitationsResponse',\n properties: {\n data: {\n type: 'array',\n title: 'Data',\n items: {\n $ref: '#/$defs/report_result'\n }\n },\n info: {\n $ref: '#/$defs/report_info'\n }\n },\n required: [ 'data',\n 'info'\n ]\n },\n report_result: {\n type: 'object',\n title: 'Result',\n description: 'Base model for report results.',\n properties: {\n dimensions: {\n type: 'array',\n title: 'Dimensions',\n items: {\n type: 'string'\n }\n },\n metrics: {\n type: 'array',\n title: 'Metrics',\n items: {\n type: 'number'\n }\n }\n },\n required: [ 'dimensions',\n 'metrics'\n ]\n },\n report_info: {\n type: 'object',\n title: 'Info',\n description: 'Base model for report information.',\n properties: {\n total_rows: {\n type: 'integer',\n title: 'Total Rows'\n },\n query: {\n type: 'object',\n title: 'Query',\n additionalProperties: true\n }\n },\n required: [ 'total_rows'\n ]\n }\n }\n}\n```",
|
|
19
|
+
description: 'Get citations for a given category.',
|
|
22
20
|
inputSchema: {
|
|
23
21
|
type: 'object',
|
|
24
22
|
properties: {
|
|
@@ -77,73 +75,351 @@ export const tool: Tool = {
|
|
|
77
75
|
filters: {
|
|
78
76
|
type: 'array',
|
|
79
77
|
title: 'Filters',
|
|
80
|
-
description: 'List of filters to apply to the report.
|
|
78
|
+
description: 'List of filters to apply to the citations report.',
|
|
81
79
|
items: {
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
80
|
+
anyOf: [
|
|
81
|
+
{
|
|
82
|
+
type: 'object',
|
|
83
|
+
title: 'HostnameFilter',
|
|
84
|
+
description: 'Filter by hostname',
|
|
85
|
+
properties: {
|
|
86
|
+
field: {
|
|
87
|
+
type: 'string',
|
|
88
|
+
title: 'Field',
|
|
89
|
+
enum: ['hostname'],
|
|
90
|
+
},
|
|
91
|
+
operator: {
|
|
92
|
+
type: 'string',
|
|
93
|
+
title: 'Operator',
|
|
94
|
+
enum: [
|
|
95
|
+
'is',
|
|
96
|
+
'not_is',
|
|
97
|
+
'in',
|
|
98
|
+
'not_in',
|
|
99
|
+
'contains',
|
|
100
|
+
'not_contains',
|
|
101
|
+
'matches',
|
|
102
|
+
'contains_case_insensitive',
|
|
103
|
+
'not_contains_case_insensitive',
|
|
104
|
+
],
|
|
105
|
+
},
|
|
106
|
+
value: {
|
|
107
|
+
anyOf: [
|
|
108
|
+
{
|
|
109
|
+
type: 'string',
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
type: 'array',
|
|
113
|
+
items: {
|
|
114
|
+
type: 'string',
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
],
|
|
118
|
+
title: 'Value',
|
|
119
|
+
},
|
|
120
|
+
},
|
|
121
|
+
required: ['field', 'operator', 'value'],
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
type: 'object',
|
|
125
|
+
title: 'PathFilter',
|
|
126
|
+
description: 'Filter by URL path',
|
|
127
|
+
properties: {
|
|
128
|
+
field: {
|
|
129
|
+
type: 'string',
|
|
130
|
+
title: 'Field',
|
|
131
|
+
enum: ['path'],
|
|
132
|
+
},
|
|
133
|
+
operator: {
|
|
134
|
+
type: 'string',
|
|
135
|
+
title: 'Operator',
|
|
136
|
+
enum: [
|
|
137
|
+
'is',
|
|
138
|
+
'not_is',
|
|
139
|
+
'in',
|
|
140
|
+
'not_in',
|
|
141
|
+
'contains',
|
|
142
|
+
'not_contains',
|
|
143
|
+
'matches',
|
|
144
|
+
'contains_case_insensitive',
|
|
145
|
+
'not_contains_case_insensitive',
|
|
146
|
+
],
|
|
147
|
+
},
|
|
148
|
+
value: {
|
|
149
|
+
anyOf: [
|
|
150
|
+
{
|
|
151
|
+
type: 'string',
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
type: 'array',
|
|
155
|
+
items: {
|
|
156
|
+
type: 'string',
|
|
157
|
+
},
|
|
158
|
+
},
|
|
159
|
+
],
|
|
160
|
+
title: 'Value',
|
|
161
|
+
},
|
|
162
|
+
},
|
|
163
|
+
required: ['field', 'operator', 'value'],
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
type: 'object',
|
|
167
|
+
title: 'RegionIdFilter',
|
|
168
|
+
properties: {
|
|
169
|
+
field: {
|
|
170
|
+
type: 'string',
|
|
171
|
+
title: 'Field',
|
|
172
|
+
description: '- `region` - Deprecated',
|
|
173
|
+
enum: ['region_id', 'region'],
|
|
174
|
+
},
|
|
175
|
+
operator: {
|
|
176
|
+
type: 'string',
|
|
177
|
+
title: 'Operator',
|
|
178
|
+
enum: ['is', 'not_is', 'in', 'not_in'],
|
|
179
|
+
},
|
|
180
|
+
value: {
|
|
181
|
+
anyOf: [
|
|
182
|
+
{
|
|
183
|
+
type: 'string',
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
type: 'array',
|
|
187
|
+
items: {
|
|
188
|
+
type: 'string',
|
|
189
|
+
},
|
|
190
|
+
},
|
|
191
|
+
],
|
|
192
|
+
title: 'Value',
|
|
193
|
+
},
|
|
194
|
+
},
|
|
195
|
+
required: ['field', 'operator', 'value'],
|
|
100
196
|
},
|
|
101
|
-
|
|
102
|
-
type: '
|
|
103
|
-
title: '
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
197
|
+
{
|
|
198
|
+
type: 'object',
|
|
199
|
+
title: 'TopicIdFilter',
|
|
200
|
+
properties: {
|
|
201
|
+
field: {
|
|
202
|
+
type: 'string',
|
|
203
|
+
title: 'Field',
|
|
204
|
+
description: '- `topic` - Deprecated',
|
|
205
|
+
enum: ['topic_id', 'topic'],
|
|
206
|
+
},
|
|
207
|
+
operator: {
|
|
208
|
+
type: 'string',
|
|
209
|
+
title: 'Operator',
|
|
210
|
+
enum: ['is', 'not_is', 'in', 'not_in'],
|
|
211
|
+
},
|
|
212
|
+
value: {
|
|
213
|
+
anyOf: [
|
|
214
|
+
{
|
|
215
|
+
type: 'string',
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
type: 'array',
|
|
219
|
+
items: {
|
|
220
|
+
type: 'string',
|
|
221
|
+
},
|
|
222
|
+
},
|
|
223
|
+
],
|
|
224
|
+
title: 'Value',
|
|
225
|
+
},
|
|
226
|
+
},
|
|
227
|
+
required: ['field', 'operator', 'value'],
|
|
115
228
|
},
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
229
|
+
{
|
|
230
|
+
type: 'object',
|
|
231
|
+
title: 'ModelIdFilter',
|
|
232
|
+
properties: {
|
|
233
|
+
field: {
|
|
234
|
+
type: 'string',
|
|
235
|
+
title: 'Field',
|
|
236
|
+
description: '- `model` - Deprecated',
|
|
237
|
+
enum: ['model_id', 'model'],
|
|
238
|
+
},
|
|
239
|
+
operator: {
|
|
240
|
+
type: 'string',
|
|
241
|
+
title: 'Operator',
|
|
242
|
+
enum: ['is', 'not_is', 'in', 'not_in'],
|
|
243
|
+
},
|
|
244
|
+
value: {
|
|
245
|
+
anyOf: [
|
|
246
|
+
{
|
|
247
|
+
type: 'string',
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
type: 'array',
|
|
251
|
+
items: {
|
|
252
|
+
type: 'string',
|
|
253
|
+
},
|
|
254
|
+
},
|
|
255
|
+
],
|
|
256
|
+
title: 'Value',
|
|
257
|
+
},
|
|
258
|
+
},
|
|
259
|
+
required: ['field', 'operator', 'value'],
|
|
144
260
|
},
|
|
145
|
-
|
|
146
|
-
|
|
261
|
+
{
|
|
262
|
+
type: 'object',
|
|
263
|
+
title: 'TagIdFilter',
|
|
264
|
+
properties: {
|
|
265
|
+
field: {
|
|
266
|
+
type: 'string',
|
|
267
|
+
title: 'Field',
|
|
268
|
+
description: '- `tag` - Deprecated',
|
|
269
|
+
enum: ['tag_id', 'tag'],
|
|
270
|
+
},
|
|
271
|
+
operator: {
|
|
272
|
+
type: 'string',
|
|
273
|
+
title: 'Operator',
|
|
274
|
+
enum: ['is', 'not_is', 'in', 'not_in'],
|
|
275
|
+
},
|
|
276
|
+
value: {
|
|
277
|
+
anyOf: [
|
|
278
|
+
{
|
|
279
|
+
type: 'string',
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
type: 'array',
|
|
283
|
+
items: {
|
|
284
|
+
type: 'string',
|
|
285
|
+
},
|
|
286
|
+
},
|
|
287
|
+
],
|
|
288
|
+
title: 'Value',
|
|
289
|
+
},
|
|
290
|
+
},
|
|
291
|
+
required: ['field', 'operator', 'value'],
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
type: 'object',
|
|
295
|
+
title: 'UrlFilter',
|
|
296
|
+
description: 'Filter by URL',
|
|
297
|
+
properties: {
|
|
298
|
+
field: {
|
|
299
|
+
type: 'string',
|
|
300
|
+
title: 'Field',
|
|
301
|
+
enum: ['url'],
|
|
302
|
+
},
|
|
303
|
+
operator: {
|
|
304
|
+
type: 'string',
|
|
305
|
+
title: 'Operator',
|
|
306
|
+
enum: [
|
|
307
|
+
'is',
|
|
308
|
+
'not_is',
|
|
309
|
+
'in',
|
|
310
|
+
'not_in',
|
|
311
|
+
'contains',
|
|
312
|
+
'not_contains',
|
|
313
|
+
'matches',
|
|
314
|
+
'contains_case_insensitive',
|
|
315
|
+
'not_contains_case_insensitive',
|
|
316
|
+
],
|
|
317
|
+
},
|
|
318
|
+
value: {
|
|
319
|
+
anyOf: [
|
|
320
|
+
{
|
|
321
|
+
type: 'string',
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
type: 'array',
|
|
325
|
+
items: {
|
|
326
|
+
type: 'string',
|
|
327
|
+
},
|
|
328
|
+
},
|
|
329
|
+
],
|
|
330
|
+
title: 'Value',
|
|
331
|
+
},
|
|
332
|
+
},
|
|
333
|
+
required: ['field', 'operator', 'value'],
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
type: 'object',
|
|
337
|
+
title: 'RootDomainFilter',
|
|
338
|
+
description: 'Filter by root domain',
|
|
339
|
+
properties: {
|
|
340
|
+
field: {
|
|
341
|
+
type: 'string',
|
|
342
|
+
title: 'Field',
|
|
343
|
+
enum: ['root_domain'],
|
|
344
|
+
},
|
|
345
|
+
operator: {
|
|
346
|
+
type: 'string',
|
|
347
|
+
title: 'Operator',
|
|
348
|
+
enum: [
|
|
349
|
+
'is',
|
|
350
|
+
'not_is',
|
|
351
|
+
'in',
|
|
352
|
+
'not_in',
|
|
353
|
+
'contains',
|
|
354
|
+
'not_contains',
|
|
355
|
+
'matches',
|
|
356
|
+
'contains_case_insensitive',
|
|
357
|
+
'not_contains_case_insensitive',
|
|
358
|
+
],
|
|
359
|
+
},
|
|
360
|
+
value: {
|
|
361
|
+
anyOf: [
|
|
362
|
+
{
|
|
363
|
+
type: 'string',
|
|
364
|
+
},
|
|
365
|
+
{
|
|
366
|
+
type: 'array',
|
|
367
|
+
items: {
|
|
368
|
+
type: 'string',
|
|
369
|
+
},
|
|
370
|
+
},
|
|
371
|
+
],
|
|
372
|
+
title: 'Value',
|
|
373
|
+
},
|
|
374
|
+
},
|
|
375
|
+
required: ['field', 'operator', 'value'],
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
type: 'object',
|
|
379
|
+
title: 'PromptTypeFilter',
|
|
380
|
+
description: 'Filter by prompt type (visibility or sentiment)',
|
|
381
|
+
properties: {
|
|
382
|
+
field: {
|
|
383
|
+
type: 'string',
|
|
384
|
+
title: 'Field',
|
|
385
|
+
enum: ['prompt_type'],
|
|
386
|
+
},
|
|
387
|
+
operator: {
|
|
388
|
+
type: 'string',
|
|
389
|
+
title: 'Operator',
|
|
390
|
+
enum: [
|
|
391
|
+
'is',
|
|
392
|
+
'not_is',
|
|
393
|
+
'in',
|
|
394
|
+
'not_in',
|
|
395
|
+
'contains',
|
|
396
|
+
'not_contains',
|
|
397
|
+
'matches',
|
|
398
|
+
'contains_case_insensitive',
|
|
399
|
+
'not_contains_case_insensitive',
|
|
400
|
+
],
|
|
401
|
+
},
|
|
402
|
+
value: {
|
|
403
|
+
anyOf: [
|
|
404
|
+
{
|
|
405
|
+
type: 'string',
|
|
406
|
+
enum: ['visibility', 'sentiment'],
|
|
407
|
+
},
|
|
408
|
+
{
|
|
409
|
+
type: 'array',
|
|
410
|
+
items: {
|
|
411
|
+
type: 'string',
|
|
412
|
+
enum: ['visibility', 'sentiment'],
|
|
413
|
+
},
|
|
414
|
+
},
|
|
415
|
+
],
|
|
416
|
+
title: 'Value',
|
|
417
|
+
},
|
|
418
|
+
},
|
|
419
|
+
required: ['field', 'operator', 'value'],
|
|
420
|
+
},
|
|
421
|
+
],
|
|
422
|
+
description: 'Filter by hostname',
|
|
147
423
|
},
|
|
148
424
|
},
|
|
149
425
|
order_by: {
|
|
@@ -156,12 +432,6 @@ export const tool: Tool = {
|
|
|
156
432
|
pagination: {
|
|
157
433
|
$ref: '#/$defs/pagination',
|
|
158
434
|
},
|
|
159
|
-
jq_filter: {
|
|
160
|
-
type: 'string',
|
|
161
|
-
title: 'jq Filter',
|
|
162
|
-
description:
|
|
163
|
-
'A jq filter to apply to the response to include certain fields. Consult the output schema in the tool description to see the fields that are available.\n\nFor example: to include only the `name` field in every object of a results array, you can provide ".results[].name".\n\nFor more information, see the [jq documentation](https://jqlang.org/manual/).',
|
|
164
|
-
},
|
|
165
435
|
},
|
|
166
436
|
required: ['category_id', 'end_date', 'metrics', 'start_date'],
|
|
167
437
|
$defs: {
|
|
@@ -188,8 +458,8 @@ export const tool: Tool = {
|
|
|
188
458
|
};
|
|
189
459
|
|
|
190
460
|
export const handler = async (client: Profound, args: Record<string, unknown> | undefined) => {
|
|
191
|
-
const
|
|
192
|
-
return asTextContentResult(await
|
|
461
|
+
const body = args as any;
|
|
462
|
+
return asTextContentResult(await client.reports.citations(body));
|
|
193
463
|
};
|
|
194
464
|
|
|
195
465
|
export default { metadata, tool, handler };
|