Merge "Added EnqueueJob class that handles routing jobs to queues"
[lhc/web/wiklou.git] / docs / extension.schema.json
1 {
2 "$schema": "http://json-schema.org/schema#",
3 "description": "MediaWiki extension.json schema",
4 "type": "object",
5 "properties": {
6 "name": {
7 "type": "string",
8 "description": "The extension's canonical name.",
9 "required": true
10 },
11 "type": {
12 "type": "string",
13 "description": "The extension's type, as an index to $wgExtensionCredits.",
14 "default": "other",
15 "enum": [
16 "api",
17 "antispam",
18 "datavalues",
19 "media",
20 "parserhook",
21 "semantic",
22 "skin",
23 "specialpage",
24 "variable",
25 "other"
26 ]
27 },
28 "author": {
29 "type": [
30 "string",
31 "array"
32 ],
33 "description": "Extension's authors.",
34 "items": {
35 "type": "string"
36 },
37 "additionalItems": false
38 },
39 "version": {
40 "type": "string",
41 "description": "The version of this release of the extension."
42 },
43 "url": {
44 "type": "string",
45 "description": "URL to the homepage for the extension.",
46 "format": "uri"
47 },
48 "description": {
49 "type": "string",
50 "description": "Raw description of the extension."
51 },
52 "descriptionmsg": {
53 "type": "string",
54 "description": "Message key for a i18n message describing the extension."
55 },
56 "license-name": {
57 "type": "string",
58 "description": "Short identifier for the license under which the extension is released.",
59 "enum": [
60 "AFL-1.1",
61 "AFL-1.2",
62 "AFL-2.0",
63 "AFL-2.1",
64 "AFL-3.0",
65 "APL-1.0",
66 "Aladdin",
67 "ANTLR-PD",
68 "Apache-1.0",
69 "Apache-1.1",
70 "Apache-2.0",
71 "APSL-1.0",
72 "APSL-1.1",
73 "APSL-1.2",
74 "APSL-2.0",
75 "Artistic-1.0",
76 "Artistic-1.0-cl8",
77 "Artistic-1.0-Perl",
78 "Artistic-2.0",
79 "AAL",
80 "BitTorrent-1.0",
81 "BitTorrent-1.1",
82 "BSL-1.0",
83 "BSD-2-Clause",
84 "BSD-2-Clause-FreeBSD",
85 "BSD-2-Clause-NetBSD",
86 "BSD-3-Clause",
87 "BSD-3-Clause-Clear",
88 "BSD-4-Clause",
89 "BSD-4-Clause-UC",
90 "CECILL-1.0",
91 "CECILL-1.1",
92 "CECILL-2.0",
93 "CECILL-B",
94 "CECILL-C",
95 "ClArtistic",
96 "CNRI-Python",
97 "CNRI-Python-GPL-Compatible",
98 "CPOL-1.02",
99 "CDDL-1.0",
100 "CDDL-1.1",
101 "CPAL-1.0",
102 "CPL-1.0",
103 "CATOSL-1.1",
104 "Condor-1.1",
105 "CC-BY-1.0",
106 "CC-BY-2.0",
107 "CC-BY-2.5",
108 "CC-BY-3.0",
109 "CC-BY-ND-1.0",
110 "CC-BY-ND-2.0",
111 "CC-BY-ND-2.5",
112 "CC-BY-ND-3.0",
113 "CC-BY-NC-1.0",
114 "CC-BY-NC-2.0",
115 "CC-BY-NC-2.5",
116 "CC-BY-NC-3.0",
117 "CC-BY-NC-ND-1.0",
118 "CC-BY-NC-ND-2.0",
119 "CC-BY-NC-ND-2.5",
120 "CC-BY-NC-ND-3.0",
121 "CC-BY-NC-SA-1.0",
122 "CC-BY-NC-SA-2.0",
123 "CC-BY-NC-SA-2.5",
124 "CC-BY-NC-SA-3.0",
125 "CC-BY-SA-1.0",
126 "CC-BY-SA-2.0",
127 "CC-BY-SA-2.5",
128 "CC-BY-SA-3.0",
129 "CC0-1.0",
130 "CUA-OPL-1.0",
131 "D-FSL-1.0",
132 "WTFPL",
133 "EPL-1.0",
134 "eCos-2.0",
135 "ECL-1.0",
136 "ECL-2.0",
137 "EFL-1.0",
138 "EFL-2.0",
139 "Entessa",
140 "ErlPL-1.1",
141 "EUDatagrid",
142 "EUPL-1.0",
143 "EUPL-1.1",
144 "Fair",
145 "Frameworx-1.0",
146 "FTL",
147 "AGPL-1.0",
148 "AGPL-3.0",
149 "GFDL-1.1",
150 "GFDL-1.2",
151 "GFDL-1.3",
152 "GPL-1.0",
153 "GPL-1.0+",
154 "GPL-2.0",
155 "GPL-2.0+",
156 "GPL-2.0-with-autoconf-exception",
157 "GPL-2.0-with-bison-exception",
158 "GPL-2.0-with-classpath-exception",
159 "GPL-2.0-with-font-exception",
160 "GPL-2.0-with-GCC-exception",
161 "GPL-3.0",
162 "GPL-3.0+",
163 "GPL-3.0-with-autoconf-exception",
164 "GPL-3.0-with-GCC-exception",
165 "LGPL-2.1",
166 "LGPL-2.1+",
167 "LGPL-3.0",
168 "LGPL-3.0+",
169 "LGPL-2.0",
170 "LGPL-2.0+",
171 "gSOAP-1.3b",
172 "HPND",
173 "IBM-pibs",
174 "IPL-1.0",
175 "Imlib2",
176 "IJG",
177 "Intel",
178 "IPA",
179 "ISC",
180 "JSON",
181 "LPPL-1.3a",
182 "LPPL-1.0",
183 "LPPL-1.1",
184 "LPPL-1.2",
185 "LPPL-1.3c",
186 "Libpng",
187 "LPL-1.02",
188 "LPL-1.0",
189 "MS-PL",
190 "MS-RL",
191 "MirOS",
192 "MIT",
193 "Motosoto",
194 "MPL-1.0",
195 "MPL-1.1",
196 "MPL-2.0",
197 "MPL-2.0-no-copyleft-exception",
198 "Multics",
199 "NASA-1.3",
200 "Naumen",
201 "NBPL-1.0",
202 "NGPL",
203 "NOSL",
204 "NPL-1.0",
205 "NPL-1.1",
206 "Nokia",
207 "NPOSL-3.0",
208 "NTP",
209 "OCLC-2.0",
210 "ODbL-1.0",
211 "PDDL-1.0",
212 "OGTSL",
213 "OLDAP-2.2.2",
214 "OLDAP-1.1",
215 "OLDAP-1.2",
216 "OLDAP-1.3",
217 "OLDAP-1.4",
218 "OLDAP-2.0",
219 "OLDAP-2.0.1",
220 "OLDAP-2.1",
221 "OLDAP-2.2",
222 "OLDAP-2.2.1",
223 "OLDAP-2.3",
224 "OLDAP-2.4",
225 "OLDAP-2.5",
226 "OLDAP-2.6",
227 "OLDAP-2.7",
228 "OPL-1.0",
229 "OSL-1.0",
230 "OSL-2.0",
231 "OSL-2.1",
232 "OSL-3.0",
233 "OLDAP-2.8",
234 "OpenSSL",
235 "PHP-3.0",
236 "PHP-3.01",
237 "PostgreSQL",
238 "Python-2.0",
239 "QPL-1.0",
240 "RPSL-1.0",
241 "RPL-1.1",
242 "RPL-1.5",
243 "RHeCos-1.1",
244 "RSCPL",
245 "Ruby",
246 "SAX-PD",
247 "SGI-B-1.0",
248 "SGI-B-1.1",
249 "SGI-B-2.0",
250 "OFL-1.0",
251 "OFL-1.1",
252 "SimPL-2.0",
253 "Sleepycat",
254 "SMLNJ",
255 "SugarCRM-1.1.3",
256 "SISSL",
257 "SISSL-1.2",
258 "SPL-1.0",
259 "Watcom-1.0",
260 "NCSA",
261 "VSL-1.0",
262 "W3C",
263 "WXwindows",
264 "Xnet",
265 "X11",
266 "XFree86-1.1",
267 "YPL-1.0",
268 "YPL-1.1",
269 "Zimbra-1.3",
270 "Zlib",
271 "ZPL-1.1",
272 "ZPL-2.0",
273 "ZPL-2.1",
274 "Unlicense"
275 ]
276 },
277 "ResourceFileModulePaths": {
278 "type": "object",
279 "description": "Default paths to use for all ResourceLoader file modules",
280 "additionalProperties": false,
281 "properties": {
282 "localBasePath": {
283 "type": "string",
284 "description": "Base path to prepend to all local paths, relative to current directory"
285 },
286 "remoteExtPath": {
287 "type": "string",
288 "description": "Base path to prepend to all remote paths, relative to $wgExtensionAssetsPath"
289 },
290 "remoteSkinPath": {
291 "type": "string",
292 "description": "Base path to prepend to all remote paths, relative to $wgStylePath"
293 }
294 }
295 },
296 "ResourceLoaderModules": {
297 "type": "object",
298 "description": "ResourceLoader modules to register",
299 "additionalProperties": false,
300 "patternProperties": {
301 "^[a-zA-Z0-9\\.]+$": {
302 "type": "object",
303 "description": "A single ResourceLoader module descriptor",
304 "properties": {
305 "localBasePath": {
306 "type": "string",
307 "description": "Base path to prepend to all local paths in $options. Defaults to $IP"
308 },
309 "remoteBasePath": {
310 "type": "string",
311 "description": "Base path to prepend to all remote paths in $options. Defaults to $wgScriptPath"
312 },
313 "remoteExtPath": {
314 "type": "string",
315 "description": "Equivalent of remoteBasePath, but relative to $wgExtensionAssetsPath"
316 },
317 "scripts": {
318 "type": "array",
319 "description": "Scripts to always include (array of file paths)",
320 "items": {
321 "type": "string"
322 }
323 },
324 "languageScripts": {
325 "type": "object",
326 "description": "Scripts to include in specific language contexts (mapping of language code to file path(s))",
327 "patternProperties": {
328 "^[a-zA-Z0-9-]{2,}$": {
329 "type": [
330 "string",
331 "array"
332 ],
333 "items": {
334 "type": "string"
335 }
336 }
337 }
338 },
339 "skinScripts": {
340 "type": "object",
341 "description": "Scripts to include in specific skin contexts (mapping of skin name to script(s)",
342 "patternProperties": {
343 ".+": {
344 "type": [
345 "string",
346 "array"
347 ],
348 "items": {
349 "type": "string"
350 }
351 }
352 }
353 },
354 "debugScripts": {
355 "type": "array",
356 "description": "Scripts to include in debug contexts",
357 "items": {
358 "type": "string"
359 }
360 },
361 "loaderScripts": {
362 "type": "array",
363 "description": "Scripts to include in the startup module",
364 "items": {
365 "type": "string"
366 }
367 },
368 "dependencies": {
369 "type": "array",
370 "description": "Modules which must be loaded before this module",
371 "items": {
372 "type": "string"
373 }
374 },
375 "styles": {
376 "type": "array",
377 "description": "Styles to always load",
378 "items": {
379 "type": "string"
380 }
381 },
382 "skinStyles": {
383 "type": "object",
384 "description": "Styles to include in specific skin contexts (mapping of skin name to style(s))",
385 "patternProperties": {
386 ".+": {
387 "type": [
388 "string",
389 "array"
390 ],
391 "items": {
392 "type": "string"
393 }
394 }
395 }
396 },
397 "messages": {
398 "type": "array",
399 "description": "Messages to always load",
400 "items": {
401 "type": "string"
402 }
403 },
404 "group": {
405 "type": "string",
406 "description": "Group which this module should be loaded together with"
407 },
408 "position": {
409 "type": "string",
410 "description": "Position on the page to load this module at",
411 "enum": [
412 "bottom",
413 "top"
414 ]
415 }
416 }
417 }
418 }
419 },
420 "ResourceLoaderSources": {
421 "type": "object",
422 "description": "ResourceLoader sources to register"
423 },
424 "ResourceLoaderLESSVars": {
425 "type": "object",
426 "description": "ResourceLoader LESS variables"
427 },
428 "ResourceLoaderLESSFunctions": {
429 "type": "object",
430 "description": "ResourceLoader LESS functions"
431 },
432 "ResourceLoaderLESSImportPaths": {
433 "type": "object",
434 "description": "ResourceLoader import paths"
435 },
436 "ConfigRegistry": {
437 "type": "object",
438 "description": "Registry of factory functions to create Config objects"
439 },
440 "namespaces": {
441 "type": "object",
442 "description": "Method to add extra namespaces",
443 "properties": {
444 "id": {
445 "type": "integer"
446 },
447 "constant": {
448 "type": "string"
449 },
450 "name": {
451 "type": "string"
452 },
453 "gender": {
454 "type": "object",
455 "properties": {
456 "male": {
457 "type": "string"
458 },
459 "female": {
460 "type": "string"
461 }
462 }
463 },
464 "subpages": {
465 "type": "boolean",
466 "default": false
467 },
468 "content": {
469 "type": "boolean",
470 "default": false
471 },
472 "defaultcontentmodel": {
473 "type": "string"
474 }
475 }
476 },
477 "TrackingCategories": {
478 "type": "array",
479 "description": "Tracking category message keys"
480 },
481 "DefaultUserOptions": {
482 "type": "object",
483 "description": "Default values of user options"
484 },
485 "HiddenPrefs": {
486 "type": "array",
487 "description": "Preferences users cannot set"
488 },
489 "GroupPermissions": {
490 "type": "object",
491 "description": "Default permissions to give to user groups"
492 },
493 "RevokePermissions": {
494 "type": "object",
495 "description": "Default permissions to revoke from user groups"
496 },
497 "ImplicitGroups": {
498 "type": "array",
499 "description": "Implicit groups"
500 },
501 "GroupsAddToSelf": {
502 "type": "object",
503 "description": "Groups a user can add to themselves"
504 },
505 "GroupsRemoveFromSelf": {
506 "type": "object",
507 "description": "Groups a user can remove from themselves"
508 },
509 "AddGroups": {
510 "type": "object",
511 "description": "Groups a user can add to users"
512 },
513 "RemoveGroups": {
514 "type": "object",
515 "description": "Groups a user can remove from users"
516 },
517 "AvailableRights": {
518 "type": "array",
519 "description": "User rights added by the extension"
520 },
521 "ContentHandlers": {
522 "type": "object",
523 "description": "Mapping of model ID to class name"
524 },
525 "RateLimits": {
526 "type": "object",
527 "description": "Rate limits"
528 },
529 "ParserTestFiles": {
530 "type": "array",
531 "description": "Parser test files to run"
532 },
533 "RecentChangesFlags": {
534 "type": "object",
535 "description": "Flags (letter symbols) shown on RecentChanges pages"
536 },
537 "ExtensionFunctions": {
538 "type": [
539 "array",
540 "string"
541 ],
542 "description": "Function to call after setup has finished"
543 },
544 "ExtensionMessagesFiles": {
545 "type": "object",
546 "description": "File paths containing PHP internationalization data"
547 },
548 "MessagesDirs": {
549 "type": "object",
550 "description": "Directory paths containing JSON internationalization data"
551 },
552 "ExtensionEntryPointListFiles": {
553 "type": "object"
554 },
555 "SpecialPages": {
556 "type": "object",
557 "description": "SpecialPages implemented in this extension (mapping of page name to class name)"
558 },
559 "SpecialPageGroups": {
560 "type": "object",
561 "description": "Mapping of special page name to group it belongs to"
562 },
563 "AutoloadClasses": {
564 "type": "object"
565 },
566 "Hooks": {
567 "type": "object",
568 "description": "Hooks this extension uses (mapping of hook name to callback)"
569 },
570 "JobClasses": {
571 "type": "object",
572 "description": "Job types this extension implements (mapping of job type to class name)"
573 },
574 "LogTypes": {
575 "type": "array",
576 "description": "List of new log types this extension uses"
577 },
578 "LogRestrictions": {
579 "type": "object"
580 },
581 "FilterLogTypes": {
582 "type": "array"
583 },
584 "LogNames": {
585 "type": "object"
586 },
587 "LogHeaders": {
588 "type": "object"
589 },
590 "LogActions": {
591 "type": "object"
592 },
593 "LogActionsHandlers": {
594 "type": "object"
595 },
596 "Actions": {
597 "type": "object"
598 },
599 "APIModules": {
600 "type": "object"
601 },
602 "APIFormatModules": {
603 "type": "object"
604 },
605 "APIMetaModules": {
606 "type": "object"
607 },
608 "APIPropModules": {
609 "type": "object"
610 },
611 "APIListModules": {
612 "type": "object"
613 },
614 "ValidSkinNames": {
615 "type": "object"
616 },
617 "callback": {
618 "type": [
619 "array",
620 "string"
621 ],
622 "description": "A function to be called right after MediaWiki processes this file"
623 },
624 "config": {
625 "type": "object",
626 "description": "Configuration options for this extension"
627 }
628 }
629 }