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