@wp-playground/blueprints 0.1.60 → 0.2.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.
@@ -0,0 +1,1188 @@
1
+ {
2
+ "$schema": "http://json-schema.org/schema",
3
+ "$ref": "#/definitions/Blueprint",
4
+ "definitions": {
5
+ "Blueprint": {
6
+ "type": "object",
7
+ "properties": {
8
+ "landingPage": {
9
+ "type": "string",
10
+ "description": "The URL to navigate to after the blueprint has been run."
11
+ },
12
+ "preferredVersions": {
13
+ "type": "object",
14
+ "properties": {
15
+ "php": {
16
+ "anyOf": [
17
+ {
18
+ "$ref": "#/definitions/SupportedPHPVersion"
19
+ },
20
+ {
21
+ "type": "string",
22
+ "const": "latest"
23
+ }
24
+ ],
25
+ "description": "The preferred PHP version to use. If not specified, the latest supported version will be used"
26
+ },
27
+ "wp": {
28
+ "type": "string",
29
+ "description": "The preferred WordPress version to use. If not specified, the latest supported version will be used"
30
+ }
31
+ },
32
+ "required": ["php", "wp"],
33
+ "additionalProperties": false,
34
+ "description": "The preferred PHP and WordPress versions to use."
35
+ },
36
+ "steps": {
37
+ "type": "array",
38
+ "items": {
39
+ "anyOf": [
40
+ {
41
+ "$ref": "#/definitions/StepDefinition"
42
+ },
43
+ {
44
+ "type": "string"
45
+ },
46
+ {
47
+ "not": {}
48
+ },
49
+ {
50
+ "type": "boolean",
51
+ "const": false
52
+ },
53
+ {
54
+ "type": "null"
55
+ }
56
+ ]
57
+ },
58
+ "description": "The steps to run."
59
+ },
60
+ "$schema": {
61
+ "type": "string"
62
+ }
63
+ },
64
+ "additionalProperties": false
65
+ },
66
+ "SupportedPHPVersion": {
67
+ "type": "string",
68
+ "enum": [
69
+ "8.2",
70
+ "8.1",
71
+ "8.0",
72
+ "7.4",
73
+ "7.3",
74
+ "7.2",
75
+ "7.1",
76
+ "7.0",
77
+ "5.6"
78
+ ]
79
+ },
80
+ "StepDefinition": {
81
+ "type": "object",
82
+ "discriminator": {
83
+ "propertyName": "step"
84
+ },
85
+ "required": ["step"],
86
+ "oneOf": [
87
+ {
88
+ "type": "object",
89
+ "additionalProperties": false,
90
+ "properties": {
91
+ "progress": {
92
+ "type": "object",
93
+ "properties": {
94
+ "weight": {
95
+ "type": "number"
96
+ },
97
+ "caption": {
98
+ "type": "string"
99
+ }
100
+ },
101
+ "additionalProperties": false
102
+ },
103
+ "step": {
104
+ "type": "string",
105
+ "const": "activatePlugin"
106
+ },
107
+ "pluginPath": {
108
+ "type": "string",
109
+ "description": "Path to the plugin directory as absolute path (/wordpress/wp-content/plugins/plugin-name); or the plugin entry file relative to the plugins directory (plugin-name/plugin-name.php)."
110
+ },
111
+ "pluginName": {
112
+ "type": "string",
113
+ "description": "Optional. Plugin name to display in the progress bar."
114
+ }
115
+ },
116
+ "required": ["pluginPath", "step"]
117
+ },
118
+ {
119
+ "type": "object",
120
+ "additionalProperties": false,
121
+ "properties": {
122
+ "progress": {
123
+ "type": "object",
124
+ "properties": {
125
+ "weight": {
126
+ "type": "number"
127
+ },
128
+ "caption": {
129
+ "type": "string"
130
+ }
131
+ },
132
+ "additionalProperties": false
133
+ },
134
+ "step": {
135
+ "type": "string",
136
+ "const": "activateTheme"
137
+ },
138
+ "themeFolderName": {
139
+ "type": "string",
140
+ "description": "The name of the theme folder inside wp-content/themes/"
141
+ }
142
+ },
143
+ "required": ["step", "themeFolderName"]
144
+ },
145
+ {
146
+ "type": "object",
147
+ "additionalProperties": false,
148
+ "properties": {
149
+ "progress": {
150
+ "type": "object",
151
+ "properties": {
152
+ "weight": {
153
+ "type": "number"
154
+ },
155
+ "caption": {
156
+ "type": "string"
157
+ }
158
+ },
159
+ "additionalProperties": false
160
+ },
161
+ "step": {
162
+ "type": "string",
163
+ "const": "applyWordPressPatches"
164
+ },
165
+ "siteUrl": {
166
+ "type": "string"
167
+ },
168
+ "wordpressPath": {
169
+ "type": "string"
170
+ },
171
+ "addPhpInfo": {
172
+ "type": "boolean"
173
+ },
174
+ "patchSecrets": {
175
+ "type": "boolean"
176
+ },
177
+ "disableSiteHealth": {
178
+ "type": "boolean"
179
+ },
180
+ "disableWpNewBlogNotification": {
181
+ "type": "boolean"
182
+ }
183
+ },
184
+ "required": ["step"]
185
+ },
186
+ {
187
+ "type": "object",
188
+ "additionalProperties": false,
189
+ "properties": {
190
+ "progress": {
191
+ "type": "object",
192
+ "properties": {
193
+ "weight": {
194
+ "type": "number"
195
+ },
196
+ "caption": {
197
+ "type": "string"
198
+ }
199
+ },
200
+ "additionalProperties": false
201
+ },
202
+ "step": {
203
+ "type": "string",
204
+ "const": "cp"
205
+ },
206
+ "fromPath": {
207
+ "type": "string",
208
+ "description": "Source path"
209
+ },
210
+ "toPath": {
211
+ "type": "string",
212
+ "description": "Target path"
213
+ }
214
+ },
215
+ "required": ["fromPath", "step", "toPath"]
216
+ },
217
+ {
218
+ "type": "object",
219
+ "additionalProperties": false,
220
+ "properties": {
221
+ "progress": {
222
+ "type": "object",
223
+ "properties": {
224
+ "weight": {
225
+ "type": "number"
226
+ },
227
+ "caption": {
228
+ "type": "string"
229
+ }
230
+ },
231
+ "additionalProperties": false
232
+ },
233
+ "step": {
234
+ "type": "string",
235
+ "const": "defineWpConfigConsts"
236
+ },
237
+ "consts": {
238
+ "type": "object",
239
+ "additionalProperties": {},
240
+ "description": "The constants to define"
241
+ },
242
+ "virtualize": {
243
+ "type": "boolean",
244
+ "description": "Enables the virtualization of wp-config.php and playground-consts.json files, leaving the local system files untouched. The variables defined in the /vfs-blueprints/playground-consts.json file are loaded via the auto_prepend_file directive in the php.ini file.",
245
+ "default": false
246
+ }
247
+ },
248
+ "required": ["consts", "step"]
249
+ },
250
+ {
251
+ "type": "object",
252
+ "additionalProperties": false,
253
+ "properties": {
254
+ "progress": {
255
+ "type": "object",
256
+ "properties": {
257
+ "weight": {
258
+ "type": "number"
259
+ },
260
+ "caption": {
261
+ "type": "string"
262
+ }
263
+ },
264
+ "additionalProperties": false
265
+ },
266
+ "step": {
267
+ "type": "string",
268
+ "const": "defineSiteUrl"
269
+ },
270
+ "siteUrl": {
271
+ "type": "string",
272
+ "description": "The URL"
273
+ }
274
+ },
275
+ "required": ["siteUrl", "step"]
276
+ },
277
+ {
278
+ "type": "object",
279
+ "additionalProperties": false,
280
+ "properties": {
281
+ "progress": {
282
+ "type": "object",
283
+ "properties": {
284
+ "weight": {
285
+ "type": "number"
286
+ },
287
+ "caption": {
288
+ "type": "string"
289
+ }
290
+ },
291
+ "additionalProperties": false
292
+ },
293
+ "step": {
294
+ "type": "string",
295
+ "const": "importFile"
296
+ },
297
+ "file": {
298
+ "$ref": "#/definitions/FileReference",
299
+ "description": "The file to import"
300
+ }
301
+ },
302
+ "required": ["file", "step"]
303
+ },
304
+ {
305
+ "type": "object",
306
+ "additionalProperties": false,
307
+ "properties": {
308
+ "progress": {
309
+ "type": "object",
310
+ "properties": {
311
+ "weight": {
312
+ "type": "number"
313
+ },
314
+ "caption": {
315
+ "type": "string"
316
+ }
317
+ },
318
+ "additionalProperties": false
319
+ },
320
+ "step": {
321
+ "type": "string",
322
+ "const": "installPlugin",
323
+ "description": "The step identifier."
324
+ },
325
+ "pluginZipFile": {
326
+ "$ref": "#/definitions/FileReference",
327
+ "description": "The plugin zip file to install."
328
+ },
329
+ "options": {
330
+ "$ref": "#/definitions/InstallPluginOptions",
331
+ "description": "Optional installation options."
332
+ }
333
+ },
334
+ "required": ["pluginZipFile", "step"]
335
+ },
336
+ {
337
+ "type": "object",
338
+ "additionalProperties": false,
339
+ "properties": {
340
+ "progress": {
341
+ "type": "object",
342
+ "properties": {
343
+ "weight": {
344
+ "type": "number"
345
+ },
346
+ "caption": {
347
+ "type": "string"
348
+ }
349
+ },
350
+ "additionalProperties": false
351
+ },
352
+ "step": {
353
+ "type": "string",
354
+ "const": "installTheme",
355
+ "description": "The step identifier."
356
+ },
357
+ "themeZipFile": {
358
+ "$ref": "#/definitions/FileReference",
359
+ "description": "The theme zip file to install."
360
+ },
361
+ "options": {
362
+ "type": "object",
363
+ "properties": {
364
+ "activate": {
365
+ "type": "boolean",
366
+ "description": "Whether to activate the theme after installing it."
367
+ }
368
+ },
369
+ "additionalProperties": false,
370
+ "description": "Optional installation options."
371
+ }
372
+ },
373
+ "required": ["step", "themeZipFile"]
374
+ },
375
+ {
376
+ "type": "object",
377
+ "additionalProperties": false,
378
+ "properties": {
379
+ "progress": {
380
+ "type": "object",
381
+ "properties": {
382
+ "weight": {
383
+ "type": "number"
384
+ },
385
+ "caption": {
386
+ "type": "string"
387
+ }
388
+ },
389
+ "additionalProperties": false
390
+ },
391
+ "step": {
392
+ "type": "string",
393
+ "const": "login"
394
+ },
395
+ "username": {
396
+ "type": "string",
397
+ "description": "The user to log in as. Defaults to 'admin'."
398
+ },
399
+ "password": {
400
+ "type": "string",
401
+ "description": "The password to log in with. Defaults to 'password'."
402
+ }
403
+ },
404
+ "required": ["step"]
405
+ },
406
+ {
407
+ "type": "object",
408
+ "additionalProperties": false,
409
+ "properties": {
410
+ "progress": {
411
+ "type": "object",
412
+ "properties": {
413
+ "weight": {
414
+ "type": "number"
415
+ },
416
+ "caption": {
417
+ "type": "string"
418
+ }
419
+ },
420
+ "additionalProperties": false
421
+ },
422
+ "step": {
423
+ "type": "string",
424
+ "const": "mkdir"
425
+ },
426
+ "path": {
427
+ "type": "string",
428
+ "description": "The path of the directory you want to create"
429
+ }
430
+ },
431
+ "required": ["path", "step"]
432
+ },
433
+ {
434
+ "type": "object",
435
+ "additionalProperties": false,
436
+ "properties": {
437
+ "progress": {
438
+ "type": "object",
439
+ "properties": {
440
+ "weight": {
441
+ "type": "number"
442
+ },
443
+ "caption": {
444
+ "type": "string"
445
+ }
446
+ },
447
+ "additionalProperties": false
448
+ },
449
+ "step": {
450
+ "type": "string",
451
+ "const": "mv"
452
+ },
453
+ "fromPath": {
454
+ "type": "string",
455
+ "description": "Source path"
456
+ },
457
+ "toPath": {
458
+ "type": "string",
459
+ "description": "Target path"
460
+ }
461
+ },
462
+ "required": ["fromPath", "step", "toPath"]
463
+ },
464
+ {
465
+ "type": "object",
466
+ "additionalProperties": false,
467
+ "properties": {
468
+ "progress": {
469
+ "type": "object",
470
+ "properties": {
471
+ "weight": {
472
+ "type": "number"
473
+ },
474
+ "caption": {
475
+ "type": "string"
476
+ }
477
+ },
478
+ "additionalProperties": false
479
+ },
480
+ "step": {
481
+ "type": "string",
482
+ "const": "request"
483
+ },
484
+ "request": {
485
+ "$ref": "#/definitions/PHPRequest",
486
+ "description": "Request details (See /wordpress-playground/api/universal/interface/PHPRequest)"
487
+ }
488
+ },
489
+ "required": ["request", "step"]
490
+ },
491
+ {
492
+ "type": "object",
493
+ "additionalProperties": false,
494
+ "properties": {
495
+ "progress": {
496
+ "type": "object",
497
+ "properties": {
498
+ "weight": {
499
+ "type": "number"
500
+ },
501
+ "caption": {
502
+ "type": "string"
503
+ }
504
+ },
505
+ "additionalProperties": false
506
+ },
507
+ "step": {
508
+ "type": "string",
509
+ "const": "replaceSite"
510
+ },
511
+ "fullSiteZip": {
512
+ "$ref": "#/definitions/FileReference",
513
+ "description": "The zip file containing the new WordPress site"
514
+ }
515
+ },
516
+ "required": ["fullSiteZip", "step"]
517
+ },
518
+ {
519
+ "type": "object",
520
+ "additionalProperties": false,
521
+ "properties": {
522
+ "progress": {
523
+ "type": "object",
524
+ "properties": {
525
+ "weight": {
526
+ "type": "number"
527
+ },
528
+ "caption": {
529
+ "type": "string"
530
+ }
531
+ },
532
+ "additionalProperties": false
533
+ },
534
+ "step": {
535
+ "type": "string",
536
+ "const": "rm"
537
+ },
538
+ "path": {
539
+ "type": "string",
540
+ "description": "The path to remove"
541
+ }
542
+ },
543
+ "required": ["path", "step"]
544
+ },
545
+ {
546
+ "type": "object",
547
+ "additionalProperties": false,
548
+ "properties": {
549
+ "progress": {
550
+ "type": "object",
551
+ "properties": {
552
+ "weight": {
553
+ "type": "number"
554
+ },
555
+ "caption": {
556
+ "type": "string"
557
+ }
558
+ },
559
+ "additionalProperties": false
560
+ },
561
+ "step": {
562
+ "type": "string",
563
+ "const": "rmdir"
564
+ },
565
+ "path": {
566
+ "type": "string",
567
+ "description": "The path to remove"
568
+ }
569
+ },
570
+ "required": ["path", "step"]
571
+ },
572
+ {
573
+ "type": "object",
574
+ "additionalProperties": false,
575
+ "properties": {
576
+ "progress": {
577
+ "type": "object",
578
+ "properties": {
579
+ "weight": {
580
+ "type": "number"
581
+ },
582
+ "caption": {
583
+ "type": "string"
584
+ }
585
+ },
586
+ "additionalProperties": false
587
+ },
588
+ "step": {
589
+ "type": "string",
590
+ "const": "runPHP",
591
+ "description": "The step identifier."
592
+ },
593
+ "code": {
594
+ "type": "string",
595
+ "description": "The PHP code to run."
596
+ }
597
+ },
598
+ "required": ["code", "step"]
599
+ },
600
+ {
601
+ "type": "object",
602
+ "additionalProperties": false,
603
+ "properties": {
604
+ "progress": {
605
+ "type": "object",
606
+ "properties": {
607
+ "weight": {
608
+ "type": "number"
609
+ },
610
+ "caption": {
611
+ "type": "string"
612
+ }
613
+ },
614
+ "additionalProperties": false
615
+ },
616
+ "step": {
617
+ "type": "string",
618
+ "const": "runPHPWithOptions"
619
+ },
620
+ "options": {
621
+ "$ref": "#/definitions/PHPRunOptions",
622
+ "description": "Run options (See /wordpress-playground/api/universal/interface/PHPRunOptions)"
623
+ }
624
+ },
625
+ "required": ["options", "step"]
626
+ },
627
+ {
628
+ "type": "object",
629
+ "additionalProperties": false,
630
+ "properties": {
631
+ "progress": {
632
+ "type": "object",
633
+ "properties": {
634
+ "weight": {
635
+ "type": "number"
636
+ },
637
+ "caption": {
638
+ "type": "string"
639
+ }
640
+ },
641
+ "additionalProperties": false
642
+ },
643
+ "step": {
644
+ "type": "string",
645
+ "const": "runWpInstallationWizard"
646
+ },
647
+ "options": {
648
+ "$ref": "#/definitions/WordPressInstallationOptions"
649
+ }
650
+ },
651
+ "required": ["options", "step"]
652
+ },
653
+ {
654
+ "type": "object",
655
+ "additionalProperties": false,
656
+ "properties": {
657
+ "progress": {
658
+ "type": "object",
659
+ "properties": {
660
+ "weight": {
661
+ "type": "number"
662
+ },
663
+ "caption": {
664
+ "type": "string"
665
+ }
666
+ },
667
+ "additionalProperties": false
668
+ },
669
+ "step": {
670
+ "type": "string",
671
+ "const": "setPhpIniEntry"
672
+ },
673
+ "key": {
674
+ "type": "string",
675
+ "description": "Entry name e.g. \"display_errors\""
676
+ },
677
+ "value": {
678
+ "type": "string",
679
+ "description": "Entry value as a string e.g. \"1\""
680
+ }
681
+ },
682
+ "required": ["key", "step", "value"]
683
+ },
684
+ {
685
+ "type": "object",
686
+ "additionalProperties": false,
687
+ "properties": {
688
+ "progress": {
689
+ "type": "object",
690
+ "properties": {
691
+ "weight": {
692
+ "type": "number"
693
+ },
694
+ "caption": {
695
+ "type": "string"
696
+ }
697
+ },
698
+ "additionalProperties": false
699
+ },
700
+ "step": {
701
+ "type": "string",
702
+ "const": "setSiteOptions",
703
+ "description": "The name of the step. Must be \"setSiteOptions\"."
704
+ },
705
+ "options": {
706
+ "type": "object",
707
+ "additionalProperties": {},
708
+ "description": "The options to set on the site."
709
+ }
710
+ },
711
+ "required": ["options", "step"]
712
+ },
713
+ {
714
+ "type": "object",
715
+ "additionalProperties": false,
716
+ "properties": {
717
+ "progress": {
718
+ "type": "object",
719
+ "properties": {
720
+ "weight": {
721
+ "type": "number"
722
+ },
723
+ "caption": {
724
+ "type": "string"
725
+ }
726
+ },
727
+ "additionalProperties": false
728
+ },
729
+ "step": {
730
+ "type": "string",
731
+ "const": "unzip"
732
+ },
733
+ "zipPath": {
734
+ "type": "string",
735
+ "description": "The zip file to extract"
736
+ },
737
+ "extractToPath": {
738
+ "type": "string",
739
+ "description": "The path to extract the zip file to"
740
+ }
741
+ },
742
+ "required": ["extractToPath", "step", "zipPath"]
743
+ },
744
+ {
745
+ "type": "object",
746
+ "additionalProperties": false,
747
+ "properties": {
748
+ "progress": {
749
+ "type": "object",
750
+ "properties": {
751
+ "weight": {
752
+ "type": "number"
753
+ },
754
+ "caption": {
755
+ "type": "string"
756
+ }
757
+ },
758
+ "additionalProperties": false
759
+ },
760
+ "step": {
761
+ "type": "string",
762
+ "const": "updateUserMeta"
763
+ },
764
+ "meta": {
765
+ "type": "object",
766
+ "additionalProperties": {},
767
+ "description": "An object of user meta values to set, e.g. { \"first_name\": \"John\" }"
768
+ },
769
+ "userId": {
770
+ "type": "number",
771
+ "description": "User ID"
772
+ }
773
+ },
774
+ "required": ["meta", "step", "userId"]
775
+ },
776
+ {
777
+ "type": "object",
778
+ "additionalProperties": false,
779
+ "properties": {
780
+ "progress": {
781
+ "type": "object",
782
+ "properties": {
783
+ "weight": {
784
+ "type": "number"
785
+ },
786
+ "caption": {
787
+ "type": "string"
788
+ }
789
+ },
790
+ "additionalProperties": false
791
+ },
792
+ "step": {
793
+ "type": "string",
794
+ "const": "writeFile"
795
+ },
796
+ "path": {
797
+ "type": "string",
798
+ "description": "The path of the file to write to"
799
+ },
800
+ "data": {
801
+ "anyOf": [
802
+ {
803
+ "$ref": "#/definitions/FileReference"
804
+ },
805
+ {
806
+ "type": "string"
807
+ },
808
+ {
809
+ "type": "object",
810
+ "properties": {
811
+ "BYTES_PER_ELEMENT": {
812
+ "type": "number"
813
+ },
814
+ "buffer": {
815
+ "type": "object",
816
+ "properties": {
817
+ "byteLength": {
818
+ "type": "number"
819
+ }
820
+ },
821
+ "required": ["byteLength"],
822
+ "additionalProperties": false
823
+ },
824
+ "byteLength": {
825
+ "type": "number"
826
+ },
827
+ "byteOffset": {
828
+ "type": "number"
829
+ },
830
+ "length": {
831
+ "type": "number"
832
+ }
833
+ },
834
+ "required": [
835
+ "BYTES_PER_ELEMENT",
836
+ "buffer",
837
+ "byteLength",
838
+ "byteOffset",
839
+ "length"
840
+ ],
841
+ "additionalProperties": {
842
+ "type": "number"
843
+ }
844
+ }
845
+ ],
846
+ "description": "The data to write"
847
+ }
848
+ },
849
+ "required": ["data", "path", "step"]
850
+ }
851
+ ]
852
+ },
853
+ "FileReference": {
854
+ "anyOf": [
855
+ {
856
+ "$ref": "#/definitions/VFSReference"
857
+ },
858
+ {
859
+ "$ref": "#/definitions/LiteralReference"
860
+ },
861
+ {
862
+ "$ref": "#/definitions/CoreThemeReference"
863
+ },
864
+ {
865
+ "$ref": "#/definitions/CorePluginReference"
866
+ },
867
+ {
868
+ "$ref": "#/definitions/UrlReference"
869
+ }
870
+ ]
871
+ },
872
+ "VFSReference": {
873
+ "type": "object",
874
+ "properties": {
875
+ "resource": {
876
+ "type": "string",
877
+ "const": "vfs",
878
+ "description": "Identifies the file resource as Virtual File System (VFS)"
879
+ },
880
+ "path": {
881
+ "type": "string",
882
+ "description": "The path to the file in the VFS"
883
+ }
884
+ },
885
+ "required": ["resource", "path"],
886
+ "additionalProperties": false
887
+ },
888
+ "LiteralReference": {
889
+ "type": "object",
890
+ "properties": {
891
+ "resource": {
892
+ "type": "string",
893
+ "const": "literal",
894
+ "description": "Identifies the file resource as a literal file"
895
+ },
896
+ "name": {
897
+ "type": "string",
898
+ "description": "The name of the file"
899
+ },
900
+ "contents": {
901
+ "anyOf": [
902
+ {
903
+ "type": "string"
904
+ },
905
+ {
906
+ "type": "object",
907
+ "properties": {
908
+ "BYTES_PER_ELEMENT": {
909
+ "type": "number"
910
+ },
911
+ "buffer": {
912
+ "type": "object",
913
+ "properties": {
914
+ "byteLength": {
915
+ "type": "number"
916
+ }
917
+ },
918
+ "required": ["byteLength"],
919
+ "additionalProperties": false
920
+ },
921
+ "byteLength": {
922
+ "type": "number"
923
+ },
924
+ "byteOffset": {
925
+ "type": "number"
926
+ },
927
+ "length": {
928
+ "type": "number"
929
+ }
930
+ },
931
+ "required": [
932
+ "BYTES_PER_ELEMENT",
933
+ "buffer",
934
+ "byteLength",
935
+ "byteOffset",
936
+ "length"
937
+ ],
938
+ "additionalProperties": {
939
+ "type": "number"
940
+ }
941
+ }
942
+ ],
943
+ "description": "The contents of the file"
944
+ }
945
+ },
946
+ "required": ["resource", "name", "contents"],
947
+ "additionalProperties": false
948
+ },
949
+ "CoreThemeReference": {
950
+ "type": "object",
951
+ "properties": {
952
+ "resource": {
953
+ "type": "string",
954
+ "const": "wordpress.org/themes",
955
+ "description": "Identifies the file resource as a WordPress Core theme"
956
+ },
957
+ "slug": {
958
+ "type": "string",
959
+ "description": "The slug of the WordPress Core theme"
960
+ }
961
+ },
962
+ "required": ["resource", "slug"],
963
+ "additionalProperties": false
964
+ },
965
+ "CorePluginReference": {
966
+ "type": "object",
967
+ "properties": {
968
+ "resource": {
969
+ "type": "string",
970
+ "const": "wordpress.org/plugins",
971
+ "description": "Identifies the file resource as a WordPress Core plugin"
972
+ },
973
+ "slug": {
974
+ "type": "string",
975
+ "description": "The slug of the WordPress Core plugin"
976
+ }
977
+ },
978
+ "required": ["resource", "slug"],
979
+ "additionalProperties": false
980
+ },
981
+ "UrlReference": {
982
+ "type": "object",
983
+ "properties": {
984
+ "resource": {
985
+ "type": "string",
986
+ "const": "url",
987
+ "description": "Identifies the file resource as a URL"
988
+ },
989
+ "url": {
990
+ "type": "string",
991
+ "description": "The URL of the file"
992
+ },
993
+ "caption": {
994
+ "type": "string",
995
+ "description": "Optional caption for displaying a progress message"
996
+ }
997
+ },
998
+ "required": ["resource", "url"],
999
+ "additionalProperties": false
1000
+ },
1001
+ "InstallPluginOptions": {
1002
+ "type": "object",
1003
+ "properties": {
1004
+ "activate": {
1005
+ "type": "boolean",
1006
+ "description": "Whether to activate the plugin after installing it."
1007
+ }
1008
+ },
1009
+ "additionalProperties": false
1010
+ },
1011
+ "PHPRequest": {
1012
+ "type": "object",
1013
+ "properties": {
1014
+ "method": {
1015
+ "$ref": "#/definitions/HTTPMethod",
1016
+ "description": "Request method. Default: `GET`."
1017
+ },
1018
+ "url": {
1019
+ "type": "string",
1020
+ "description": "Request path or absolute URL."
1021
+ },
1022
+ "headers": {
1023
+ "$ref": "#/definitions/PHPRequestHeaders",
1024
+ "description": "Request headers."
1025
+ },
1026
+ "files": {
1027
+ "type": "object",
1028
+ "additionalProperties": {
1029
+ "type": "object",
1030
+ "properties": {
1031
+ "size": {
1032
+ "type": "number"
1033
+ },
1034
+ "type": {
1035
+ "type": "string"
1036
+ },
1037
+ "lastModified": {
1038
+ "type": "number"
1039
+ },
1040
+ "name": {
1041
+ "type": "string"
1042
+ },
1043
+ "webkitRelativePath": {
1044
+ "type": "string"
1045
+ }
1046
+ },
1047
+ "required": [
1048
+ "lastModified",
1049
+ "name",
1050
+ "size",
1051
+ "type",
1052
+ "webkitRelativePath"
1053
+ ],
1054
+ "additionalProperties": false
1055
+ },
1056
+ "description": "Uploaded files"
1057
+ },
1058
+ "body": {
1059
+ "type": "string",
1060
+ "description": "Request body without the files."
1061
+ },
1062
+ "formData": {
1063
+ "type": "object",
1064
+ "additionalProperties": {},
1065
+ "description": "Form data. If set, the request body will be ignored and the content-type header will be set to `application/x-www-form-urlencoded`."
1066
+ }
1067
+ },
1068
+ "required": ["url"],
1069
+ "additionalProperties": false
1070
+ },
1071
+ "HTTPMethod": {
1072
+ "type": "string",
1073
+ "enum": ["GET", "POST", "HEAD", "OPTIONS", "PATCH", "PUT", "DELETE"]
1074
+ },
1075
+ "PHPRequestHeaders": {
1076
+ "type": "object",
1077
+ "additionalProperties": {
1078
+ "type": "string"
1079
+ }
1080
+ },
1081
+ "PHPRunOptions": {
1082
+ "type": "object",
1083
+ "properties": {
1084
+ "relativeUri": {
1085
+ "type": "string",
1086
+ "description": "Request path following the domain:port part."
1087
+ },
1088
+ "scriptPath": {
1089
+ "type": "string",
1090
+ "description": "Path of the .php file to execute."
1091
+ },
1092
+ "protocol": {
1093
+ "type": "string",
1094
+ "description": "Request protocol."
1095
+ },
1096
+ "method": {
1097
+ "$ref": "#/definitions/HTTPMethod",
1098
+ "description": "Request method. Default: `GET`."
1099
+ },
1100
+ "headers": {
1101
+ "$ref": "#/definitions/PHPRequestHeaders",
1102
+ "description": "Request headers."
1103
+ },
1104
+ "body": {
1105
+ "type": "string",
1106
+ "description": "Request body without the files."
1107
+ },
1108
+ "fileInfos": {
1109
+ "type": "array",
1110
+ "items": {
1111
+ "$ref": "#/definitions/FileInfo"
1112
+ },
1113
+ "description": "Uploaded files."
1114
+ },
1115
+ "code": {
1116
+ "type": "string",
1117
+ "description": "The code snippet to eval instead of a php file."
1118
+ }
1119
+ },
1120
+ "additionalProperties": false
1121
+ },
1122
+ "FileInfo": {
1123
+ "type": "object",
1124
+ "properties": {
1125
+ "key": {
1126
+ "type": "string"
1127
+ },
1128
+ "name": {
1129
+ "type": "string"
1130
+ },
1131
+ "type": {
1132
+ "type": "string"
1133
+ },
1134
+ "data": {
1135
+ "type": "object",
1136
+ "properties": {
1137
+ "BYTES_PER_ELEMENT": {
1138
+ "type": "number"
1139
+ },
1140
+ "buffer": {
1141
+ "type": "object",
1142
+ "properties": {
1143
+ "byteLength": {
1144
+ "type": "number"
1145
+ }
1146
+ },
1147
+ "required": ["byteLength"],
1148
+ "additionalProperties": false
1149
+ },
1150
+ "byteLength": {
1151
+ "type": "number"
1152
+ },
1153
+ "byteOffset": {
1154
+ "type": "number"
1155
+ },
1156
+ "length": {
1157
+ "type": "number"
1158
+ }
1159
+ },
1160
+ "required": [
1161
+ "BYTES_PER_ELEMENT",
1162
+ "buffer",
1163
+ "byteLength",
1164
+ "byteOffset",
1165
+ "length"
1166
+ ],
1167
+ "additionalProperties": {
1168
+ "type": "number"
1169
+ }
1170
+ }
1171
+ },
1172
+ "required": ["key", "name", "type", "data"],
1173
+ "additionalProperties": false
1174
+ },
1175
+ "WordPressInstallationOptions": {
1176
+ "type": "object",
1177
+ "properties": {
1178
+ "adminUsername": {
1179
+ "type": "string"
1180
+ },
1181
+ "adminPassword": {
1182
+ "type": "string"
1183
+ }
1184
+ },
1185
+ "additionalProperties": false
1186
+ }
1187
+ }
1188
+ }