@cyanheads/seerr-mcp-server 0.1.0 → 0.1.2
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/AGENTS.md +19 -16
- package/CLAUDE.md +19 -16
- package/Dockerfile +11 -7
- package/LICENSE +1 -1
- package/README.md +7 -7
- package/changelog/0.1.x/0.1.1.md +30 -0
- package/changelog/0.1.x/0.1.2.md +22 -0
- package/changelog/template.md +5 -3
- package/dist/index.js +0 -0
- package/dist/mcp-server/resources/definitions/index.d.ts +1 -0
- package/dist/mcp-server/resources/definitions/index.d.ts.map +1 -1
- package/dist/mcp-server/resources/definitions/request.resource.d.ts +7 -3
- package/dist/mcp-server/resources/definitions/request.resource.d.ts.map +1 -1
- package/dist/mcp-server/resources/definitions/request.resource.js +17 -5
- package/dist/mcp-server/resources/definitions/request.resource.js.map +1 -1
- package/dist/mcp-server/tools/definitions/index.d.ts +152 -142
- package/dist/mcp-server/tools/definitions/index.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/list-requests.tool.d.ts +16 -9
- package/dist/mcp-server/tools/definitions/list-requests.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/list-requests.tool.js +74 -11
- package/dist/mcp-server/tools/definitions/list-requests.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/request-media.tool.d.ts +7 -2
- package/dist/mcp-server/tools/definitions/request-media.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/request-media.tool.js +18 -4
- package/dist/mcp-server/tools/definitions/request-media.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/request-status.tool.d.ts +4 -2
- package/dist/mcp-server/tools/definitions/request-status.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/request-status.tool.js +11 -4
- package/dist/mcp-server/tools/definitions/request-status.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/search-media.tool.d.ts +1 -1
- package/dist/services/seerr/normalizers.d.ts +5 -1
- package/dist/services/seerr/normalizers.d.ts.map +1 -1
- package/dist/services/seerr/normalizers.js +21 -7
- package/dist/services/seerr/normalizers.js.map +1 -1
- package/dist/services/seerr/seerr-service.d.ts +12 -2
- package/dist/services/seerr/seerr-service.d.ts.map +1 -1
- package/dist/services/seerr/seerr-service.js +42 -16
- package/dist/services/seerr/seerr-service.js.map +1 -1
- package/dist/services/seerr/titles.d.ts +47 -0
- package/dist/services/seerr/titles.d.ts.map +1 -0
- package/dist/services/seerr/titles.js +96 -0
- package/dist/services/seerr/titles.js.map +1 -0
- package/package.json +11 -9
- package/server.json +3 -3
|
@@ -6,6 +6,147 @@
|
|
|
6
6
|
* @module mcp-server/tools/definitions/index
|
|
7
7
|
*/
|
|
8
8
|
export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
9
|
+
mediaType: import("zod").ZodEnum<{
|
|
10
|
+
movie: "movie";
|
|
11
|
+
tv: "tv";
|
|
12
|
+
}>;
|
|
13
|
+
tmdbId: import("zod").ZodNumber;
|
|
14
|
+
mode: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
15
|
+
preview: "preview";
|
|
16
|
+
request: "request";
|
|
17
|
+
}>>;
|
|
18
|
+
is4k: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
19
|
+
seasons: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodLiteral<"all">, import("zod").ZodArray<import("zod").ZodNumber>]>>;
|
|
20
|
+
serverId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
21
|
+
profileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
22
|
+
rootFolder: import("zod").ZodOptional<import("zod").ZodString>;
|
|
23
|
+
languageProfileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
24
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
25
|
+
mode: import("zod").ZodEnum<{
|
|
26
|
+
preview: "preview";
|
|
27
|
+
request: "request";
|
|
28
|
+
}>;
|
|
29
|
+
resolved: import("zod").ZodObject<{
|
|
30
|
+
tmdbId: import("zod").ZodNumber;
|
|
31
|
+
mediaType: import("zod").ZodEnum<{
|
|
32
|
+
movie: "movie";
|
|
33
|
+
tv: "tv";
|
|
34
|
+
}>;
|
|
35
|
+
title: import("zod").ZodString;
|
|
36
|
+
year: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
37
|
+
}, import("zod/v4/core").$strip>;
|
|
38
|
+
capability: import("zod").ZodObject<{
|
|
39
|
+
is4kEnabled: import("zod").ZodBoolean;
|
|
40
|
+
partialRequestsEnabled: import("zod").ZodBoolean;
|
|
41
|
+
}, import("zod/v4/core").$strip>;
|
|
42
|
+
payload: import("zod").ZodObject<{
|
|
43
|
+
mediaType: import("zod").ZodEnum<{
|
|
44
|
+
movie: "movie";
|
|
45
|
+
tv: "tv";
|
|
46
|
+
}>;
|
|
47
|
+
mediaId: import("zod").ZodNumber;
|
|
48
|
+
is4k: import("zod").ZodBoolean;
|
|
49
|
+
seasons: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodLiteral<"all">, import("zod").ZodArray<import("zod").ZodNumber>]>>;
|
|
50
|
+
serverId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
51
|
+
profileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
52
|
+
rootFolder: import("zod").ZodOptional<import("zod").ZodString>;
|
|
53
|
+
languageProfileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
54
|
+
}, import("zod/v4/core").$strip>;
|
|
55
|
+
existingRequest: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
56
|
+
requestId: import("zod").ZodNumber;
|
|
57
|
+
status: import("zod").ZodObject<{
|
|
58
|
+
raw: import("zod").ZodNumber;
|
|
59
|
+
label: import("zod").ZodString;
|
|
60
|
+
}, import("zod/v4/core").$strip>;
|
|
61
|
+
is4k: import("zod").ZodBoolean;
|
|
62
|
+
}, import("zod/v4/core").$strip>>;
|
|
63
|
+
created: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
64
|
+
requestId: import("zod").ZodNumber;
|
|
65
|
+
requestStatus: import("zod").ZodObject<{
|
|
66
|
+
raw: import("zod").ZodNumber;
|
|
67
|
+
label: import("zod").ZodString;
|
|
68
|
+
}, import("zod/v4/core").$strip>;
|
|
69
|
+
mediaStatus: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
70
|
+
raw: import("zod").ZodNumber;
|
|
71
|
+
label: import("zod").ZodString;
|
|
72
|
+
}, import("zod/v4/core").$strip>>;
|
|
73
|
+
}, import("zod/v4/core").$strip>>;
|
|
74
|
+
}, import("zod/v4/core").$strip>, readonly [{
|
|
75
|
+
readonly reason: "media_not_found";
|
|
76
|
+
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
|
|
77
|
+
readonly when: "tmdbId does not resolve to a movie/show (Seerr 500 \"Unable to retrieve movie.\").";
|
|
78
|
+
readonly recovery: "Run seerr_search_media to get the correct tmdbId and retry with the matching mediaType.";
|
|
79
|
+
}, {
|
|
80
|
+
readonly reason: "seasons_required";
|
|
81
|
+
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
82
|
+
readonly when: "mediaType is tv but no seasons were provided.";
|
|
83
|
+
readonly recovery: "Provide seasons: \"all\" for the whole series or an explicit list like [1,2].";
|
|
84
|
+
}, {
|
|
85
|
+
readonly reason: "four_k_not_enabled";
|
|
86
|
+
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
87
|
+
readonly when: "is4k:true but the instance has no 4K configured for this media type.";
|
|
88
|
+
readonly recovery: "Resubmit with is4k:false, or check seerr_service_options for 4K availability first.";
|
|
89
|
+
}, {
|
|
90
|
+
readonly reason: "partial_requests_disabled";
|
|
91
|
+
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
92
|
+
readonly when: "an explicit season list was given but the instance disallows partial requests.";
|
|
93
|
+
readonly recovery: "Use seasons:\"all\" to request the full series instead of specific seasons.";
|
|
94
|
+
}, {
|
|
95
|
+
readonly reason: "special_episodes_not_enabled";
|
|
96
|
+
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
97
|
+
readonly when: "the season list includes 0 (Specials) but the instance has special episodes disabled.";
|
|
98
|
+
readonly recovery: "Drop season 0 from the list, or confirm specialEpisodesEnabled via seerr_service_options first.";
|
|
99
|
+
}, {
|
|
100
|
+
readonly reason: "duplicate_request";
|
|
101
|
+
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
102
|
+
readonly when: "Seerr rejects the POST because an identical request already exists.";
|
|
103
|
+
readonly recovery: "Check the existingRequest in this output; track it with seerr_request_status instead of re-requesting.";
|
|
104
|
+
}, {
|
|
105
|
+
readonly reason: "request_cancelled";
|
|
106
|
+
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
107
|
+
readonly when: "the user declined the elicit confirmation.";
|
|
108
|
+
readonly recovery: "Re-run with mode:request and confirm the prompt if you intend to submit the request.";
|
|
109
|
+
}], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
110
|
+
query: import("zod").ZodString;
|
|
111
|
+
mediaType: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
112
|
+
all: "all";
|
|
113
|
+
movie: "movie";
|
|
114
|
+
tv: "tv";
|
|
115
|
+
}>>;
|
|
116
|
+
page: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
117
|
+
language: import("zod").ZodOptional<import("zod").ZodString>;
|
|
118
|
+
limit: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
119
|
+
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
120
|
+
results: import("zod").ZodArray<import("zod").ZodObject<{
|
|
121
|
+
tmdbId: import("zod").ZodNumber;
|
|
122
|
+
mediaType: import("zod").ZodEnum<{
|
|
123
|
+
movie: "movie";
|
|
124
|
+
tv: "tv";
|
|
125
|
+
}>;
|
|
126
|
+
title: import("zod").ZodString;
|
|
127
|
+
year: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
128
|
+
overview: import("zod").ZodOptional<import("zod").ZodString>;
|
|
129
|
+
voteAverage: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
130
|
+
tracked: import("zod").ZodBoolean;
|
|
131
|
+
availability: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
132
|
+
status: import("zod").ZodObject<{
|
|
133
|
+
raw: import("zod").ZodNumber;
|
|
134
|
+
label: import("zod").ZodString;
|
|
135
|
+
}, import("zod/v4/core").$strip>;
|
|
136
|
+
status4k: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
137
|
+
raw: import("zod").ZodNumber;
|
|
138
|
+
label: import("zod").ZodString;
|
|
139
|
+
}, import("zod/v4/core").$strip>>;
|
|
140
|
+
}, import("zod/v4/core").$strip>>;
|
|
141
|
+
}, import("zod/v4/core").$strip>>;
|
|
142
|
+
}, import("zod/v4/core").$strip>, undefined, {
|
|
143
|
+
readonly effectiveQuery: import("zod").ZodString;
|
|
144
|
+
readonly totalCount: import("zod").ZodNumber;
|
|
145
|
+
readonly truncated: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
146
|
+
readonly shown: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
147
|
+
readonly cap: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
148
|
+
readonly notice: import("zod").ZodOptional<import("zod").ZodString>;
|
|
149
|
+
}> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
9
150
|
mediaType: import("zod").ZodEnum<{
|
|
10
151
|
movie: "movie";
|
|
11
152
|
tv: "tv";
|
|
@@ -61,20 +202,20 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
|
|
|
61
202
|
readonly recovery: "Call seerr_search_media to find the correct tmdbId, then retry with the exact ID and matching mediaType.";
|
|
62
203
|
}], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
63
204
|
filter: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
64
|
-
|
|
205
|
+
all: "all";
|
|
65
206
|
approved: "approved";
|
|
66
|
-
failed: "failed";
|
|
67
|
-
completed: "completed";
|
|
68
|
-
processing: "processing";
|
|
69
207
|
available: "available";
|
|
208
|
+
completed: "completed";
|
|
70
209
|
deleted: "deleted";
|
|
71
|
-
|
|
210
|
+
failed: "failed";
|
|
211
|
+
pending: "pending";
|
|
212
|
+
processing: "processing";
|
|
72
213
|
unavailable: "unavailable";
|
|
73
214
|
}>>;
|
|
74
215
|
mediaType: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
216
|
+
all: "all";
|
|
75
217
|
movie: "movie";
|
|
76
218
|
tv: "tv";
|
|
77
|
-
all: "all";
|
|
78
219
|
}>>;
|
|
79
220
|
requestedById: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
80
221
|
sort: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
@@ -87,6 +228,7 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
|
|
|
87
228
|
}>>;
|
|
88
229
|
take: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
89
230
|
skip: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
231
|
+
includeTitles: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
90
232
|
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
91
233
|
requests: import("zod").ZodArray<import("zod").ZodObject<{
|
|
92
234
|
requestId: import("zod").ZodNumber;
|
|
@@ -104,6 +246,10 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
|
|
|
104
246
|
raw: import("zod").ZodNumber;
|
|
105
247
|
label: import("zod").ZodString;
|
|
106
248
|
}, import("zod/v4/core").$strip>>;
|
|
249
|
+
mediaStatus4k: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
250
|
+
raw: import("zod").ZodNumber;
|
|
251
|
+
label: import("zod").ZodString;
|
|
252
|
+
}, import("zod/v4/core").$strip>>;
|
|
107
253
|
is4k: import("zod").ZodBoolean;
|
|
108
254
|
seasons: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodNumber>>;
|
|
109
255
|
requestedBy: import("zod").ZodObject<{
|
|
@@ -124,102 +270,6 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
|
|
|
124
270
|
readonly cap: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
125
271
|
readonly notice: import("zod").ZodOptional<import("zod").ZodString>;
|
|
126
272
|
}> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
127
|
-
mediaType: import("zod").ZodEnum<{
|
|
128
|
-
movie: "movie";
|
|
129
|
-
tv: "tv";
|
|
130
|
-
}>;
|
|
131
|
-
tmdbId: import("zod").ZodNumber;
|
|
132
|
-
mode: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
133
|
-
request: "request";
|
|
134
|
-
preview: "preview";
|
|
135
|
-
}>>;
|
|
136
|
-
is4k: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
137
|
-
seasons: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodLiteral<"all">, import("zod").ZodArray<import("zod").ZodNumber>]>>;
|
|
138
|
-
serverId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
139
|
-
profileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
140
|
-
rootFolder: import("zod").ZodOptional<import("zod").ZodString>;
|
|
141
|
-
languageProfileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
142
|
-
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
143
|
-
mode: import("zod").ZodEnum<{
|
|
144
|
-
request: "request";
|
|
145
|
-
preview: "preview";
|
|
146
|
-
}>;
|
|
147
|
-
resolved: import("zod").ZodObject<{
|
|
148
|
-
tmdbId: import("zod").ZodNumber;
|
|
149
|
-
mediaType: import("zod").ZodEnum<{
|
|
150
|
-
movie: "movie";
|
|
151
|
-
tv: "tv";
|
|
152
|
-
}>;
|
|
153
|
-
title: import("zod").ZodString;
|
|
154
|
-
year: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
155
|
-
}, import("zod/v4/core").$strip>;
|
|
156
|
-
capability: import("zod").ZodObject<{
|
|
157
|
-
is4kEnabled: import("zod").ZodBoolean;
|
|
158
|
-
partialRequestsEnabled: import("zod").ZodBoolean;
|
|
159
|
-
}, import("zod/v4/core").$strip>;
|
|
160
|
-
payload: import("zod").ZodObject<{
|
|
161
|
-
mediaType: import("zod").ZodEnum<{
|
|
162
|
-
movie: "movie";
|
|
163
|
-
tv: "tv";
|
|
164
|
-
}>;
|
|
165
|
-
mediaId: import("zod").ZodNumber;
|
|
166
|
-
is4k: import("zod").ZodBoolean;
|
|
167
|
-
seasons: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodLiteral<"all">, import("zod").ZodArray<import("zod").ZodNumber>]>>;
|
|
168
|
-
serverId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
169
|
-
profileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
170
|
-
rootFolder: import("zod").ZodOptional<import("zod").ZodString>;
|
|
171
|
-
languageProfileId: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
172
|
-
}, import("zod/v4/core").$strip>;
|
|
173
|
-
existingRequest: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
174
|
-
requestId: import("zod").ZodNumber;
|
|
175
|
-
status: import("zod").ZodObject<{
|
|
176
|
-
raw: import("zod").ZodNumber;
|
|
177
|
-
label: import("zod").ZodString;
|
|
178
|
-
}, import("zod/v4/core").$strip>;
|
|
179
|
-
is4k: import("zod").ZodBoolean;
|
|
180
|
-
}, import("zod/v4/core").$strip>>;
|
|
181
|
-
created: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
182
|
-
requestId: import("zod").ZodNumber;
|
|
183
|
-
requestStatus: import("zod").ZodObject<{
|
|
184
|
-
raw: import("zod").ZodNumber;
|
|
185
|
-
label: import("zod").ZodString;
|
|
186
|
-
}, import("zod/v4/core").$strip>;
|
|
187
|
-
mediaStatus: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
188
|
-
raw: import("zod").ZodNumber;
|
|
189
|
-
label: import("zod").ZodString;
|
|
190
|
-
}, import("zod/v4/core").$strip>>;
|
|
191
|
-
}, import("zod/v4/core").$strip>>;
|
|
192
|
-
}, import("zod/v4/core").$strip>, readonly [{
|
|
193
|
-
readonly reason: "media_not_found";
|
|
194
|
-
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.NotFound;
|
|
195
|
-
readonly when: "tmdbId does not resolve to a movie/show (Seerr 500 \"Unable to retrieve movie.\").";
|
|
196
|
-
readonly recovery: "Run seerr_search_media to get the correct tmdbId and retry with the matching mediaType.";
|
|
197
|
-
}, {
|
|
198
|
-
readonly reason: "seasons_required";
|
|
199
|
-
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
200
|
-
readonly when: "mediaType is tv but no seasons were provided.";
|
|
201
|
-
readonly recovery: "Provide seasons: \"all\" for the whole series or an explicit list like [1,2].";
|
|
202
|
-
}, {
|
|
203
|
-
readonly reason: "four_k_not_enabled";
|
|
204
|
-
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
205
|
-
readonly when: "is4k:true but the instance has no 4K configured for this media type.";
|
|
206
|
-
readonly recovery: "Resubmit with is4k:false, or check seerr_service_options for 4K availability first.";
|
|
207
|
-
}, {
|
|
208
|
-
readonly reason: "partial_requests_disabled";
|
|
209
|
-
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
210
|
-
readonly when: "an explicit season list was given but the instance disallows partial requests.";
|
|
211
|
-
readonly recovery: "Use seasons:\"all\" to request the full series instead of specific seasons.";
|
|
212
|
-
}, {
|
|
213
|
-
readonly reason: "duplicate_request";
|
|
214
|
-
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
215
|
-
readonly when: "Seerr rejects the POST because an identical request already exists.";
|
|
216
|
-
readonly recovery: "Check the existingRequest in this output; track it with seerr_request_status instead of re-requesting.";
|
|
217
|
-
}, {
|
|
218
|
-
readonly reason: "request_cancelled";
|
|
219
|
-
readonly code: import("@cyanheads/mcp-ts-core/errors").JsonRpcErrorCode.InvalidParams;
|
|
220
|
-
readonly when: "the user declined the elicit confirmation.";
|
|
221
|
-
readonly recovery: "Re-run with mode:request and confirm the prompt if you intend to submit the request.";
|
|
222
|
-
}], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
223
273
|
requestId: import("zod").ZodNumber;
|
|
224
274
|
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
225
275
|
requestId: import("zod").ZodNumber;
|
|
@@ -261,46 +311,6 @@ export declare const allToolDefinitions: (import("@cyanheads/mcp-ts-core").ToolD
|
|
|
261
311
|
readonly when: "No request exists with the given ID (Seerr returns HTTP 404 \"Request not found.\").";
|
|
262
312
|
readonly recovery: "List requests with seerr_list_requests to find a valid requestId, then retry.";
|
|
263
313
|
}], undefined> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
264
|
-
query: import("zod").ZodString;
|
|
265
|
-
mediaType: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
266
|
-
movie: "movie";
|
|
267
|
-
tv: "tv";
|
|
268
|
-
all: "all";
|
|
269
|
-
}>>;
|
|
270
|
-
page: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
271
|
-
language: import("zod").ZodOptional<import("zod").ZodString>;
|
|
272
|
-
limit: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
273
|
-
}, import("zod/v4/core").$strip>, import("zod").ZodObject<{
|
|
274
|
-
results: import("zod").ZodArray<import("zod").ZodObject<{
|
|
275
|
-
tmdbId: import("zod").ZodNumber;
|
|
276
|
-
mediaType: import("zod").ZodEnum<{
|
|
277
|
-
movie: "movie";
|
|
278
|
-
tv: "tv";
|
|
279
|
-
}>;
|
|
280
|
-
title: import("zod").ZodString;
|
|
281
|
-
year: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
282
|
-
overview: import("zod").ZodOptional<import("zod").ZodString>;
|
|
283
|
-
voteAverage: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
284
|
-
tracked: import("zod").ZodBoolean;
|
|
285
|
-
availability: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
286
|
-
status: import("zod").ZodObject<{
|
|
287
|
-
raw: import("zod").ZodNumber;
|
|
288
|
-
label: import("zod").ZodString;
|
|
289
|
-
}, import("zod/v4/core").$strip>;
|
|
290
|
-
status4k: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
291
|
-
raw: import("zod").ZodNumber;
|
|
292
|
-
label: import("zod").ZodString;
|
|
293
|
-
}, import("zod/v4/core").$strip>>;
|
|
294
|
-
}, import("zod/v4/core").$strip>>;
|
|
295
|
-
}, import("zod/v4/core").$strip>>;
|
|
296
|
-
}, import("zod/v4/core").$strip>, undefined, {
|
|
297
|
-
readonly effectiveQuery: import("zod").ZodString;
|
|
298
|
-
readonly totalCount: import("zod").ZodNumber;
|
|
299
|
-
readonly truncated: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
300
|
-
readonly shown: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
301
|
-
readonly cap: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
302
|
-
readonly notice: import("zod").ZodOptional<import("zod").ZodString>;
|
|
303
|
-
}> | import("@cyanheads/mcp-ts-core").ToolDefinition<import("zod").ZodObject<{
|
|
304
314
|
service: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
305
315
|
all: "all";
|
|
306
316
|
radarr: "radarr";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AASH,eAAO,MAAM,kBAAkB
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AASH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAO9B,CAAC"}
|
|
@@ -2,28 +2,30 @@
|
|
|
2
2
|
* @fileoverview seerr_list_requests — review recent requests and their lifecycle.
|
|
3
3
|
* Wraps `GET /request`. Echoes the applied filters and decodes every numeric
|
|
4
4
|
* status. The media-type discriminator is the raw `type` field (not `mediaType`);
|
|
5
|
-
* `requestedBy` is PII-redacted
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* `requestedBy` is PII-redacted. The request object has no title field, so
|
|
6
|
+
* `title` is unpopulated unless `includeTitles` is set — that opt-in costs one
|
|
7
|
+
* media fetch per DISTINCT `(mediaType, tmdbId)` on the page, and rows that
|
|
8
|
+
* cannot be hydrated degrade to no title plus an enrichment notice. The total
|
|
9
|
+
* count comes from `pageInfo.results`.
|
|
8
10
|
* @module mcp-server/tools/definitions/list-requests.tool
|
|
9
11
|
*/
|
|
10
12
|
import { z } from '@cyanheads/mcp-ts-core';
|
|
11
13
|
export declare const listRequestsTool: import("@cyanheads/mcp-ts-core").ToolDefinition<z.ZodObject<{
|
|
12
14
|
filter: z.ZodDefault<z.ZodEnum<{
|
|
13
|
-
|
|
15
|
+
all: "all";
|
|
14
16
|
approved: "approved";
|
|
15
|
-
failed: "failed";
|
|
16
|
-
completed: "completed";
|
|
17
|
-
processing: "processing";
|
|
18
17
|
available: "available";
|
|
18
|
+
completed: "completed";
|
|
19
19
|
deleted: "deleted";
|
|
20
|
-
|
|
20
|
+
failed: "failed";
|
|
21
|
+
pending: "pending";
|
|
22
|
+
processing: "processing";
|
|
21
23
|
unavailable: "unavailable";
|
|
22
24
|
}>>;
|
|
23
25
|
mediaType: z.ZodDefault<z.ZodEnum<{
|
|
26
|
+
all: "all";
|
|
24
27
|
movie: "movie";
|
|
25
28
|
tv: "tv";
|
|
26
|
-
all: "all";
|
|
27
29
|
}>>;
|
|
28
30
|
requestedById: z.ZodOptional<z.ZodNumber>;
|
|
29
31
|
sort: z.ZodDefault<z.ZodEnum<{
|
|
@@ -36,6 +38,7 @@ export declare const listRequestsTool: import("@cyanheads/mcp-ts-core").ToolDefi
|
|
|
36
38
|
}>>;
|
|
37
39
|
take: z.ZodDefault<z.ZodNumber>;
|
|
38
40
|
skip: z.ZodDefault<z.ZodNumber>;
|
|
41
|
+
includeTitles: z.ZodDefault<z.ZodBoolean>;
|
|
39
42
|
}, z.core.$strip>, z.ZodObject<{
|
|
40
43
|
requests: z.ZodArray<z.ZodObject<{
|
|
41
44
|
requestId: z.ZodNumber;
|
|
@@ -53,6 +56,10 @@ export declare const listRequestsTool: import("@cyanheads/mcp-ts-core").ToolDefi
|
|
|
53
56
|
raw: z.ZodNumber;
|
|
54
57
|
label: z.ZodString;
|
|
55
58
|
}, z.core.$strip>>;
|
|
59
|
+
mediaStatus4k: z.ZodOptional<z.ZodObject<{
|
|
60
|
+
raw: z.ZodNumber;
|
|
61
|
+
label: z.ZodString;
|
|
62
|
+
}, z.core.$strip>>;
|
|
56
63
|
is4k: z.ZodBoolean;
|
|
57
64
|
seasons: z.ZodOptional<z.ZodArray<z.ZodNumber>>;
|
|
58
65
|
requestedBy: z.ZodObject<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-requests.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/list-requests.tool.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"list-requests.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/list-requests.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAgBjD,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+Q3B,CAAC"}
|
|
@@ -2,18 +2,25 @@
|
|
|
2
2
|
* @fileoverview seerr_list_requests — review recent requests and their lifecycle.
|
|
3
3
|
* Wraps `GET /request`. Echoes the applied filters and decodes every numeric
|
|
4
4
|
* status. The media-type discriminator is the raw `type` field (not `mediaType`);
|
|
5
|
-
* `requestedBy` is PII-redacted
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* `requestedBy` is PII-redacted. The request object has no title field, so
|
|
6
|
+
* `title` is unpopulated unless `includeTitles` is set — that opt-in costs one
|
|
7
|
+
* media fetch per DISTINCT `(mediaType, tmdbId)` on the page, and rows that
|
|
8
|
+
* cannot be hydrated degrade to no title plus an enrichment notice. The total
|
|
9
|
+
* count comes from `pageInfo.results`.
|
|
8
10
|
* @module mcp-server/tools/definitions/list-requests.tool
|
|
9
11
|
*/
|
|
10
12
|
import { tool, z } from '@cyanheads/mcp-ts-core';
|
|
11
13
|
import { normalizeSeasons, redactUser } from '../../../services/seerr/normalizers.js';
|
|
12
14
|
import { getSeerrService } from '../../../services/seerr/seerr-service.js';
|
|
13
15
|
import { decodeMediaStatus, decodeRequestStatus, StatusRef, statusText, } from '../../../services/seerr/status.js';
|
|
16
|
+
import { resolveTitles, titleKeyOf } from '../../../services/seerr/titles.js';
|
|
17
|
+
/** Pluralize "request" for a notice count. */
|
|
18
|
+
function requestCount(n) {
|
|
19
|
+
return `${n} request${n === 1 ? '' : 's'}`;
|
|
20
|
+
}
|
|
14
21
|
export const listRequestsTool = tool('seerr_list_requests', {
|
|
15
22
|
title: 'seerr-mcp-server: list requests',
|
|
16
|
-
description: 'List recent media requests with their lifecycle status. Filter by status, media type, and requester; echoes the applied filters and decodes every numeric status. Pass a requestId from the results to seerr_request_status for full detail. Titles are not on request objects
|
|
23
|
+
description: 'List recent media requests with their lifecycle status. Filter by status, media type, and requester; echoes the applied filters and decodes every numeric status. Pass a requestId from the results to seerr_request_status for full detail. Titles are not on request objects — set includeTitles to resolve them, or fetch one with seerr_get_media.',
|
|
17
24
|
annotations: { readOnlyHint: true, openWorldHint: true },
|
|
18
25
|
input: z.object({
|
|
19
26
|
filter: z
|
|
@@ -61,6 +68,10 @@ export const listRequestsTool = tool('seerr_list_requests', {
|
|
|
61
68
|
.min(0)
|
|
62
69
|
.default(0)
|
|
63
70
|
.describe('Number of requests to skip for pagination (offset). Use take+skip to page.'),
|
|
71
|
+
includeTitles: z
|
|
72
|
+
.boolean()
|
|
73
|
+
.default(false)
|
|
74
|
+
.describe('Resolve each row\'s title. Default false keeps the call to a single upstream read; true adds one media lookup per distinct title on the page (rows sharing a title, such as a 4K and a non-4K request, resolve once). Rows that cannot be resolved keep every other field and stay "Untitled".'),
|
|
64
75
|
}),
|
|
65
76
|
output: z.object({
|
|
66
77
|
requests: z
|
|
@@ -71,10 +82,11 @@ export const listRequestsTool = tool('seerr_list_requests', {
|
|
|
71
82
|
title: z
|
|
72
83
|
.string()
|
|
73
84
|
.optional()
|
|
74
|
-
.describe('Title of the requested media
|
|
85
|
+
.describe('Title of the requested media. Present only when includeTitles was set and the lookup succeeded — request objects carry no title field.'),
|
|
75
86
|
tmdbId: z.number().optional().describe('TMDB ID of the requested media.'),
|
|
76
87
|
requestStatus: StatusRef.describe('Decoded request status {raw,label}.'),
|
|
77
|
-
mediaStatus: StatusRef.optional().describe('Decoded availability of the
|
|
88
|
+
mediaStatus: StatusRef.optional().describe('Decoded availability of the non-4K copy {raw,label} (from media.status).'),
|
|
89
|
+
mediaStatus4k: StatusRef.optional().describe('Decoded availability of the 4K copy {raw,label} (from media.status4k). The 4K copy downloads through a separate Radarr/Sonarr service, so this is the field that tracks an is4k request.'),
|
|
78
90
|
is4k: z.boolean().describe('Whether this is a 4K request.'),
|
|
79
91
|
seasons: z
|
|
80
92
|
.array(z.number())
|
|
@@ -106,7 +118,10 @@ export const listRequestsTool = tool('seerr_list_requests', {
|
|
|
106
118
|
.describe('True when the page filled to the take limit (more may exist).'),
|
|
107
119
|
shown: z.number().optional().describe('Number of requests returned.'),
|
|
108
120
|
cap: z.number().optional().describe('The take limit that was applied.'),
|
|
109
|
-
notice: z
|
|
121
|
+
notice: z
|
|
122
|
+
.string()
|
|
123
|
+
.optional()
|
|
124
|
+
.describe('Combined guidance for this page: the paging hint when the result was capped, a broaden-the-filter hint when nothing matched, and disclosure when includeTitles left some rows without a title. All applicable parts are joined into this one field.'),
|
|
110
125
|
},
|
|
111
126
|
enrichmentTrailer: {
|
|
112
127
|
appliedFilters: {
|
|
@@ -125,17 +140,33 @@ export const listRequestsTool = tool('seerr_list_requests', {
|
|
|
125
140
|
...(typeof input.requestedById === 'number' ? { requestedById: input.requestedById } : {}),
|
|
126
141
|
}, ctx);
|
|
127
142
|
const rows = response.results ?? [];
|
|
143
|
+
const typeOf = (r) => r.type === 'tv' ? 'tv' : 'movie';
|
|
144
|
+
/**
|
|
145
|
+
* Hydration is opt-in because its cost scales with the page: with
|
|
146
|
+
* includeTitles unset this stays a single upstream read, exactly as before.
|
|
147
|
+
*/
|
|
148
|
+
const lookup = input.includeTitles
|
|
149
|
+
? await resolveTitles(rows.flatMap((r) => typeof r.media?.tmdbId === 'number'
|
|
150
|
+
? [{ mediaType: typeOf(r), tmdbId: r.media.tmdbId }]
|
|
151
|
+
: []), seerr, ctx)
|
|
152
|
+
: undefined;
|
|
128
153
|
const requests = rows.map((r) => {
|
|
129
|
-
const mediaType = r
|
|
154
|
+
const mediaType = typeOf(r);
|
|
130
155
|
const seasons = normalizeSeasons(r);
|
|
131
156
|
const tmdbId = r.media?.tmdbId;
|
|
157
|
+
const title = lookup && typeof tmdbId === 'number'
|
|
158
|
+
? lookup.titles.get(titleKeyOf(mediaType, tmdbId))
|
|
159
|
+
: undefined;
|
|
132
160
|
const mediaStatus = typeof r.media?.status === 'number' ? decodeMediaStatus(r.media.status) : undefined;
|
|
161
|
+
const mediaStatus4k = typeof r.media?.status4k === 'number' ? decodeMediaStatus(r.media.status4k) : undefined;
|
|
133
162
|
return {
|
|
134
163
|
requestId: r.id,
|
|
135
164
|
mediaType,
|
|
165
|
+
...(title ? { title } : {}),
|
|
136
166
|
...(typeof tmdbId === 'number' ? { tmdbId } : {}),
|
|
137
167
|
requestStatus: decodeRequestStatus(r.status ?? 1),
|
|
138
168
|
...(mediaStatus ? { mediaStatus } : {}),
|
|
169
|
+
...(mediaStatus4k ? { mediaStatus4k } : {}),
|
|
139
170
|
is4k: r.is4k === true,
|
|
140
171
|
...(seasons.length > 0 ? { seasons } : {}),
|
|
141
172
|
requestedBy: r.requestedBy ? redactUser(r.requestedBy) : { id: 0, displayName: 'Unknown' },
|
|
@@ -147,16 +178,46 @@ export const listRequestsTool = tool('seerr_list_requests', {
|
|
|
147
178
|
ctx.enrich({
|
|
148
179
|
appliedFilters: { filter: input.filter, mediaType: input.mediaType, sort: input.sort },
|
|
149
180
|
});
|
|
181
|
+
const notices = [];
|
|
182
|
+
if (requests.length === 0) {
|
|
183
|
+
notices.push(`No requests matched filter="${input.filter}", mediaType="${input.mediaType}". Try filter="all" or a different mediaType.`);
|
|
184
|
+
}
|
|
185
|
+
if (lookup) {
|
|
186
|
+
/**
|
|
187
|
+
* Two distinct outcomes, kept apart on purpose: a row with no tmdbId was
|
|
188
|
+
* never hydratable (normal), while a row that had one and still has no
|
|
189
|
+
* title had its lookup attempted and fail.
|
|
190
|
+
*/
|
|
191
|
+
const noTmdbId = requests.filter((r) => r.tmdbId === undefined).length;
|
|
192
|
+
const unresolved = requests.filter((r) => r.tmdbId !== undefined && r.title === undefined).length;
|
|
193
|
+
if (unresolved > 0) {
|
|
194
|
+
notices.push(`Title lookup failed for ${requestCount(unresolved)}; those rows keep every other field.`);
|
|
195
|
+
}
|
|
196
|
+
if (noTmdbId > 0) {
|
|
197
|
+
notices.push(`Titles unavailable for ${requestCount(noTmdbId)} with no tmdbId.`);
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
/**
|
|
201
|
+
* `enrich.truncated` writes the shared `notice` field, so a hydration
|
|
202
|
+
* disclosure and the pagination hint would silently overwrite each other.
|
|
203
|
+
* Compose them into one string when both apply.
|
|
204
|
+
*/
|
|
150
205
|
if (requests.length >= input.take && requests.length < total) {
|
|
151
|
-
|
|
206
|
+
const pagination = `Results capped at ${input.take}; showing ${requests.length} of ${total}. Raise take or page with skip.`;
|
|
207
|
+
ctx.enrich.truncated({
|
|
208
|
+
shown: requests.length,
|
|
209
|
+
cap: input.take,
|
|
210
|
+
guidance: [pagination, ...notices].join(' '),
|
|
211
|
+
});
|
|
152
212
|
}
|
|
153
|
-
if (
|
|
154
|
-
ctx.enrich.notice(
|
|
213
|
+
else if (notices.length > 0) {
|
|
214
|
+
ctx.enrich.notice(notices.join(' '));
|
|
155
215
|
}
|
|
156
216
|
ctx.log.info('Seerr request list fetched', {
|
|
157
217
|
filter: input.filter,
|
|
158
218
|
returned: requests.length,
|
|
159
219
|
total,
|
|
220
|
+
titleLookups: lookup?.uniqueKeys ?? 0,
|
|
160
221
|
});
|
|
161
222
|
return { requests };
|
|
162
223
|
},
|
|
@@ -173,6 +234,8 @@ export const listRequestsTool = tool('seerr_list_requests', {
|
|
|
173
234
|
];
|
|
174
235
|
if (r.mediaStatus)
|
|
175
236
|
facts.push(`**Media:** ${statusText(r.mediaStatus)}`);
|
|
237
|
+
if (r.mediaStatus4k)
|
|
238
|
+
facts.push(`**Media 4K:** ${statusText(r.mediaStatus4k)}`);
|
|
176
239
|
facts.push(`**Requested by:** ${r.requestedBy.displayName} (id ${r.requestedBy.id})`);
|
|
177
240
|
if (r.createdAt)
|
|
178
241
|
facts.push(`**Created:** ${r.createdAt}`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list-requests.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/list-requests.tool.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"list-requests.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/list-requests.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAC/E,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,SAAS,EACT,UAAU,GACX,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,aAAa,EAAiB,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAEtF,8CAA8C;AAC9C,SAAS,YAAY,CAAC,CAAS;IAC7B,OAAO,GAAG,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC;AAC7C,CAAC;AAED,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,CAAC,qBAAqB,EAAE;IAC1D,KAAK,EAAE,iCAAiC;IACxC,WAAW,EACT,wVAAwV;IAC1V,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE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