You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
'Queries the Chrome UX Report (CrUX) API to get real-user experience metrics (like Core Web Vitals) for a given URL or origin. You must provide EITHER "origin" OR "url", but not both. You can optionally filter by "formFactor".',
196
+
'Queries the Chrome UX Report (aka CrUX) to get aggregated real-user experience metrics (like Core Web Vitals) for a given URL or origin. You must provide EITHER "origin" OR "url", but not both. You can optionally filter by "formFactor".',
163
197
annotations: {
164
198
category: ToolCategory.PERFORMANCE,
165
199
readOnlyHint: true,
166
200
},
167
201
schema: {
168
-
origin: zod.string().describe('The origin to query, e.g., "https://www.google.com". Do not provide this if "url" is specified.').optional(),
202
+
origin: zod
203
+
.string()
204
+
.describe(
205
+
'The origin to query, e.g., "https://www.google.com". Do not provide this if "url" is specified.',
206
+
)
207
+
.optional(),
169
208
url: zod
170
209
.string()
171
-
.describe('The specific page URL to query, e.g., "https://www.google.com/search?q=puppies". Do not provide this if "origin" is specified.')
210
+
.describe(
211
+
'The specific page URL to query, e.g., "https://www.google.com/search?q=puppies". Do not provide this if "origin" is specified.',
212
+
)
172
213
.optional(),
173
214
formFactor: zod
174
215
.enum(['DESKTOP','PHONE','TABLET'])
175
-
.describe('The form factor to filter by. If omitted, data for all form factors is aggregated.')
216
+
.describe(
217
+
'The form factor to filter by. If omitted, data for all form factors is aggregated.',
218
+
)
176
219
.optional(),
177
220
},
178
221
handler: async(request,response)=>{
179
222
const{origin, url, formFactor}=request.params;
180
223
181
224
if((!origin&&!url)||(origin&&url)){
182
-
response.appendResponseLine('Error: you must provide either "origin" or "url", but not both.');
225
+
response.appendResponseLine(
226
+
'Error: you must provide either "origin" or "url", but not both.',
0 commit comments