1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "beforeManifest": `{
12 "tools": [
13 {
14 "name": "get_current_time",
15 "description": "Get current time in a specific timezone",
16 "inputSchema": {
17 "type": "object",
18 "properties": {
19 "timezone": {
20 "type": "string",
21 "default": "UTC"
22 }
23 },
24 "required": []
25 }
26 },
27 {
28 "name": "convert_time",
29 "description": "Convert time between timezones",
30 "inputSchema": {
31 "type": "object",
32 "properties": {
33 "source_timezone": {
34 "type": "string",
35 "default": "UTC"
36 },
37 "time": {
38 "type": "string"
39 },
40 "target_timezone": {
41 "type": "string",
42 "default": "UTC"
43 }
44 },
45 "required": [
46 "time"
47 ]
48 }
49 }
50 ]
51}`,
52 "afterManifest": `{
53 "tools": [
54 {
55 "name": "get_current_time",
56 "description": "Get current time in a specific timezone",
57 "inputSchema": {
58 "type": "object",
59 "properties": {
60 "timezone": {
61 "type": "string",
62 "default": "UTC"
63 }
64 },
65 "required": []
66 }
67 },
68 {
69 "name": "convert_time",
70 "description": "Convert time between timezones",
71 "inputSchema": {
72 "type": "object",
73 "properties": {
74 "source_timezone": {
75 "type": "string",
76 "default": "UTC"
77 },
78 "time": {
79 "type": "string"
80 },
81 "target_timezone": {
82 "type": "string",
83 "default": "UTC"
84 }
85 },
86 "required": [
87 "time"
88 ]
89 }
90 },
91 {
92 "name": "get_time_ago",
93 "description": "Look up the local time for a past time offset",
94 "inputSchema": {
95 "type": "object",
96 "properties": {
97 "timezone": {
98 "type": "string",
99 "default": "UTC"
100 },
101 "days_ago": {
102 "type": "integer",
103 "minimum": 0,
104 "default": 0
105 },
106 "hours_ago": {
107 "type": "integer",
108 "minimum": 0,
109 "default": 0
110 },
111 "minutes_ago": {
112 "type": "integer",
113 "minimum": 0,
114 "default": 0
115 },
116 "seconds_ago": {
117 "type": "integer",
118 "minimum": 0,
119 "default": 0
120 }
121 },
122 "required": []
123 }
124 }
125 ]
126}`
127};
128
129
130const run = await client.actor("merciful_goldenlarch/mcp-manifest-diff").call(input);
131
132
133console.log('Results from dataset');
134console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
135const { items } = await client.dataset(run.defaultDatasetId).listItems();
136items.forEach((item) => {
137 console.dir(item);
138});
139
140