@itentialopensource/adapter-terraform_enterprise 0.2.1 → 0.3.1

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.
Files changed (45) hide show
  1. package/AUTH.md +11 -14
  2. package/CALLS.md +575 -22
  3. package/CHANGELOG.md +16 -0
  4. package/CONTRIBUTING.md +1 -160
  5. package/ENHANCE.md +2 -2
  6. package/README.md +32 -23
  7. package/SUMMARY.md +1 -1
  8. package/SYSTEMINFO.md +15 -6
  9. package/adapter.js +157 -329
  10. package/adapterBase.js +549 -879
  11. package/changelogs/CHANGELOG.md +52 -0
  12. package/metadata.json +61 -0
  13. package/package.json +24 -24
  14. package/pronghorn.json +470 -138
  15. package/propertiesSchema.json +431 -31
  16. package/refs?service=git-upload-pack +0 -0
  17. package/report/adapter-openapi.json +3984 -0
  18. package/report/adapter-openapi.yaml +2861 -0
  19. package/report/adapterInfo.json +8 -8
  20. package/report/updateReport1691507498223.json +120 -0
  21. package/report/updateReport1692202520108.json +120 -0
  22. package/report/updateReport1694461356284.json +120 -0
  23. package/report/updateReport1698420765161.json +120 -0
  24. package/sampleProperties.json +63 -2
  25. package/test/integration/adapterTestBasicGet.js +2 -4
  26. package/test/integration/adapterTestConnectivity.js +91 -42
  27. package/test/integration/adapterTestIntegration.js +130 -2
  28. package/test/unit/adapterBaseTestUnit.js +388 -313
  29. package/test/unit/adapterTestUnit.js +338 -112
  30. package/utils/adapterInfo.js +1 -1
  31. package/utils/addAuth.js +1 -1
  32. package/utils/artifactize.js +1 -1
  33. package/utils/checkMigrate.js +1 -1
  34. package/utils/entitiesToDB.js +2 -2
  35. package/utils/findPath.js +1 -1
  36. package/utils/methodDocumentor.js +273 -0
  37. package/utils/modify.js +13 -15
  38. package/utils/packModificationScript.js +1 -1
  39. package/utils/pre-commit.sh +2 -0
  40. package/utils/taskMover.js +309 -0
  41. package/utils/tbScript.js +89 -34
  42. package/utils/tbUtils.js +41 -21
  43. package/utils/testRunner.js +1 -1
  44. package/utils/troubleshootingAdapter.js +9 -6
  45. package/workflows/README.md +0 -3
@@ -0,0 +1,3984 @@
1
+ {
2
+ "openapi": "3.0.0",
3
+ "info": {
4
+ "title": "Terraform",
5
+ "description": "Terraform Cloud is an application that helps teams use Terraform together. It manages Terraform runs in a consistent and reliable environment, and includes easy access to shared state and secret data, access controls for approving changes to infrastructure, a private registry for sharing Terraform modules, detailed policy controls for governing the contents of Terraform configurations, and more.\n\nTerraform Cloud is available as a hosted service at https://app.terraform.io. We offer free accounts for small teams, and paid plans with additional feature sets for medium-sized businesses.\n\nLarge enterprises can purchase Terraform Enterprise, our self-hosted distribution of Terraform Cloud. It offers enterprises a private instance of the Terraform Cloud application, with no resource limits and with additional enterprise-grade architectural features like audit logging and SAML single sign-on.",
6
+ "contact": {
7
+ "email": "apiteam@swagger.io"
8
+ },
9
+ "version": "v2"
10
+ },
11
+ "servers": [
12
+ {
13
+ "url": "https://app.terraform.io/api",
14
+ "variables": {}
15
+ },
16
+ {
17
+ "url": "http://app.terraform.io/api",
18
+ "variables": {}
19
+ }
20
+ ],
21
+ "paths": {
22
+ "/account/details": {
23
+ "get": {
24
+ "tags": [
25
+ "Account"
26
+ ],
27
+ "summary": "GET",
28
+ "description": "Get account details.",
29
+ "operationId": "GET",
30
+ "parameters": [],
31
+ "responses": {
32
+ "200": {
33
+ "description": "successful operation",
34
+ "headers": {},
35
+ "content": {
36
+ "text/plain": {
37
+ "schema": {
38
+ "type": "string",
39
+ "description": "successful operation"
40
+ }
41
+ }
42
+ }
43
+ },
44
+ "400": {
45
+ "description": "failed operation"
46
+ }
47
+ },
48
+ "deprecated": false
49
+ }
50
+ },
51
+ "/account/update": {
52
+ "patch": {
53
+ "tags": [
54
+ "Account"
55
+ ],
56
+ "summary": "updateAccount",
57
+ "description": "Update account details",
58
+ "operationId": "updateAccount",
59
+ "parameters": [],
60
+ "requestBody": {
61
+ "description": "JSON body for update",
62
+ "content": {
63
+ "text/plain": {
64
+ "schema": {
65
+ "type": "string",
66
+ "description": "JSON body for update"
67
+ }
68
+ }
69
+ },
70
+ "required": false
71
+ },
72
+ "responses": {
73
+ "200": {
74
+ "description": "successful operation",
75
+ "headers": {},
76
+ "content": {
77
+ "text/plain": {
78
+ "schema": {
79
+ "type": "string",
80
+ "description": "successful operation"
81
+ }
82
+ }
83
+ }
84
+ },
85
+ "400": {
86
+ "description": "failed operation"
87
+ }
88
+ },
89
+ "deprecated": false
90
+ }
91
+ },
92
+ "/account/password": {
93
+ "patch": {
94
+ "tags": [
95
+ "Account"
96
+ ],
97
+ "summary": "changePassword",
98
+ "description": "Change your password",
99
+ "operationId": "changePassword",
100
+ "parameters": [],
101
+ "requestBody": {
102
+ "description": "",
103
+ "content": {
104
+ "text/plain": {
105
+ "schema": {
106
+ "type": "string"
107
+ }
108
+ }
109
+ },
110
+ "required": false
111
+ },
112
+ "responses": {
113
+ "200": {
114
+ "description": "successful operation",
115
+ "headers": {},
116
+ "content": {
117
+ "text/plain": {
118
+ "schema": {
119
+ "type": "string",
120
+ "description": "successful operation"
121
+ }
122
+ }
123
+ }
124
+ },
125
+ "400": {
126
+ "description": "failed operation"
127
+ }
128
+ },
129
+ "deprecated": false
130
+ }
131
+ },
132
+ "/applies/{id}": {
133
+ "get": {
134
+ "tags": [
135
+ "Applies"
136
+ ],
137
+ "summary": "getApply",
138
+ "description": "Show an apply",
139
+ "operationId": "getApply",
140
+ "parameters": [
141
+ {
142
+ "name": "id",
143
+ "in": "path",
144
+ "description": "The ID of the apply to show.",
145
+ "required": true,
146
+ "style": "simple",
147
+ "schema": {
148
+ "type": "object"
149
+ }
150
+ }
151
+ ],
152
+ "responses": {
153
+ "200": {
154
+ "description": "successful operation",
155
+ "headers": {},
156
+ "content": {
157
+ "text/plain": {
158
+ "schema": {
159
+ "type": "string",
160
+ "description": "successful operation"
161
+ }
162
+ }
163
+ }
164
+ },
165
+ "400": {
166
+ "description": "failed operation"
167
+ }
168
+ },
169
+ "deprecated": false
170
+ }
171
+ },
172
+ "/cost-estimates/{id}": {
173
+ "get": {
174
+ "tags": [
175
+ "CostEstimates"
176
+ ],
177
+ "summary": "getCostEstimate",
178
+ "description": "Show a cost estimate",
179
+ "operationId": "getCostEstimate",
180
+ "parameters": [
181
+ {
182
+ "name": "id",
183
+ "in": "path",
184
+ "description": "The ID of the cost estimate to show..",
185
+ "required": true,
186
+ "style": "simple",
187
+ "schema": {
188
+ "type": "object"
189
+ }
190
+ }
191
+ ],
192
+ "responses": {
193
+ "200": {
194
+ "description": "successful operation",
195
+ "headers": {},
196
+ "content": {
197
+ "text/plain": {
198
+ "schema": {
199
+ "type": "string",
200
+ "description": "successful operation"
201
+ }
202
+ }
203
+ }
204
+ },
205
+ "400": {
206
+ "description": "failed operation"
207
+ }
208
+ },
209
+ "deprecated": false
210
+ }
211
+ },
212
+ "/workspaces/{workspace_id}/notification-configurations": {
213
+ "post": {
214
+ "tags": [
215
+ "NotificationConfigurations"
216
+ ],
217
+ "summary": "createNotificationConfiguration",
218
+ "description": "Create a Notification Configuration",
219
+ "operationId": "createNotificationConfiguration",
220
+ "parameters": [
221
+ {
222
+ "name": "workspace_id",
223
+ "in": "path",
224
+ "description": "",
225
+ "required": true,
226
+ "style": "simple",
227
+ "schema": {
228
+ "type": "string"
229
+ }
230
+ }
231
+ ],
232
+ "requestBody": {
233
+ "description": "",
234
+ "content": {
235
+ "text/plain": {
236
+ "schema": {
237
+ "type": "string"
238
+ }
239
+ }
240
+ },
241
+ "required": false
242
+ },
243
+ "responses": {
244
+ "200": {
245
+ "description": "successful operation",
246
+ "headers": {},
247
+ "content": {
248
+ "text/plain": {
249
+ "schema": {
250
+ "type": "string",
251
+ "description": "successful operation"
252
+ }
253
+ }
254
+ }
255
+ },
256
+ "400": {
257
+ "description": "failed operation"
258
+ }
259
+ },
260
+ "deprecated": false
261
+ },
262
+ "get": {
263
+ "tags": [
264
+ "NotificationConfigurations"
265
+ ],
266
+ "summary": "listNotificationConfigurations",
267
+ "description": "List all notification configurations",
268
+ "operationId": "listNotificationConfigurations",
269
+ "parameters": [
270
+ {
271
+ "name": "workspace_id",
272
+ "in": "path",
273
+ "description": "The ID of the workspace to list configurations from. Obtain this from the workspace settings or the Show Workspace endpoint.",
274
+ "required": true,
275
+ "style": "simple",
276
+ "schema": {
277
+ "type": "string"
278
+ }
279
+ }
280
+ ],
281
+ "responses": {
282
+ "200": {
283
+ "description": "successful operation",
284
+ "headers": {},
285
+ "content": {
286
+ "text/plain": {
287
+ "schema": {
288
+ "type": "string",
289
+ "description": "successful operation"
290
+ }
291
+ }
292
+ }
293
+ },
294
+ "400": {
295
+ "description": "failed operation"
296
+ }
297
+ },
298
+ "deprecated": false
299
+ }
300
+ },
301
+ "/notification-configurations/{notification-configuration-id}": {
302
+ "get": {
303
+ "tags": [
304
+ "NotificationConfigurations"
305
+ ],
306
+ "summary": "getNotificationConfiguration",
307
+ "description": "Get details for a notification configuration",
308
+ "operationId": "getNotificationConfiguration",
309
+ "parameters": [
310
+ {
311
+ "name": "notification-configuration-id",
312
+ "in": "path",
313
+ "description": "The id of the notification configuration to show.",
314
+ "required": true,
315
+ "style": "simple",
316
+ "schema": {
317
+ "type": "string"
318
+ }
319
+ }
320
+ ],
321
+ "responses": {
322
+ "200": {
323
+ "description": "successful operation",
324
+ "headers": {},
325
+ "content": {
326
+ "text/plain": {
327
+ "schema": {
328
+ "type": "string",
329
+ "description": "successful operation"
330
+ }
331
+ }
332
+ }
333
+ },
334
+ "400": {
335
+ "description": "failed operation"
336
+ }
337
+ },
338
+ "deprecated": false
339
+ },
340
+ "patch": {
341
+ "tags": [
342
+ "NotificationConfigurations"
343
+ ],
344
+ "summary": "updateNotificationConfiguration",
345
+ "description": "Update a notification configuration",
346
+ "operationId": "updateNotificationConfiguration",
347
+ "parameters": [
348
+ {
349
+ "name": "notification-configuration-id",
350
+ "in": "path",
351
+ "description": "The id of the notification configuration to update.",
352
+ "required": true,
353
+ "style": "simple",
354
+ "schema": {
355
+ "type": "string"
356
+ }
357
+ }
358
+ ],
359
+ "responses": {
360
+ "200": {
361
+ "description": "successful operation",
362
+ "headers": {},
363
+ "content": {
364
+ "text/plain": {
365
+ "schema": {
366
+ "type": "string",
367
+ "description": "successful operation"
368
+ }
369
+ }
370
+ }
371
+ },
372
+ "400": {
373
+ "description": "failed operation"
374
+ }
375
+ },
376
+ "deprecated": false
377
+ },
378
+ "delete": {
379
+ "tags": [
380
+ "NotificationConfigurations"
381
+ ],
382
+ "summary": "deleteNotificationConfiguration",
383
+ "description": "This endpoint deletes a notification configuration.",
384
+ "operationId": "deleteNotificationConfiguration",
385
+ "parameters": [
386
+ {
387
+ "name": "notification-configuration-id",
388
+ "in": "path",
389
+ "description": "The id of the notification configuration to delete.",
390
+ "required": true,
391
+ "style": "simple",
392
+ "schema": {
393
+ "type": "string"
394
+ }
395
+ }
396
+ ],
397
+ "responses": {
398
+ "200": {
399
+ "description": "successful operation",
400
+ "headers": {},
401
+ "content": {
402
+ "text/plain": {
403
+ "schema": {
404
+ "type": "string",
405
+ "description": "successful operation"
406
+ }
407
+ }
408
+ }
409
+ },
410
+ "400": {
411
+ "description": "failed operation"
412
+ }
413
+ },
414
+ "deprecated": false
415
+ }
416
+ },
417
+ "/notification-configurations/{notification-configuration-id}/actions/verify": {
418
+ "post": {
419
+ "tags": [
420
+ "NotificationConfigurations"
421
+ ],
422
+ "summary": "verifyNotificationConfiguration",
423
+ "description": "This will cause Terraform Cloud to send a verification request for the specified configuration. If a response is received, it will be stored and returned in the delivery-responses attribute. More details in the Notification Verification and Delivery Responses section above.",
424
+ "operationId": "verifyNotificationConfiguration",
425
+ "parameters": [
426
+ {
427
+ "name": "notification-configuration-id",
428
+ "in": "path",
429
+ "description": "The id of the notification configuration to verify.",
430
+ "required": true,
431
+ "style": "simple",
432
+ "schema": {
433
+ "type": "string"
434
+ }
435
+ }
436
+ ],
437
+ "responses": {
438
+ "200": {
439
+ "description": "successful operation",
440
+ "headers": {},
441
+ "content": {
442
+ "text/plain": {
443
+ "schema": {
444
+ "type": "string",
445
+ "description": "successful operation"
446
+ }
447
+ }
448
+ }
449
+ },
450
+ "400": {
451
+ "description": "failed operation"
452
+ }
453
+ },
454
+ "deprecated": false
455
+ }
456
+ },
457
+ "/organizations/{organization_name}/oauth-clients": {
458
+ "get": {
459
+ "tags": [
460
+ "OAuthClients"
461
+ ],
462
+ "summary": "listOauthClients",
463
+ "description": "This endpoint allows you to list VCS connections between an organization and a VCS provider (GitHub, Bitbucket, or GitLab) for use when creating or setting up workspaces.",
464
+ "operationId": "listOauthClients",
465
+ "parameters": [
466
+ {
467
+ "name": "organization_name",
468
+ "in": "path",
469
+ "description": "The name of the organization.",
470
+ "required": true,
471
+ "style": "simple",
472
+ "schema": {
473
+ "type": "string"
474
+ }
475
+ }
476
+ ],
477
+ "responses": {
478
+ "200": {
479
+ "description": "successful operation",
480
+ "headers": {},
481
+ "content": {
482
+ "text/plain": {
483
+ "schema": {
484
+ "type": "string",
485
+ "description": "successful operation"
486
+ }
487
+ }
488
+ }
489
+ },
490
+ "400": {
491
+ "description": "failed operation"
492
+ }
493
+ },
494
+ "deprecated": false
495
+ },
496
+ "post": {
497
+ "tags": [
498
+ "OAuthClients"
499
+ ],
500
+ "summary": "createOAuthClient",
501
+ "description": "Create an OAuth Client",
502
+ "operationId": "createOAuthClient",
503
+ "parameters": [
504
+ {
505
+ "name": "organization_name",
506
+ "in": "path",
507
+ "description": "The name of the organization that will be connected to the VCS provider. The organization must already exist in the system, and the user must have permissions to initiate the connection.",
508
+ "required": true,
509
+ "style": "simple",
510
+ "schema": {
511
+ "type": "string"
512
+ }
513
+ }
514
+ ],
515
+ "requestBody": {
516
+ "description": "",
517
+ "content": {
518
+ "text/plain": {
519
+ "schema": {
520
+ "type": "string"
521
+ }
522
+ }
523
+ },
524
+ "required": false
525
+ },
526
+ "responses": {
527
+ "200": {
528
+ "description": "successful operation",
529
+ "headers": {},
530
+ "content": {
531
+ "text/plain": {
532
+ "schema": {
533
+ "type": "string",
534
+ "description": "successful operation"
535
+ }
536
+ }
537
+ }
538
+ },
539
+ "400": {
540
+ "description": "failed operation"
541
+ }
542
+ },
543
+ "deprecated": false
544
+ }
545
+ },
546
+ "/oauth-clients/{id}": {
547
+ "get": {
548
+ "tags": [
549
+ "OAuthClients"
550
+ ],
551
+ "summary": "showOAuthClient",
552
+ "description": "Show an OAuth Client",
553
+ "operationId": "showOAuthClient",
554
+ "parameters": [
555
+ {
556
+ "name": "id",
557
+ "in": "path",
558
+ "description": "The ID of the OAuth Client to show",
559
+ "required": true,
560
+ "style": "simple",
561
+ "schema": {
562
+ "type": "string"
563
+ }
564
+ }
565
+ ],
566
+ "responses": {
567
+ "200": {
568
+ "description": "successful operation",
569
+ "headers": {},
570
+ "content": {
571
+ "text/plain": {
572
+ "schema": {
573
+ "type": "string",
574
+ "description": "successful operation"
575
+ }
576
+ }
577
+ }
578
+ },
579
+ "400": {
580
+ "description": "failed operation"
581
+ }
582
+ },
583
+ "deprecated": false
584
+ },
585
+ "patch": {
586
+ "tags": [
587
+ "OAuthClients"
588
+ ],
589
+ "summary": "updateOAuthClient",
590
+ "description": "Update an OAuth Client",
591
+ "operationId": "updateOAuthClient",
592
+ "parameters": [
593
+ {
594
+ "name": "id",
595
+ "in": "path",
596
+ "description": "The ID of the OAuth Client to update.",
597
+ "required": true,
598
+ "style": "simple",
599
+ "schema": {
600
+ "type": "string"
601
+ }
602
+ }
603
+ ],
604
+ "requestBody": {
605
+ "description": "",
606
+ "content": {
607
+ "text/plain": {
608
+ "schema": {
609
+ "type": "string"
610
+ }
611
+ }
612
+ },
613
+ "required": false
614
+ },
615
+ "responses": {
616
+ "200": {
617
+ "description": "successful operation",
618
+ "headers": {},
619
+ "content": {
620
+ "text/plain": {
621
+ "schema": {
622
+ "type": "string",
623
+ "description": "successful operation"
624
+ }
625
+ }
626
+ }
627
+ },
628
+ "400": {
629
+ "description": "failed operation"
630
+ }
631
+ },
632
+ "deprecated": false
633
+ },
634
+ "delete": {
635
+ "tags": [
636
+ "OAuthClients"
637
+ ],
638
+ "summary": "destroyOAuthClient",
639
+ "description": "Destroy an OAuth Client",
640
+ "operationId": "destroyOAuthClient",
641
+ "parameters": [
642
+ {
643
+ "name": "id",
644
+ "in": "path",
645
+ "description": "The ID of the OAuth Client to destroy",
646
+ "required": true,
647
+ "style": "simple",
648
+ "schema": {
649
+ "type": "string"
650
+ }
651
+ }
652
+ ],
653
+ "responses": {
654
+ "200": {
655
+ "description": "successful operation",
656
+ "headers": {},
657
+ "content": {
658
+ "text/plain": {
659
+ "schema": {
660
+ "type": "string",
661
+ "description": "successful operation"
662
+ }
663
+ }
664
+ }
665
+ },
666
+ "400": {
667
+ "description": "failed operation"
668
+ }
669
+ },
670
+ "deprecated": false
671
+ }
672
+ },
673
+ "/oauth-clients/{oauth_client_id}/oauth-tokens": {
674
+ "get": {
675
+ "tags": [
676
+ "OAuthTokens"
677
+ ],
678
+ "summary": "listOAuthTokens",
679
+ "description": "List all the OAuth Tokens for a given OAuth Client",
680
+ "operationId": "listOAuthTokens",
681
+ "parameters": [
682
+ {
683
+ "name": "oauth_client_id",
684
+ "in": "path",
685
+ "description": "The ID of the OAuth Client",
686
+ "required": true,
687
+ "style": "simple",
688
+ "schema": {
689
+ "type": "string"
690
+ }
691
+ }
692
+ ],
693
+ "responses": {
694
+ "200": {
695
+ "description": "successful operation",
696
+ "headers": {},
697
+ "content": {
698
+ "text/plain": {
699
+ "schema": {
700
+ "type": "string",
701
+ "description": "successful operation"
702
+ }
703
+ }
704
+ }
705
+ },
706
+ "400": {
707
+ "description": "failed operation"
708
+ }
709
+ },
710
+ "deprecated": false
711
+ }
712
+ },
713
+ "/oauth-tokens/{id}": {
714
+ "get": {
715
+ "tags": [
716
+ "OAuthTokens"
717
+ ],
718
+ "summary": "showOAuthToken",
719
+ "description": "Show an OAuth Token",
720
+ "operationId": "showOAuthToken",
721
+ "parameters": [
722
+ {
723
+ "name": "id",
724
+ "in": "path",
725
+ "description": "The ID of the OAuth token to show",
726
+ "required": true,
727
+ "style": "simple",
728
+ "schema": {
729
+ "type": "string"
730
+ }
731
+ }
732
+ ],
733
+ "responses": {
734
+ "200": {
735
+ "description": "successful operation",
736
+ "headers": {},
737
+ "content": {
738
+ "text/plain": {
739
+ "schema": {
740
+ "type": "string",
741
+ "description": "successful operation"
742
+ }
743
+ }
744
+ }
745
+ },
746
+ "400": {
747
+ "description": "failed operation"
748
+ }
749
+ },
750
+ "deprecated": false
751
+ },
752
+ "patch": {
753
+ "tags": [
754
+ "OAuthTokens"
755
+ ],
756
+ "summary": "updateOAuthToken",
757
+ "description": "Update an OAuth Token",
758
+ "operationId": "updateOAuthToken",
759
+ "parameters": [
760
+ {
761
+ "name": "id",
762
+ "in": "path",
763
+ "description": "The ID of the OAuth token to update",
764
+ "required": true,
765
+ "style": "simple",
766
+ "schema": {
767
+ "type": "string"
768
+ }
769
+ }
770
+ ],
771
+ "requestBody": {
772
+ "description": "",
773
+ "content": {
774
+ "text/plain": {
775
+ "schema": {
776
+ "type": "string"
777
+ }
778
+ }
779
+ },
780
+ "required": false
781
+ },
782
+ "responses": {
783
+ "200": {
784
+ "description": "successful operation",
785
+ "headers": {},
786
+ "content": {
787
+ "text/plain": {
788
+ "schema": {
789
+ "type": "string",
790
+ "description": "successful operation"
791
+ }
792
+ }
793
+ }
794
+ },
795
+ "400": {
796
+ "description": "failed operation"
797
+ }
798
+ },
799
+ "deprecated": false
800
+ },
801
+ "delete": {
802
+ "tags": [
803
+ "OAuthTokens"
804
+ ],
805
+ "summary": "destroyOAuthToken",
806
+ "description": "Destroy an OAuth Token",
807
+ "operationId": "destroyOAuthToken",
808
+ "parameters": [
809
+ {
810
+ "name": "id",
811
+ "in": "path",
812
+ "description": "The ID of the OAuth Token to destroy",
813
+ "required": true,
814
+ "style": "simple",
815
+ "schema": {
816
+ "type": "string"
817
+ }
818
+ }
819
+ ],
820
+ "responses": {
821
+ "200": {
822
+ "description": "successful operation",
823
+ "headers": {},
824
+ "content": {
825
+ "text/plain": {
826
+ "schema": {
827
+ "type": "string",
828
+ "description": "successful operation"
829
+ }
830
+ }
831
+ }
832
+ },
833
+ "400": {
834
+ "description": "failed operation"
835
+ }
836
+ },
837
+ "deprecated": false
838
+ }
839
+ },
840
+ "/organizations": {
841
+ "get": {
842
+ "tags": [
843
+ "Organizations"
844
+ ],
845
+ "summary": "listOrganizations",
846
+ "description": "List the organizations",
847
+ "operationId": "listOrganizations",
848
+ "parameters": [],
849
+ "responses": {
850
+ "200": {
851
+ "description": "successful operation",
852
+ "headers": {},
853
+ "content": {
854
+ "text/plain": {
855
+ "schema": {
856
+ "type": "string",
857
+ "description": "successful operation"
858
+ }
859
+ }
860
+ }
861
+ },
862
+ "400": {
863
+ "description": "failed operation"
864
+ }
865
+ },
866
+ "deprecated": false
867
+ }
868
+ },
869
+ "/organizations/{organization_name}": {
870
+ "get": {
871
+ "tags": [
872
+ "Organizations"
873
+ ],
874
+ "summary": "getOrganization",
875
+ "description": "Get an organization",
876
+ "operationId": "getOrganization",
877
+ "parameters": [
878
+ {
879
+ "name": "organization_name",
880
+ "in": "path",
881
+ "description": "The name of the organization to show",
882
+ "required": true,
883
+ "style": "simple",
884
+ "schema": {
885
+ "type": "string"
886
+ }
887
+ }
888
+ ],
889
+ "responses": {
890
+ "200": {
891
+ "description": "successful operation",
892
+ "headers": {},
893
+ "content": {
894
+ "text/plain": {
895
+ "schema": {
896
+ "type": "string",
897
+ "description": "successful operation"
898
+ }
899
+ }
900
+ }
901
+ },
902
+ "400": {
903
+ "description": "failed operation"
904
+ }
905
+ },
906
+ "deprecated": false
907
+ }
908
+ },
909
+ "/organizations/{organization_name}/organization-memberships": {
910
+ "post": {
911
+ "tags": [
912
+ "OrganizationMemberships"
913
+ ],
914
+ "summary": "InviteUserToOrganization",
915
+ "description": "Invite a User to an Organization",
916
+ "operationId": "InviteUserToOrganization",
917
+ "parameters": [
918
+ {
919
+ "name": "organization_name",
920
+ "in": "path",
921
+ "description": "The name of the organization the user will be invited to join. The inviting user must have permission to manage organization memberships",
922
+ "required": true,
923
+ "style": "simple",
924
+ "schema": {
925
+ "type": "string"
926
+ }
927
+ }
928
+ ],
929
+ "requestBody": {
930
+ "description": "",
931
+ "content": {
932
+ "text/plain": {
933
+ "schema": {
934
+ "type": "string"
935
+ }
936
+ }
937
+ },
938
+ "required": false
939
+ },
940
+ "responses": {
941
+ "200": {
942
+ "description": "successful operation",
943
+ "headers": {},
944
+ "content": {
945
+ "text/plain": {
946
+ "schema": {
947
+ "type": "string",
948
+ "description": "successful operation"
949
+ }
950
+ }
951
+ }
952
+ },
953
+ "400": {
954
+ "description": "failed operation"
955
+ }
956
+ },
957
+ "deprecated": false
958
+ },
959
+ "get": {
960
+ "tags": [
961
+ "OrganizationMemberships"
962
+ ],
963
+ "summary": "listMembershipsOrganization",
964
+ "description": "List Memberships for an Organization",
965
+ "operationId": "listMembershipsOrganization",
966
+ "parameters": [
967
+ {
968
+ "name": "organization_name",
969
+ "in": "path",
970
+ "description": "The name of the organization to list the memberships of.",
971
+ "required": true,
972
+ "style": "simple",
973
+ "schema": {
974
+ "type": "string"
975
+ }
976
+ },
977
+ {
978
+ "name": "q",
979
+ "in": "query",
980
+ "description": "Optional. A search query string. Organization memberships are searchable by user name and email.",
981
+ "style": "form",
982
+ "explode": true,
983
+ "schema": {
984
+ "type": "string"
985
+ }
986
+ },
987
+ {
988
+ "name": "filter[status]",
989
+ "in": "query",
990
+ "description": "Optional. If specified, restricts results to those with the matching status value. Valid values are invited and active.",
991
+ "style": "form",
992
+ "explode": true,
993
+ "schema": {
994
+ "type": "string"
995
+ }
996
+ },
997
+ {
998
+ "name": "page[number]",
999
+ "in": "query",
1000
+ "description": "Optional. If omitted, the endpoint will return the first page.",
1001
+ "style": "form",
1002
+ "explode": true,
1003
+ "schema": {
1004
+ "type": "string"
1005
+ }
1006
+ },
1007
+ {
1008
+ "name": "page[size]",
1009
+ "in": "query",
1010
+ "description": "Optional. If omitted, the endpoint will return 20 users per page.",
1011
+ "style": "form",
1012
+ "explode": true,
1013
+ "schema": {
1014
+ "type": "string"
1015
+ }
1016
+ }
1017
+ ],
1018
+ "responses": {
1019
+ "200": {
1020
+ "description": "successful operation",
1021
+ "headers": {},
1022
+ "content": {
1023
+ "text/plain": {
1024
+ "schema": {
1025
+ "type": "string",
1026
+ "description": "successful operation"
1027
+ }
1028
+ }
1029
+ }
1030
+ },
1031
+ "400": {
1032
+ "description": "failed operation"
1033
+ }
1034
+ },
1035
+ "deprecated": false
1036
+ }
1037
+ },
1038
+ "/organization-memberships": {
1039
+ "get": {
1040
+ "tags": [
1041
+ "OrganizationMemberships"
1042
+ ],
1043
+ "summary": "listUserOwnMemberships",
1044
+ "description": "List User's Own Memberships",
1045
+ "operationId": "listUserOwnMemberships",
1046
+ "parameters": [],
1047
+ "responses": {
1048
+ "200": {
1049
+ "description": "successful operation",
1050
+ "headers": {},
1051
+ "content": {
1052
+ "text/plain": {
1053
+ "schema": {
1054
+ "type": "string",
1055
+ "description": "successful operation"
1056
+ }
1057
+ }
1058
+ }
1059
+ },
1060
+ "400": {
1061
+ "description": "failed operation"
1062
+ }
1063
+ },
1064
+ "deprecated": false
1065
+ }
1066
+ },
1067
+ "/organization-memberships/{organization_membership_id}": {
1068
+ "get": {
1069
+ "tags": [
1070
+ "OrganizationMemberships"
1071
+ ],
1072
+ "summary": "showMembership",
1073
+ "description": "Show a Membership",
1074
+ "operationId": "showMembership",
1075
+ "parameters": [
1076
+ {
1077
+ "name": "organization_membership_id",
1078
+ "in": "path",
1079
+ "description": "The organization membership",
1080
+ "required": true,
1081
+ "style": "simple",
1082
+ "schema": {
1083
+ "type": "string"
1084
+ }
1085
+ }
1086
+ ],
1087
+ "responses": {
1088
+ "200": {
1089
+ "description": "successful operation",
1090
+ "headers": {},
1091
+ "content": {
1092
+ "text/plain": {
1093
+ "schema": {
1094
+ "type": "string",
1095
+ "description": "successful operation"
1096
+ }
1097
+ }
1098
+ }
1099
+ },
1100
+ "400": {
1101
+ "description": "failed operation"
1102
+ }
1103
+ },
1104
+ "deprecated": false
1105
+ },
1106
+ "delete": {
1107
+ "tags": [
1108
+ "OrganizationMemberships"
1109
+ ],
1110
+ "summary": "removeUserFromOrganization",
1111
+ "description": "Remove User from Organization",
1112
+ "operationId": "removeUserFromOrganization",
1113
+ "parameters": [
1114
+ {
1115
+ "name": "organization_membership_id",
1116
+ "in": "path",
1117
+ "description": "The organization membership",
1118
+ "required": true,
1119
+ "style": "simple",
1120
+ "schema": {
1121
+ "type": "string"
1122
+ }
1123
+ }
1124
+ ],
1125
+ "responses": {
1126
+ "200": {
1127
+ "description": "successful operation",
1128
+ "headers": {},
1129
+ "content": {
1130
+ "text/plain": {
1131
+ "schema": {
1132
+ "type": "string",
1133
+ "description": "successful operation"
1134
+ }
1135
+ }
1136
+ }
1137
+ },
1138
+ "400": {
1139
+ "description": "failed operation"
1140
+ }
1141
+ },
1142
+ "deprecated": false
1143
+ }
1144
+ },
1145
+ "/organizations/{organization_name}/authentication-token": {
1146
+ "post": {
1147
+ "tags": [
1148
+ "OrganizationToken"
1149
+ ],
1150
+ "summary": "generateOrganizationToken",
1151
+ "description": "Generate a new organization token",
1152
+ "operationId": "generateOrganizationToken",
1153
+ "parameters": [
1154
+ {
1155
+ "name": "organization_name",
1156
+ "in": "path",
1157
+ "description": "The name of the organization to generate a token for.",
1158
+ "required": true,
1159
+ "style": "simple",
1160
+ "schema": {
1161
+ "type": "string"
1162
+ }
1163
+ }
1164
+ ],
1165
+ "responses": {
1166
+ "200": {
1167
+ "description": "successful operation",
1168
+ "headers": {},
1169
+ "content": {
1170
+ "text/plain": {
1171
+ "schema": {
1172
+ "type": "string",
1173
+ "description": "successful operation"
1174
+ }
1175
+ }
1176
+ }
1177
+ },
1178
+ "400": {
1179
+ "description": "failed operation"
1180
+ }
1181
+ },
1182
+ "deprecated": false
1183
+ },
1184
+ "delete": {
1185
+ "tags": [
1186
+ "OrganizationToken"
1187
+ ],
1188
+ "summary": "deleteOrganizationToken",
1189
+ "description": "Delete the organization token",
1190
+ "operationId": "deleteOrganizationToken",
1191
+ "parameters": [
1192
+ {
1193
+ "name": "organization_name",
1194
+ "in": "path",
1195
+ "description": "Which organization's token should be deleted.",
1196
+ "required": true,
1197
+ "style": "simple",
1198
+ "schema": {
1199
+ "type": "string"
1200
+ }
1201
+ }
1202
+ ],
1203
+ "responses": {
1204
+ "200": {
1205
+ "description": "successful operation",
1206
+ "headers": {},
1207
+ "content": {
1208
+ "text/plain": {
1209
+ "schema": {
1210
+ "type": "string",
1211
+ "description": "successful operation"
1212
+ }
1213
+ }
1214
+ }
1215
+ },
1216
+ "400": {
1217
+ "description": "failed operation"
1218
+ }
1219
+ },
1220
+ "deprecated": false
1221
+ }
1222
+ },
1223
+ "/plan-exports": {
1224
+ "post": {
1225
+ "tags": [
1226
+ "PlanExports"
1227
+ ],
1228
+ "summary": "createPlanExport",
1229
+ "description": "This endpoint exports data from a plan in the specified format. The export process is asynchronous, and the resulting data becomes downloadable when its status is \"finished\". The data is then available for one hour before expiring. After the hour is up, a new export can be created.",
1230
+ "operationId": "createPlanExport",
1231
+ "parameters": [],
1232
+ "requestBody": {
1233
+ "description": "",
1234
+ "content": {
1235
+ "text/plain": {
1236
+ "schema": {
1237
+ "type": "string"
1238
+ }
1239
+ }
1240
+ },
1241
+ "required": false
1242
+ },
1243
+ "responses": {
1244
+ "200": {
1245
+ "description": "successful operation",
1246
+ "headers": {},
1247
+ "content": {
1248
+ "text/plain": {
1249
+ "schema": {
1250
+ "type": "string",
1251
+ "description": "successful operation"
1252
+ }
1253
+ }
1254
+ }
1255
+ },
1256
+ "400": {
1257
+ "description": "failed operation"
1258
+ }
1259
+ },
1260
+ "deprecated": false
1261
+ }
1262
+ },
1263
+ "/plan-exports/{id}": {
1264
+ "get": {
1265
+ "tags": [
1266
+ "PlanExports"
1267
+ ],
1268
+ "summary": "showPlanExport",
1269
+ "description": "Show a plan export",
1270
+ "operationId": "showPlanExport",
1271
+ "parameters": [
1272
+ {
1273
+ "name": "id",
1274
+ "in": "path",
1275
+ "description": "The ID of the plan export to show.",
1276
+ "required": true,
1277
+ "style": "simple",
1278
+ "schema": {
1279
+ "type": "string"
1280
+ }
1281
+ }
1282
+ ],
1283
+ "responses": {
1284
+ "200": {
1285
+ "description": "successful operation",
1286
+ "headers": {},
1287
+ "content": {
1288
+ "text/plain": {
1289
+ "schema": {
1290
+ "type": "string",
1291
+ "description": "successful operation"
1292
+ }
1293
+ }
1294
+ }
1295
+ },
1296
+ "400": {
1297
+ "description": "failed operation"
1298
+ }
1299
+ },
1300
+ "deprecated": false
1301
+ },
1302
+ "delete": {
1303
+ "tags": [
1304
+ "PlanExports"
1305
+ ],
1306
+ "summary": "Delete exported plan data",
1307
+ "description": "Plan exports expire after being available for one hour, but they can be deleted manually as well.",
1308
+ "operationId": "Deleteexportedplandata",
1309
+ "parameters": [
1310
+ {
1311
+ "name": "id",
1312
+ "in": "path",
1313
+ "description": "The ID of the plan export",
1314
+ "required": true,
1315
+ "style": "simple",
1316
+ "schema": {
1317
+ "type": "string"
1318
+ }
1319
+ }
1320
+ ],
1321
+ "responses": {
1322
+ "200": {
1323
+ "description": "successful operation",
1324
+ "headers": {},
1325
+ "content": {
1326
+ "text/plain": {
1327
+ "schema": {
1328
+ "type": "string",
1329
+ "description": "successful operation"
1330
+ }
1331
+ }
1332
+ }
1333
+ },
1334
+ "400": {
1335
+ "description": "failed operation"
1336
+ }
1337
+ },
1338
+ "deprecated": false
1339
+ }
1340
+ },
1341
+ "/plan-exports/{id}/download": {
1342
+ "get": {
1343
+ "tags": [
1344
+ "PlanExports"
1345
+ ],
1346
+ "summary": "downloadPlanExport",
1347
+ "description": "This endpoint generates a temporary URL to the location of the exported plan data in a .tar.gz archive, and then redirects to that link. If using a client that can follow redirects, you can use this endpoint to save the .tar.gz archive locally without needing to save the temporary URL.",
1348
+ "operationId": "downloadPlanExport",
1349
+ "parameters": [
1350
+ {
1351
+ "name": "id",
1352
+ "in": "path",
1353
+ "description": "The ID of the plan export.",
1354
+ "required": true,
1355
+ "style": "simple",
1356
+ "schema": {
1357
+ "type": "string"
1358
+ }
1359
+ }
1360
+ ],
1361
+ "responses": {
1362
+ "200": {
1363
+ "description": "successful operation",
1364
+ "headers": {},
1365
+ "content": {
1366
+ "text/plain": {
1367
+ "schema": {
1368
+ "type": "string",
1369
+ "description": "successful operation"
1370
+ }
1371
+ }
1372
+ }
1373
+ },
1374
+ "400": {
1375
+ "description": "failed operation"
1376
+ }
1377
+ },
1378
+ "deprecated": false
1379
+ }
1380
+ },
1381
+ "/plans/{id}": {
1382
+ "get": {
1383
+ "tags": [
1384
+ "Plans"
1385
+ ],
1386
+ "summary": "showPlan",
1387
+ "description": "Show a plan",
1388
+ "operationId": "showPlan",
1389
+ "parameters": [
1390
+ {
1391
+ "name": "id",
1392
+ "in": "path",
1393
+ "description": "The ID of the plan to show",
1394
+ "required": true,
1395
+ "style": "simple",
1396
+ "schema": {
1397
+ "type": "string"
1398
+ }
1399
+ }
1400
+ ],
1401
+ "responses": {
1402
+ "200": {
1403
+ "description": "successful operation",
1404
+ "headers": {},
1405
+ "content": {
1406
+ "text/plain": {
1407
+ "schema": {
1408
+ "type": "string",
1409
+ "description": "successful operation"
1410
+ }
1411
+ }
1412
+ }
1413
+ },
1414
+ "400": {
1415
+ "description": "failed operation"
1416
+ }
1417
+ },
1418
+ "deprecated": false
1419
+ }
1420
+ },
1421
+ "/organizations/{organization_name}/policies": {
1422
+ "post": {
1423
+ "tags": [
1424
+ "Policies"
1425
+ ],
1426
+ "summary": "createPolicy",
1427
+ "description": "Create a Policy",
1428
+ "operationId": "createPolicy",
1429
+ "parameters": [
1430
+ {
1431
+ "name": "organization_name",
1432
+ "in": "path",
1433
+ "description": "The organization to create the policy in. The organization must already exist in the system, and the token authenticating the API request must belong to the \"owners\" team or a member of the \"owners\" team.",
1434
+ "required": true,
1435
+ "style": "simple",
1436
+ "schema": {
1437
+ "type": "string"
1438
+ }
1439
+ }
1440
+ ],
1441
+ "requestBody": {
1442
+ "description": "",
1443
+ "content": {
1444
+ "text/plain": {
1445
+ "schema": {
1446
+ "type": "string"
1447
+ }
1448
+ }
1449
+ },
1450
+ "required": false
1451
+ },
1452
+ "responses": {
1453
+ "200": {
1454
+ "description": "successful operation",
1455
+ "headers": {},
1456
+ "content": {
1457
+ "text/plain": {
1458
+ "schema": {
1459
+ "type": "string",
1460
+ "description": "successful operation"
1461
+ }
1462
+ }
1463
+ }
1464
+ },
1465
+ "400": {
1466
+ "description": "failed operation"
1467
+ }
1468
+ },
1469
+ "deprecated": false
1470
+ },
1471
+ "get": {
1472
+ "tags": [
1473
+ "Policies"
1474
+ ],
1475
+ "summary": "listPolicies",
1476
+ "description": "List Policies",
1477
+ "operationId": "listPolicies",
1478
+ "parameters": [
1479
+ {
1480
+ "name": "organization_name",
1481
+ "in": "path",
1482
+ "description": "The organization to list policies for.",
1483
+ "required": true,
1484
+ "style": "simple",
1485
+ "schema": {
1486
+ "type": "string"
1487
+ }
1488
+ },
1489
+ {
1490
+ "name": "page[number]",
1491
+ "in": "query",
1492
+ "description": "Optional. If omitted, the endpoint will return the first page.",
1493
+ "style": "form",
1494
+ "explode": true,
1495
+ "schema": {
1496
+ "type": "string"
1497
+ }
1498
+ },
1499
+ {
1500
+ "name": "page[size]",
1501
+ "in": "query",
1502
+ "description": "Optional. If omitted, the endpoint will return 20 policies per page.",
1503
+ "style": "form",
1504
+ "explode": true,
1505
+ "schema": {
1506
+ "type": "string"
1507
+ }
1508
+ },
1509
+ {
1510
+ "name": "search[name]",
1511
+ "in": "query",
1512
+ "description": "Optional. Allows searching the organization's policies by name.",
1513
+ "style": "form",
1514
+ "explode": true,
1515
+ "schema": {
1516
+ "type": "string"
1517
+ }
1518
+ }
1519
+ ],
1520
+ "responses": {
1521
+ "200": {
1522
+ "description": "successful operation",
1523
+ "headers": {},
1524
+ "content": {
1525
+ "text/plain": {
1526
+ "schema": {
1527
+ "type": "string",
1528
+ "description": "successful operation"
1529
+ }
1530
+ }
1531
+ }
1532
+ },
1533
+ "400": {
1534
+ "description": "failed operation"
1535
+ }
1536
+ },
1537
+ "deprecated": false
1538
+ }
1539
+ },
1540
+ "/policies/{policy_id}": {
1541
+ "get": {
1542
+ "tags": [
1543
+ "Policies"
1544
+ ],
1545
+ "summary": "showPolicy",
1546
+ "description": "Show a Policy",
1547
+ "operationId": "showPolicy",
1548
+ "parameters": [
1549
+ {
1550
+ "name": "policy_id",
1551
+ "in": "path",
1552
+ "description": "The ID of the policy to show. Use the \"List Policies\" endpoint to find IDs.",
1553
+ "required": true,
1554
+ "style": "simple",
1555
+ "schema": {
1556
+ "type": "string"
1557
+ }
1558
+ }
1559
+ ],
1560
+ "responses": {
1561
+ "200": {
1562
+ "description": "successful operation",
1563
+ "headers": {},
1564
+ "content": {
1565
+ "text/plain": {
1566
+ "schema": {
1567
+ "type": "string",
1568
+ "description": "successful operation"
1569
+ }
1570
+ }
1571
+ }
1572
+ },
1573
+ "400": {
1574
+ "description": "failed operation"
1575
+ }
1576
+ },
1577
+ "deprecated": false
1578
+ },
1579
+ "patch": {
1580
+ "tags": [
1581
+ "Policies"
1582
+ ],
1583
+ "summary": "updatePolicy",
1584
+ "description": "This endpoint can update the enforcement mode of an existing policy. To update the policy code itself, use the upload endpoint.",
1585
+ "operationId": "updatePolicy",
1586
+ "parameters": [
1587
+ {
1588
+ "name": "policy_id",
1589
+ "in": "path",
1590
+ "description": "The ID of the policy to update. Use the \"List Policies\" endpoint to find IDs.",
1591
+ "required": true,
1592
+ "style": "simple",
1593
+ "schema": {
1594
+ "type": "string"
1595
+ }
1596
+ }
1597
+ ],
1598
+ "requestBody": {
1599
+ "description": "",
1600
+ "content": {
1601
+ "text/plain": {
1602
+ "schema": {
1603
+ "type": "string"
1604
+ }
1605
+ }
1606
+ },
1607
+ "required": false
1608
+ },
1609
+ "responses": {
1610
+ "200": {
1611
+ "description": "successful operation",
1612
+ "headers": {},
1613
+ "content": {
1614
+ "text/plain": {
1615
+ "schema": {
1616
+ "type": "string",
1617
+ "description": "successful operation"
1618
+ }
1619
+ }
1620
+ }
1621
+ },
1622
+ "400": {
1623
+ "description": "failed operation"
1624
+ }
1625
+ },
1626
+ "deprecated": false
1627
+ },
1628
+ "delete": {
1629
+ "tags": [
1630
+ "Policies"
1631
+ ],
1632
+ "summary": "deletePolicy",
1633
+ "description": "Delete a Policy",
1634
+ "operationId": "deletePolicy",
1635
+ "parameters": [
1636
+ {
1637
+ "name": "policy_id",
1638
+ "in": "path",
1639
+ "description": "The ID of the policy to delete. Use the \"List Policies\" endpoint to find IDs.",
1640
+ "required": true,
1641
+ "style": "simple",
1642
+ "schema": {
1643
+ "type": "string"
1644
+ }
1645
+ }
1646
+ ],
1647
+ "responses": {
1648
+ "200": {
1649
+ "description": "successful operation",
1650
+ "headers": {},
1651
+ "content": {
1652
+ "text/plain": {
1653
+ "schema": {
1654
+ "type": "string",
1655
+ "description": "successful operation"
1656
+ }
1657
+ }
1658
+ }
1659
+ },
1660
+ "400": {
1661
+ "description": "failed operation"
1662
+ }
1663
+ },
1664
+ "deprecated": false
1665
+ }
1666
+ },
1667
+ "/policies/{policy_id}/upload": {
1668
+ "put": {
1669
+ "tags": [
1670
+ "Policies"
1671
+ ],
1672
+ "summary": "uploadPolicy",
1673
+ "description": "Upload a Policy",
1674
+ "operationId": "uploadPolicy",
1675
+ "parameters": [
1676
+ {
1677
+ "name": "policy_id",
1678
+ "in": "path",
1679
+ "description": "The ID of the policy to upload code to. Use the \"List Policies\" endpoint (or the response to a \"Create Policy\" request) to find IDs.",
1680
+ "required": true,
1681
+ "style": "simple",
1682
+ "schema": {
1683
+ "type": "string"
1684
+ }
1685
+ }
1686
+ ],
1687
+ "responses": {
1688
+ "200": {
1689
+ "description": "successful operation",
1690
+ "headers": {},
1691
+ "content": {
1692
+ "text/plain": {
1693
+ "schema": {
1694
+ "type": "string",
1695
+ "description": "successful operation"
1696
+ }
1697
+ }
1698
+ }
1699
+ },
1700
+ "400": {
1701
+ "description": "failed operation"
1702
+ }
1703
+ },
1704
+ "deprecated": false
1705
+ }
1706
+ },
1707
+ "/runs/{run_id}/policy-checks": {
1708
+ "get": {
1709
+ "tags": [
1710
+ "PolicyChecks"
1711
+ ],
1712
+ "summary": "listPolicyChecks",
1713
+ "description": "This endpoint lists the policy checks in a run.",
1714
+ "operationId": "listPolicyChecks",
1715
+ "parameters": [
1716
+ {
1717
+ "name": "run_id",
1718
+ "in": "path",
1719
+ "description": "specifies the run ID for which to list policy checks",
1720
+ "required": true,
1721
+ "style": "simple",
1722
+ "schema": {
1723
+ "type": "string"
1724
+ }
1725
+ }
1726
+ ],
1727
+ "responses": {
1728
+ "200": {
1729
+ "description": "successful operation",
1730
+ "headers": {},
1731
+ "content": {
1732
+ "text/plain": {
1733
+ "schema": {
1734
+ "type": "string",
1735
+ "description": "successful operation"
1736
+ }
1737
+ }
1738
+ }
1739
+ },
1740
+ "400": {
1741
+ "description": "failed operation"
1742
+ }
1743
+ },
1744
+ "deprecated": false
1745
+ }
1746
+ },
1747
+ "/policy-checks/{policy_check_id}/actions/override": {
1748
+ "post": {
1749
+ "tags": [
1750
+ "PolicyChecks"
1751
+ ],
1752
+ "summary": "overridePolicy",
1753
+ "description": "This endpoint overrides a soft-mandatory or warning policy.",
1754
+ "operationId": "overridePolicy",
1755
+ "parameters": [
1756
+ {
1757
+ "name": "policy_check_id",
1758
+ "in": "path",
1759
+ "description": "specifies the ID for the policy check to override",
1760
+ "required": true,
1761
+ "style": "simple",
1762
+ "schema": {
1763
+ "type": "string"
1764
+ }
1765
+ }
1766
+ ],
1767
+ "responses": {
1768
+ "200": {
1769
+ "description": "successful operation",
1770
+ "headers": {},
1771
+ "content": {
1772
+ "text/plain": {
1773
+ "schema": {
1774
+ "type": "string",
1775
+ "description": "successful operation"
1776
+ }
1777
+ }
1778
+ }
1779
+ },
1780
+ "400": {
1781
+ "description": "failed operation"
1782
+ }
1783
+ },
1784
+ "deprecated": false
1785
+ }
1786
+ },
1787
+ "/organizations/{organization_name}/policy-sets": {
1788
+ "post": {
1789
+ "tags": [
1790
+ "PolicySets"
1791
+ ],
1792
+ "summary": "createPolicySet",
1793
+ "description": "Create a Policy Set",
1794
+ "operationId": "createPolicySet",
1795
+ "parameters": [
1796
+ {
1797
+ "name": "organization_name",
1798
+ "in": "path",
1799
+ "description": "The organization to create the policy set in. The organization must already exist in the system, and the token authenticating the API request must belong to the \"owners\" team or a member of the \"owners\" team.",
1800
+ "required": true,
1801
+ "style": "simple",
1802
+ "schema": {
1803
+ "type": "string"
1804
+ }
1805
+ }
1806
+ ],
1807
+ "requestBody": {
1808
+ "description": "",
1809
+ "content": {
1810
+ "text/plain": {
1811
+ "schema": {
1812
+ "type": "string"
1813
+ }
1814
+ }
1815
+ },
1816
+ "required": false
1817
+ },
1818
+ "responses": {
1819
+ "200": {
1820
+ "description": "successful operation",
1821
+ "headers": {},
1822
+ "content": {
1823
+ "text/plain": {
1824
+ "schema": {
1825
+ "type": "string",
1826
+ "description": "successful operation"
1827
+ }
1828
+ }
1829
+ }
1830
+ },
1831
+ "400": {
1832
+ "description": "failed operation"
1833
+ }
1834
+ },
1835
+ "deprecated": false
1836
+ },
1837
+ "get": {
1838
+ "tags": [
1839
+ "PolicySets"
1840
+ ],
1841
+ "summary": "listPolicySets",
1842
+ "description": "List Policy Sets",
1843
+ "operationId": "listPolicySets",
1844
+ "parameters": [
1845
+ {
1846
+ "name": "organization_name",
1847
+ "in": "path",
1848
+ "description": "The organization to list policy sets for.",
1849
+ "required": true,
1850
+ "style": "simple",
1851
+ "schema": {
1852
+ "type": "string"
1853
+ }
1854
+ },
1855
+ {
1856
+ "name": "filter[versioned]",
1857
+ "in": "query",
1858
+ "description": "Optional. Allows filtering policy sets based on whether they are versioned (VCS-managed or API-managed), or use individual policy relationships. Accepts a boolean true/false value. A true value returns versioned sets, and a false value returns sets with individual policy relationships. If omitted, all policy sets are returned.",
1859
+ "style": "form",
1860
+ "explode": true,
1861
+ "schema": {
1862
+ "type": "string"
1863
+ }
1864
+ },
1865
+ {
1866
+ "name": "include",
1867
+ "in": "query",
1868
+ "description": "Optional. Allows including related resource data. Value must be a comma-separated list containing one or more of workspaces, policies, newest_version, or current_version. See the relationships section for details.",
1869
+ "style": "form",
1870
+ "explode": true,
1871
+ "schema": {
1872
+ "type": "string"
1873
+ }
1874
+ },
1875
+ {
1876
+ "name": "page[number]",
1877
+ "in": "query",
1878
+ "description": "Optional. If omitted, the endpoint will return the first page.",
1879
+ "style": "form",
1880
+ "explode": true,
1881
+ "schema": {
1882
+ "type": "string"
1883
+ }
1884
+ },
1885
+ {
1886
+ "name": "page[size]",
1887
+ "in": "query",
1888
+ "description": "Optional. If omitted, the endpoint will return 20 policy sets per page.",
1889
+ "style": "form",
1890
+ "explode": true,
1891
+ "schema": {
1892
+ "type": "string"
1893
+ }
1894
+ },
1895
+ {
1896
+ "name": "search[name]",
1897
+ "in": "query",
1898
+ "description": "Optional. Allows searching the organization's policy sets by name.",
1899
+ "style": "form",
1900
+ "explode": true,
1901
+ "schema": {
1902
+ "type": "string"
1903
+ }
1904
+ }
1905
+ ],
1906
+ "responses": {
1907
+ "200": {
1908
+ "description": "successful operation",
1909
+ "headers": {},
1910
+ "content": {
1911
+ "text/plain": {
1912
+ "schema": {
1913
+ "type": "string",
1914
+ "description": "successful operation"
1915
+ }
1916
+ }
1917
+ }
1918
+ },
1919
+ "400": {
1920
+ "description": "failed operation"
1921
+ }
1922
+ },
1923
+ "deprecated": false
1924
+ }
1925
+ },
1926
+ "/policy-sets/{id}": {
1927
+ "get": {
1928
+ "tags": [
1929
+ "PolicySets"
1930
+ ],
1931
+ "summary": "showPolicySet",
1932
+ "description": "Show a Policy Set",
1933
+ "operationId": "showPolicySet",
1934
+ "parameters": [
1935
+ {
1936
+ "name": "id",
1937
+ "in": "path",
1938
+ "description": "The ID of the policy set to show. Use the \"List Policy Sets\" endpoint to find IDs.",
1939
+ "required": true,
1940
+ "style": "simple",
1941
+ "schema": {
1942
+ "type": "string"
1943
+ }
1944
+ }
1945
+ ],
1946
+ "responses": {
1947
+ "200": {
1948
+ "description": "successful operation",
1949
+ "headers": {},
1950
+ "content": {
1951
+ "text/plain": {
1952
+ "schema": {
1953
+ "type": "string",
1954
+ "description": "successful operation"
1955
+ }
1956
+ }
1957
+ }
1958
+ },
1959
+ "400": {
1960
+ "description": "failed operation"
1961
+ }
1962
+ },
1963
+ "deprecated": false
1964
+ },
1965
+ "patch": {
1966
+ "tags": [
1967
+ "PolicySets"
1968
+ ],
1969
+ "summary": "updatePolicySet",
1970
+ "description": "Update a Policy Set",
1971
+ "operationId": "updatePolicySet",
1972
+ "parameters": [
1973
+ {
1974
+ "name": "id",
1975
+ "in": "path",
1976
+ "description": "The ID of the policy set to update. Use the \"List Policy Sets\" endpoint to find IDs.",
1977
+ "required": true,
1978
+ "style": "simple",
1979
+ "schema": {
1980
+ "type": "string"
1981
+ }
1982
+ }
1983
+ ],
1984
+ "requestBody": {
1985
+ "description": "",
1986
+ "content": {
1987
+ "text/plain": {
1988
+ "schema": {
1989
+ "type": "string"
1990
+ }
1991
+ }
1992
+ },
1993
+ "required": false
1994
+ },
1995
+ "responses": {
1996
+ "200": {
1997
+ "description": "successful operation",
1998
+ "headers": {},
1999
+ "content": {
2000
+ "text/plain": {
2001
+ "schema": {
2002
+ "type": "string",
2003
+ "description": "successful operation"
2004
+ }
2005
+ }
2006
+ }
2007
+ },
2008
+ "400": {
2009
+ "description": "failed operation"
2010
+ }
2011
+ },
2012
+ "deprecated": false
2013
+ },
2014
+ "delete": {
2015
+ "tags": [
2016
+ "PolicySets"
2017
+ ],
2018
+ "summary": "deletePolicySet",
2019
+ "description": "Delete a Policy Set",
2020
+ "operationId": "deletePolicySet",
2021
+ "parameters": [
2022
+ {
2023
+ "name": "id",
2024
+ "in": "path",
2025
+ "description": "The ID of the policy set to delete. Use the \"List Policy Sets\" endpoint to find IDs.",
2026
+ "required": true,
2027
+ "style": "simple",
2028
+ "schema": {
2029
+ "type": "string"
2030
+ }
2031
+ }
2032
+ ],
2033
+ "responses": {
2034
+ "200": {
2035
+ "description": "successful operation",
2036
+ "headers": {},
2037
+ "content": {
2038
+ "text/plain": {
2039
+ "schema": {
2040
+ "type": "string",
2041
+ "description": "successful operation"
2042
+ }
2043
+ }
2044
+ }
2045
+ },
2046
+ "400": {
2047
+ "description": "failed operation"
2048
+ }
2049
+ },
2050
+ "deprecated": false
2051
+ }
2052
+ },
2053
+ "/policy-sets/{id}/relationships/policies": {
2054
+ "post": {
2055
+ "tags": [
2056
+ "PolicySets"
2057
+ ],
2058
+ "summary": "addPoliciesToPolicySet",
2059
+ "description": "Add Policies to the Policy Set",
2060
+ "operationId": "addPoliciesToPolicySet",
2061
+ "parameters": [
2062
+ {
2063
+ "name": "id",
2064
+ "in": "path",
2065
+ "description": "The ID of the policy set to add policies to. Use the \"List Policy Sets\" endpoint to find IDs.",
2066
+ "required": true,
2067
+ "style": "simple",
2068
+ "schema": {
2069
+ "type": "string"
2070
+ }
2071
+ }
2072
+ ],
2073
+ "requestBody": {
2074
+ "description": "",
2075
+ "content": {
2076
+ "text/plain": {
2077
+ "schema": {
2078
+ "type": "string"
2079
+ }
2080
+ }
2081
+ },
2082
+ "required": false
2083
+ },
2084
+ "responses": {
2085
+ "200": {
2086
+ "description": "successful operation",
2087
+ "headers": {},
2088
+ "content": {
2089
+ "text/plain": {
2090
+ "schema": {
2091
+ "type": "string",
2092
+ "description": "successful operation"
2093
+ }
2094
+ }
2095
+ }
2096
+ },
2097
+ "400": {
2098
+ "description": "failed operation"
2099
+ }
2100
+ },
2101
+ "deprecated": false
2102
+ },
2103
+ "delete": {
2104
+ "tags": [
2105
+ "PolicySets"
2106
+ ],
2107
+ "summary": "removePoliciesFromThePolicySet",
2108
+ "description": "Remove Policies from the Policy Set",
2109
+ "operationId": "removePoliciesFromThePolicySet",
2110
+ "parameters": [
2111
+ {
2112
+ "name": "id",
2113
+ "in": "path",
2114
+ "description": "The ID of the policy set to remove policies from. Use the \"List Policy Sets\" endpoint to find IDs.",
2115
+ "required": true,
2116
+ "style": "simple",
2117
+ "schema": {
2118
+ "type": "string"
2119
+ }
2120
+ }
2121
+ ],
2122
+ "responses": {
2123
+ "200": {
2124
+ "description": "successful operation",
2125
+ "headers": {},
2126
+ "content": {
2127
+ "text/plain": {
2128
+ "schema": {
2129
+ "type": "string",
2130
+ "description": "successful operation"
2131
+ }
2132
+ }
2133
+ }
2134
+ },
2135
+ "400": {
2136
+ "description": "failed operation"
2137
+ }
2138
+ },
2139
+ "deprecated": false
2140
+ }
2141
+ },
2142
+ "/policy-sets/{id}/relationships/workspaces": {
2143
+ "post": {
2144
+ "tags": [
2145
+ "PolicySets"
2146
+ ],
2147
+ "summary": "attachPolicySetToWorkspaces",
2148
+ "description": "Attach a Policy Set to workspaces",
2149
+ "operationId": "attachPolicySetToWorkspaces",
2150
+ "parameters": [
2151
+ {
2152
+ "name": "id",
2153
+ "in": "path",
2154
+ "description": "The ID of the policy set to attach to workspaces. Use the \"List Policy Sets\" endpoint to find IDs.",
2155
+ "required": true,
2156
+ "style": "simple",
2157
+ "schema": {
2158
+ "type": "string"
2159
+ }
2160
+ }
2161
+ ],
2162
+ "requestBody": {
2163
+ "description": "",
2164
+ "content": {
2165
+ "text/plain": {
2166
+ "schema": {
2167
+ "type": "string"
2168
+ }
2169
+ }
2170
+ },
2171
+ "required": false
2172
+ },
2173
+ "responses": {
2174
+ "200": {
2175
+ "description": "successful operation",
2176
+ "headers": {},
2177
+ "content": {
2178
+ "text/plain": {
2179
+ "schema": {
2180
+ "type": "string",
2181
+ "description": "successful operation"
2182
+ }
2183
+ }
2184
+ }
2185
+ },
2186
+ "400": {
2187
+ "description": "failed operation"
2188
+ }
2189
+ },
2190
+ "deprecated": false
2191
+ },
2192
+ "delete": {
2193
+ "tags": [
2194
+ "PolicySets"
2195
+ ],
2196
+ "summary": "detachthePolicySetFromWorkspaces",
2197
+ "description": "Detach the Policy Set from workspaces",
2198
+ "operationId": "detachthePolicySetFromWorkspaces",
2199
+ "parameters": [
2200
+ {
2201
+ "name": "id",
2202
+ "in": "path",
2203
+ "description": "The ID of the policy set to detach from workspaces. Use the \"List Policy Sets\" endpoint to find IDs.",
2204
+ "required": true,
2205
+ "style": "simple",
2206
+ "schema": {
2207
+ "type": "string"
2208
+ }
2209
+ }
2210
+ ],
2211
+ "responses": {
2212
+ "200": {
2213
+ "description": "successful operation",
2214
+ "headers": {},
2215
+ "content": {
2216
+ "text/plain": {
2217
+ "schema": {
2218
+ "type": "string",
2219
+ "description": "successful operation"
2220
+ }
2221
+ }
2222
+ }
2223
+ },
2224
+ "400": {
2225
+ "description": "failed operation"
2226
+ }
2227
+ },
2228
+ "deprecated": false
2229
+ }
2230
+ },
2231
+ "/policy-sets/{id}/versions": {
2232
+ "post": {
2233
+ "tags": [
2234
+ "PolicySets"
2235
+ ],
2236
+ "summary": "createPolicySetVersion",
2237
+ "description": "For versioned policy sets which have no VCS repository attached, versions of policy code may be uploaded directly to the API by creating a new policy set version and, in a subsequent request, uploading a tarball (tar.gz) of data to it.",
2238
+ "operationId": "createPolicySetVersion",
2239
+ "parameters": [
2240
+ {
2241
+ "name": "id",
2242
+ "in": "path",
2243
+ "description": "The ID of the policy set to create a new version for.",
2244
+ "required": true,
2245
+ "style": "simple",
2246
+ "schema": {
2247
+ "type": "string"
2248
+ }
2249
+ }
2250
+ ],
2251
+ "responses": {
2252
+ "200": {
2253
+ "description": "successful operation",
2254
+ "headers": {},
2255
+ "content": {
2256
+ "text/plain": {
2257
+ "schema": {
2258
+ "type": "string",
2259
+ "description": "successful operation"
2260
+ }
2261
+ }
2262
+ }
2263
+ },
2264
+ "400": {
2265
+ "description": "failed operation"
2266
+ }
2267
+ },
2268
+ "deprecated": false
2269
+ }
2270
+ },
2271
+ "/policy-set-versions/{id}": {
2272
+ "get": {
2273
+ "tags": [
2274
+ "PolicySets"
2275
+ ],
2276
+ "summary": "showPolicySetVersion",
2277
+ "description": "Show a Policy Set Version",
2278
+ "operationId": "showPolicySetVersion",
2279
+ "parameters": [
2280
+ {
2281
+ "name": "id",
2282
+ "in": "path",
2283
+ "description": "The ID of the policy set version to show.",
2284
+ "required": true,
2285
+ "style": "simple",
2286
+ "schema": {
2287
+ "type": "string"
2288
+ }
2289
+ }
2290
+ ],
2291
+ "responses": {
2292
+ "200": {
2293
+ "description": "successful operation",
2294
+ "headers": {},
2295
+ "content": {
2296
+ "text/plain": {
2297
+ "schema": {
2298
+ "type": "string",
2299
+ "description": "successful operation"
2300
+ }
2301
+ }
2302
+ }
2303
+ },
2304
+ "400": {
2305
+ "description": "failed operation"
2306
+ }
2307
+ },
2308
+ "deprecated": false
2309
+ }
2310
+ },
2311
+ "/policy-sets/{policy_set_id}/parameters": {
2312
+ "post": {
2313
+ "tags": [
2314
+ "PolicySetParameters"
2315
+ ],
2316
+ "summary": "createParameter",
2317
+ "description": "Create a Parameter",
2318
+ "operationId": "createParameter",
2319
+ "parameters": [
2320
+ {
2321
+ "name": "policy_set_id",
2322
+ "in": "path",
2323
+ "description": "The ID of the policy set to create the parameter in.",
2324
+ "required": true,
2325
+ "style": "simple",
2326
+ "schema": {
2327
+ "type": "string"
2328
+ }
2329
+ }
2330
+ ],
2331
+ "requestBody": {
2332
+ "description": "",
2333
+ "content": {
2334
+ "text/plain": {
2335
+ "schema": {
2336
+ "type": "string"
2337
+ }
2338
+ }
2339
+ },
2340
+ "required": false
2341
+ },
2342
+ "responses": {
2343
+ "200": {
2344
+ "description": "successful operation",
2345
+ "headers": {},
2346
+ "content": {
2347
+ "text/plain": {
2348
+ "schema": {
2349
+ "type": "string",
2350
+ "description": "successful operation"
2351
+ }
2352
+ }
2353
+ }
2354
+ },
2355
+ "400": {
2356
+ "description": "failed operation"
2357
+ }
2358
+ },
2359
+ "deprecated": false
2360
+ },
2361
+ "get": {
2362
+ "tags": [
2363
+ "PolicySetParameters"
2364
+ ],
2365
+ "summary": "listParameters",
2366
+ "description": "List Parameters",
2367
+ "operationId": "listParameters",
2368
+ "parameters": [
2369
+ {
2370
+ "name": "policy_set_id",
2371
+ "in": "path",
2372
+ "description": "The ID of the policy set to list parameters for.",
2373
+ "required": true,
2374
+ "style": "simple",
2375
+ "schema": {
2376
+ "type": "string"
2377
+ }
2378
+ }
2379
+ ],
2380
+ "responses": {
2381
+ "200": {
2382
+ "description": "successful operation",
2383
+ "headers": {},
2384
+ "content": {
2385
+ "text/plain": {
2386
+ "schema": {
2387
+ "type": "string",
2388
+ "description": "successful operation"
2389
+ }
2390
+ }
2391
+ }
2392
+ },
2393
+ "400": {
2394
+ "description": "failed operation"
2395
+ }
2396
+ },
2397
+ "deprecated": false
2398
+ }
2399
+ },
2400
+ "/policy-sets/{policy_set_id}/parameters/{parameter_id}": {
2401
+ "patch": {
2402
+ "tags": [
2403
+ "PolicySetParameters"
2404
+ ],
2405
+ "summary": "updateParameters",
2406
+ "description": "Update Parameters",
2407
+ "operationId": "updateParameters",
2408
+ "parameters": [
2409
+ {
2410
+ "name": "policy_set_id",
2411
+ "in": "path",
2412
+ "description": "The ID of the policy set that owns the parameter.",
2413
+ "required": true,
2414
+ "style": "simple",
2415
+ "schema": {
2416
+ "type": "string"
2417
+ }
2418
+ },
2419
+ {
2420
+ "name": "parameter_id",
2421
+ "in": "path",
2422
+ "description": "The ID of the parameter to be updated.",
2423
+ "required": true,
2424
+ "style": "simple",
2425
+ "schema": {
2426
+ "type": "string"
2427
+ }
2428
+ }
2429
+ ],
2430
+ "requestBody": {
2431
+ "description": "",
2432
+ "content": {
2433
+ "text/plain": {
2434
+ "schema": {
2435
+ "type": "string"
2436
+ }
2437
+ }
2438
+ },
2439
+ "required": false
2440
+ },
2441
+ "responses": {
2442
+ "200": {
2443
+ "description": "successful operation",
2444
+ "headers": {},
2445
+ "content": {
2446
+ "text/plain": {
2447
+ "schema": {
2448
+ "type": "string",
2449
+ "description": "successful operation"
2450
+ }
2451
+ }
2452
+ }
2453
+ },
2454
+ "400": {
2455
+ "description": "failed operation"
2456
+ }
2457
+ },
2458
+ "deprecated": false
2459
+ },
2460
+ "delete": {
2461
+ "tags": [
2462
+ "PolicySetParameters"
2463
+ ],
2464
+ "summary": "deleteParameters",
2465
+ "description": "Delete Parameters",
2466
+ "operationId": "deleteParameters",
2467
+ "parameters": [
2468
+ {
2469
+ "name": "policy_set_id",
2470
+ "in": "path",
2471
+ "description": "The ID of the policy set that owns the parameter.",
2472
+ "required": true,
2473
+ "style": "simple",
2474
+ "schema": {
2475
+ "type": "string"
2476
+ }
2477
+ },
2478
+ {
2479
+ "name": "parameter_id",
2480
+ "in": "path",
2481
+ "description": "The ID of the parameter to be deleted.",
2482
+ "required": true,
2483
+ "style": "simple",
2484
+ "schema": {
2485
+ "type": "string"
2486
+ }
2487
+ }
2488
+ ],
2489
+ "responses": {
2490
+ "200": {
2491
+ "description": "successful operation",
2492
+ "headers": {},
2493
+ "content": {
2494
+ "text/plain": {
2495
+ "schema": {
2496
+ "type": "string",
2497
+ "description": "successful operation"
2498
+ }
2499
+ }
2500
+ }
2501
+ },
2502
+ "400": {
2503
+ "description": "failed operation"
2504
+ }
2505
+ },
2506
+ "deprecated": false
2507
+ }
2508
+ },
2509
+ "/runs": {
2510
+ "post": {
2511
+ "tags": [
2512
+ "Runs"
2513
+ ],
2514
+ "summary": "createRun",
2515
+ "description": "A run performs a plan and apply, using a configuration version and the workspace’s current variables. You can specify a configuration version when creating a run; if you don’t provide one, the run defaults to the workspace’s most recently used version. (A configuration version is “used” when it is created or used for a run in this workspace.)",
2516
+ "operationId": "createRun",
2517
+ "parameters": [],
2518
+ "requestBody": {
2519
+ "description": "",
2520
+ "content": {
2521
+ "text/plain": {
2522
+ "schema": {
2523
+ "type": "string"
2524
+ }
2525
+ }
2526
+ },
2527
+ "required": false
2528
+ },
2529
+ "responses": {
2530
+ "200": {
2531
+ "description": "successful operation",
2532
+ "headers": {},
2533
+ "content": {
2534
+ "text/plain": {
2535
+ "schema": {
2536
+ "type": "string",
2537
+ "description": "successful operation"
2538
+ }
2539
+ }
2540
+ }
2541
+ },
2542
+ "400": {
2543
+ "description": "failed operation"
2544
+ }
2545
+ },
2546
+ "deprecated": false
2547
+ }
2548
+ },
2549
+ "/runs/{run_id}/actions/apply": {
2550
+ "post": {
2551
+ "tags": [
2552
+ "Runs"
2553
+ ],
2554
+ "summary": "applyRun",
2555
+ "description": "Applies a run that is paused waiting for confirmation after a plan. This includes runs in the \"needs confirmation\" and \"policy checked\" states. This action is only required for runs that can't be auto-applied. (Plans can be auto-applied if the auto-apply setting is enabled on the workspace and the plan was queued by a new VCS commit or by a user with write permissions.)",
2556
+ "operationId": "applyRun",
2557
+ "parameters": [
2558
+ {
2559
+ "name": "run_id",
2560
+ "in": "path",
2561
+ "description": "The run ID to apply",
2562
+ "required": true,
2563
+ "style": "simple",
2564
+ "schema": {
2565
+ "type": "string"
2566
+ }
2567
+ }
2568
+ ],
2569
+ "requestBody": {
2570
+ "description": "",
2571
+ "content": {
2572
+ "text/plain": {
2573
+ "schema": {
2574
+ "type": "string"
2575
+ }
2576
+ }
2577
+ },
2578
+ "required": false
2579
+ },
2580
+ "responses": {
2581
+ "200": {
2582
+ "description": "successful operation",
2583
+ "headers": {},
2584
+ "content": {
2585
+ "text/plain": {
2586
+ "schema": {
2587
+ "type": "string",
2588
+ "description": "successful operation"
2589
+ }
2590
+ }
2591
+ }
2592
+ },
2593
+ "400": {
2594
+ "description": "failed operation"
2595
+ }
2596
+ },
2597
+ "deprecated": false
2598
+ }
2599
+ },
2600
+ "/workspaces/{workspace_id}/runs": {
2601
+ "get": {
2602
+ "tags": [
2603
+ "Runs"
2604
+ ],
2605
+ "summary": "ListRuns",
2606
+ "description": "List Runs in a Workspace",
2607
+ "operationId": "ListRuns",
2608
+ "parameters": [
2609
+ {
2610
+ "name": "workspace_id",
2611
+ "in": "path",
2612
+ "description": "The workspace ID to list runs for.",
2613
+ "required": true,
2614
+ "style": "simple",
2615
+ "schema": {
2616
+ "type": "string"
2617
+ }
2618
+ },
2619
+ {
2620
+ "name": "page[number]",
2621
+ "in": "query",
2622
+ "description": "Page Number",
2623
+ "style": "form",
2624
+ "explode": true,
2625
+ "schema": {
2626
+ "type": "number",
2627
+ "format": "double"
2628
+ }
2629
+ },
2630
+ {
2631
+ "name": "page[size]",
2632
+ "in": "query",
2633
+ "description": "Page Size",
2634
+ "style": "form",
2635
+ "explode": true,
2636
+ "schema": {
2637
+ "type": "number",
2638
+ "format": "double"
2639
+ }
2640
+ }
2641
+ ],
2642
+ "responses": {
2643
+ "200": {
2644
+ "description": "successful operation",
2645
+ "headers": {},
2646
+ "content": {
2647
+ "text/plain": {
2648
+ "schema": {
2649
+ "type": "string",
2650
+ "description": "successful operation"
2651
+ }
2652
+ }
2653
+ }
2654
+ },
2655
+ "400": {
2656
+ "description": "failed operation"
2657
+ }
2658
+ },
2659
+ "deprecated": false
2660
+ }
2661
+ },
2662
+ "/runs/{run_id}": {
2663
+ "get": {
2664
+ "tags": [
2665
+ "Runs"
2666
+ ],
2667
+ "summary": "GetRunDetails",
2668
+ "description": "This endpoint is used for showing details of a specific run.",
2669
+ "operationId": "GetRunDetails",
2670
+ "parameters": [
2671
+ {
2672
+ "name": "run_id",
2673
+ "in": "path",
2674
+ "description": "The run ID to get.",
2675
+ "required": true,
2676
+ "style": "simple",
2677
+ "schema": {
2678
+ "type": "string"
2679
+ }
2680
+ }
2681
+ ],
2682
+ "responses": {
2683
+ "200": {
2684
+ "description": "successful operation",
2685
+ "headers": {},
2686
+ "content": {
2687
+ "text/plain": {
2688
+ "schema": {
2689
+ "type": "string",
2690
+ "description": "successful operation"
2691
+ }
2692
+ }
2693
+ }
2694
+ },
2695
+ "400": {
2696
+ "description": "failed operation"
2697
+ }
2698
+ },
2699
+ "deprecated": false
2700
+ }
2701
+ },
2702
+ "/runs/{run_id}/actions/discard": {
2703
+ "post": {
2704
+ "tags": [
2705
+ "Runs"
2706
+ ],
2707
+ "summary": "DiscardRun",
2708
+ "description": "The discard action can be used to skip any remaining work on runs that are paused waiting for confirmation or priority. This includes runs in the \"pending,\" \"needs confirmation,\" \"policy checked,\" and \"policy override\" states.",
2709
+ "operationId": "DiscardRun",
2710
+ "parameters": [
2711
+ {
2712
+ "name": "run_id",
2713
+ "in": "path",
2714
+ "description": "The run ID to discard",
2715
+ "required": true,
2716
+ "style": "simple",
2717
+ "schema": {
2718
+ "type": "string"
2719
+ }
2720
+ }
2721
+ ],
2722
+ "requestBody": {
2723
+ "description": "",
2724
+ "content": {
2725
+ "text/plain": {
2726
+ "schema": {
2727
+ "type": "string"
2728
+ }
2729
+ }
2730
+ },
2731
+ "required": false
2732
+ },
2733
+ "responses": {
2734
+ "200": {
2735
+ "description": "successful operation",
2736
+ "headers": {},
2737
+ "content": {
2738
+ "text/plain": {
2739
+ "schema": {
2740
+ "type": "string",
2741
+ "description": "successful operation"
2742
+ }
2743
+ }
2744
+ }
2745
+ },
2746
+ "400": {
2747
+ "description": "failed operation"
2748
+ }
2749
+ },
2750
+ "deprecated": false
2751
+ }
2752
+ },
2753
+ "/runs/{run_id}/actions/cancel": {
2754
+ "post": {
2755
+ "tags": [
2756
+ "Runs"
2757
+ ],
2758
+ "summary": "cancelRun",
2759
+ "description": "The cancel action can be used to interrupt a run that is currently planning or applying. Performing a cancel is roughly equivalent to hitting ctrl+c during a Terraform plan or apply on the CLI. The running Terraform process is sent an INT signal, which instructs Terraform to end its work and wrap up in the safest way possible.",
2760
+ "operationId": "cancelRun",
2761
+ "parameters": [
2762
+ {
2763
+ "name": "run_id",
2764
+ "in": "path",
2765
+ "description": "The run ID to cancel",
2766
+ "required": true,
2767
+ "style": "simple",
2768
+ "schema": {
2769
+ "type": "string"
2770
+ }
2771
+ }
2772
+ ],
2773
+ "requestBody": {
2774
+ "description": "",
2775
+ "content": {
2776
+ "text/plain": {
2777
+ "schema": {
2778
+ "type": "string"
2779
+ }
2780
+ }
2781
+ },
2782
+ "required": false
2783
+ },
2784
+ "responses": {
2785
+ "200": {
2786
+ "description": "successful operation",
2787
+ "headers": {},
2788
+ "content": {
2789
+ "text/plain": {
2790
+ "schema": {
2791
+ "type": "string",
2792
+ "description": "successful operation"
2793
+ }
2794
+ }
2795
+ }
2796
+ },
2797
+ "400": {
2798
+ "description": "failed operation"
2799
+ }
2800
+ },
2801
+ "deprecated": false
2802
+ }
2803
+ },
2804
+ "/runs/{run_id}/actions/force-cancel": {
2805
+ "post": {
2806
+ "tags": [
2807
+ "Runs"
2808
+ ],
2809
+ "summary": "forceCancel",
2810
+ "description": "The force-cancel action is like cancel, but ends the run immediately. Once invoked, the run is placed into a canceled state, and the running Terraform process is terminated. The workspace is immediately unlocked, allowing further runs to be queued. The force-cancel operation requires workspace admin privileges.",
2811
+ "operationId": "forceCancel",
2812
+ "parameters": [
2813
+ {
2814
+ "name": "run_id",
2815
+ "in": "path",
2816
+ "description": "The run ID to cancel",
2817
+ "required": true,
2818
+ "style": "simple",
2819
+ "schema": {
2820
+ "type": "string"
2821
+ }
2822
+ }
2823
+ ],
2824
+ "requestBody": {
2825
+ "description": "",
2826
+ "content": {
2827
+ "text/plain": {
2828
+ "schema": {
2829
+ "type": "string"
2830
+ }
2831
+ }
2832
+ },
2833
+ "required": false
2834
+ },
2835
+ "responses": {
2836
+ "200": {
2837
+ "description": "successful operation",
2838
+ "headers": {},
2839
+ "content": {
2840
+ "text/plain": {
2841
+ "schema": {
2842
+ "type": "string",
2843
+ "description": "successful operation"
2844
+ }
2845
+ }
2846
+ }
2847
+ },
2848
+ "400": {
2849
+ "description": "failed operation"
2850
+ }
2851
+ },
2852
+ "deprecated": false
2853
+ }
2854
+ },
2855
+ "/runs/{run_id}/actions/force-execute": {
2856
+ "get": {
2857
+ "tags": [
2858
+ "Runs"
2859
+ ],
2860
+ "summary": "forceExecute",
2861
+ "description": "The force-execute action cancels all prior runs that are not already complete, unlocking the run's workspace and allowing the run to be executed. (It initiates the same actions as the \"Run this plan now\" button at the top of the view of a pending run.)",
2862
+ "operationId": "forceExecute",
2863
+ "parameters": [
2864
+ {
2865
+ "name": "run_id",
2866
+ "in": "path",
2867
+ "description": "The run ID to execute",
2868
+ "required": true,
2869
+ "style": "simple",
2870
+ "schema": {
2871
+ "type": "string"
2872
+ }
2873
+ }
2874
+ ],
2875
+ "responses": {
2876
+ "200": {
2877
+ "description": "successful operation",
2878
+ "headers": {},
2879
+ "content": {
2880
+ "text/plain": {
2881
+ "schema": {
2882
+ "type": "string",
2883
+ "description": "successful operation"
2884
+ }
2885
+ }
2886
+ }
2887
+ },
2888
+ "400": {
2889
+ "description": "failed operation"
2890
+ }
2891
+ },
2892
+ "deprecated": false
2893
+ }
2894
+ },
2895
+ "/workspaces/{workspace_id}/state-versions": {
2896
+ "post": {
2897
+ "tags": [
2898
+ "StateVersions"
2899
+ ],
2900
+ "summary": "createStateVersion",
2901
+ "description": "Create a State Version",
2902
+ "operationId": "createStateVersion",
2903
+ "parameters": [
2904
+ {
2905
+ "name": "workspace_id",
2906
+ "in": "path",
2907
+ "description": "The workspace ID to create the new state version in. Obtain this from the workspace settings or the Show Workspace endpoint.",
2908
+ "required": true,
2909
+ "style": "simple",
2910
+ "schema": {
2911
+ "type": "string"
2912
+ }
2913
+ }
2914
+ ],
2915
+ "requestBody": {
2916
+ "description": "",
2917
+ "content": {
2918
+ "text/plain": {
2919
+ "schema": {
2920
+ "type": "string"
2921
+ }
2922
+ }
2923
+ },
2924
+ "required": false
2925
+ },
2926
+ "responses": {
2927
+ "200": {
2928
+ "description": "successful operation",
2929
+ "headers": {},
2930
+ "content": {
2931
+ "text/plain": {
2932
+ "schema": {
2933
+ "type": "string",
2934
+ "description": "successful operation"
2935
+ }
2936
+ }
2937
+ }
2938
+ },
2939
+ "400": {
2940
+ "description": "failed operation"
2941
+ }
2942
+ },
2943
+ "deprecated": false
2944
+ }
2945
+ },
2946
+ "/state-versions": {
2947
+ "get": {
2948
+ "tags": [
2949
+ "StateVersions"
2950
+ ],
2951
+ "summary": "listStateVersions",
2952
+ "description": "List State Versions for a Workspace",
2953
+ "operationId": "listStateVersions",
2954
+ "parameters": [
2955
+ {
2956
+ "name": "filter[workspace][name]",
2957
+ "in": "query",
2958
+ "description": "Required The name of one workspace to list versions for.",
2959
+ "style": "form",
2960
+ "explode": true,
2961
+ "schema": {
2962
+ "type": "string"
2963
+ }
2964
+ },
2965
+ {
2966
+ "name": "filter[organization][name]",
2967
+ "in": "query",
2968
+ "description": "Required The name of the organization that owns the desired workspace.",
2969
+ "style": "form",
2970
+ "explode": true,
2971
+ "schema": {
2972
+ "type": "string"
2973
+ }
2974
+ },
2975
+ {
2976
+ "name": "page[number]",
2977
+ "in": "query",
2978
+ "description": "Optional. If omitted, the endpoint will return the first page.",
2979
+ "style": "form",
2980
+ "explode": true,
2981
+ "schema": {
2982
+ "type": "string"
2983
+ }
2984
+ },
2985
+ {
2986
+ "name": "page[size]",
2987
+ "in": "query",
2988
+ "description": "Optional. If omitted, the endpoint will return 20 state versions per page.",
2989
+ "style": "form",
2990
+ "explode": true,
2991
+ "schema": {
2992
+ "type": "string"
2993
+ }
2994
+ }
2995
+ ],
2996
+ "responses": {
2997
+ "200": {
2998
+ "description": "successful operation",
2999
+ "headers": {},
3000
+ "content": {
3001
+ "text/plain": {
3002
+ "schema": {
3003
+ "type": "string",
3004
+ "description": "successful operation"
3005
+ }
3006
+ }
3007
+ }
3008
+ },
3009
+ "400": {
3010
+ "description": "failed operation"
3011
+ }
3012
+ },
3013
+ "deprecated": false
3014
+ }
3015
+ },
3016
+ "/workspaces/{workspace_id}/current-state-version": {
3017
+ "get": {
3018
+ "tags": [
3019
+ "StateVersions"
3020
+ ],
3021
+ "summary": "fetchCurrentStateVersionForWorkspace",
3022
+ "description": "Fetch the Current State Version for a Workspace",
3023
+ "operationId": "fetchCurrentStateVersionForWorkspace",
3024
+ "parameters": [
3025
+ {
3026
+ "name": "workspace_id",
3027
+ "in": "path",
3028
+ "description": "The ID for the workspace whose current state version you want to fetch. Obtain this from the workspace settings or the Show Workspace endpoint.",
3029
+ "required": true,
3030
+ "style": "simple",
3031
+ "schema": {
3032
+ "type": "string"
3033
+ }
3034
+ }
3035
+ ],
3036
+ "responses": {
3037
+ "200": {
3038
+ "description": "successful operation",
3039
+ "headers": {},
3040
+ "content": {
3041
+ "text/plain": {
3042
+ "schema": {
3043
+ "type": "string",
3044
+ "description": "successful operation"
3045
+ }
3046
+ }
3047
+ }
3048
+ },
3049
+ "400": {
3050
+ "description": "failed operation"
3051
+ }
3052
+ },
3053
+ "deprecated": false
3054
+ }
3055
+ },
3056
+ "/state-versions/{state_version_id}": {
3057
+ "get": {
3058
+ "tags": [
3059
+ "StateVersions"
3060
+ ],
3061
+ "summary": "showStateVersion",
3062
+ "description": "Show a State Version",
3063
+ "operationId": "showStateVersion",
3064
+ "parameters": [
3065
+ {
3066
+ "name": "state_version_id",
3067
+ "in": "path",
3068
+ "description": "The ID of the desired state version.",
3069
+ "required": true,
3070
+ "style": "simple",
3071
+ "schema": {
3072
+ "type": "string"
3073
+ }
3074
+ }
3075
+ ],
3076
+ "responses": {
3077
+ "200": {
3078
+ "description": "successful operation",
3079
+ "headers": {},
3080
+ "content": {
3081
+ "text/plain": {
3082
+ "schema": {
3083
+ "type": "string",
3084
+ "description": "successful operation"
3085
+ }
3086
+ }
3087
+ }
3088
+ },
3089
+ "400": {
3090
+ "description": "failed operation"
3091
+ }
3092
+ },
3093
+ "deprecated": false
3094
+ }
3095
+ },
3096
+ "/state-version-outputs/{state_version_output_id}": {
3097
+ "get": {
3098
+ "tags": [
3099
+ "StateVersionOutputs"
3100
+ ],
3101
+ "summary": "showStateVersionOutput",
3102
+ "description": "Show a State Version Output",
3103
+ "operationId": "showStateVersionOutput",
3104
+ "parameters": [
3105
+ {
3106
+ "name": "state_version_output_id",
3107
+ "in": "path",
3108
+ "description": "The ID of the desired state version output.",
3109
+ "required": true,
3110
+ "style": "simple",
3111
+ "schema": {
3112
+ "type": "string"
3113
+ }
3114
+ }
3115
+ ],
3116
+ "responses": {
3117
+ "200": {
3118
+ "description": "successful operation",
3119
+ "headers": {},
3120
+ "content": {
3121
+ "text/plain": {
3122
+ "schema": {
3123
+ "type": "string",
3124
+ "description": "successful operation"
3125
+ }
3126
+ }
3127
+ }
3128
+ },
3129
+ "400": {
3130
+ "description": "failed operation"
3131
+ }
3132
+ },
3133
+ "deprecated": false
3134
+ }
3135
+ },
3136
+ "/users/{user_id}": {
3137
+ "get": {
3138
+ "tags": [
3139
+ "Users"
3140
+ ],
3141
+ "summary": "showUser",
3142
+ "description": "Shows details for a given user.",
3143
+ "operationId": "showUser",
3144
+ "parameters": [
3145
+ {
3146
+ "name": "user",
3147
+ "in": "query",
3148
+ "description": "The ID of the desired user.",
3149
+ "required": true,
3150
+ "style": "form",
3151
+ "explode": true,
3152
+ "schema": {
3153
+ "type": "string"
3154
+ }
3155
+ },
3156
+ {
3157
+ "name": "user_id",
3158
+ "in": "path",
3159
+ "description": "",
3160
+ "required": true,
3161
+ "style": "simple",
3162
+ "schema": {
3163
+ "type": "string"
3164
+ }
3165
+ }
3166
+ ],
3167
+ "responses": {
3168
+ "200": {
3169
+ "description": "successful operation",
3170
+ "headers": {},
3171
+ "content": {
3172
+ "text/plain": {
3173
+ "schema": {
3174
+ "type": "string",
3175
+ "description": "successful operation"
3176
+ }
3177
+ }
3178
+ }
3179
+ },
3180
+ "400": {
3181
+ "description": "failed operation"
3182
+ }
3183
+ },
3184
+ "deprecated": false
3185
+ }
3186
+ },
3187
+ "/vars": {
3188
+ "post": {
3189
+ "tags": [
3190
+ "Variables"
3191
+ ],
3192
+ "summary": "createVariable",
3193
+ "description": "Create a Variable",
3194
+ "operationId": "createVariable",
3195
+ "parameters": [],
3196
+ "requestBody": {
3197
+ "description": "",
3198
+ "content": {
3199
+ "text/plain": {
3200
+ "schema": {
3201
+ "type": "string"
3202
+ }
3203
+ }
3204
+ },
3205
+ "required": false
3206
+ },
3207
+ "responses": {
3208
+ "200": {
3209
+ "description": "successful operation",
3210
+ "headers": {},
3211
+ "content": {
3212
+ "text/plain": {
3213
+ "schema": {
3214
+ "type": "string",
3215
+ "description": "successful operation"
3216
+ }
3217
+ }
3218
+ }
3219
+ },
3220
+ "400": {
3221
+ "description": "failed operation"
3222
+ }
3223
+ },
3224
+ "deprecated": false
3225
+ },
3226
+ "get": {
3227
+ "tags": [
3228
+ "Variables"
3229
+ ],
3230
+ "summary": "listVariables",
3231
+ "description": "List Variables",
3232
+ "operationId": "listVariables",
3233
+ "parameters": [
3234
+ {
3235
+ "name": "filter[workspace][name]",
3236
+ "in": "query",
3237
+ "description": "Optional The name of one workspace to list variables for. If included, you must also include the organization name filter.",
3238
+ "style": "form",
3239
+ "explode": true,
3240
+ "schema": {
3241
+ "type": "string"
3242
+ }
3243
+ },
3244
+ {
3245
+ "name": "filter[organization][name]",
3246
+ "in": "query",
3247
+ "description": "Optional The name of the organization that owns the desired workspace. If included, you must also included the workspace name filter.",
3248
+ "style": "form",
3249
+ "explode": true,
3250
+ "schema": {
3251
+ "type": "string"
3252
+ }
3253
+ }
3254
+ ],
3255
+ "responses": {
3256
+ "200": {
3257
+ "description": "successful operation",
3258
+ "headers": {},
3259
+ "content": {
3260
+ "text/plain": {
3261
+ "schema": {
3262
+ "type": "string",
3263
+ "description": "successful operation"
3264
+ }
3265
+ }
3266
+ }
3267
+ },
3268
+ "400": {
3269
+ "description": "failed operation"
3270
+ }
3271
+ },
3272
+ "deprecated": false
3273
+ }
3274
+ },
3275
+ "/vars/{variable_id}": {
3276
+ "patch": {
3277
+ "tags": [
3278
+ "Variables"
3279
+ ],
3280
+ "summary": "updateVariables",
3281
+ "description": "Update Variables",
3282
+ "operationId": "updateVariables",
3283
+ "parameters": [
3284
+ {
3285
+ "name": "variable_id",
3286
+ "in": "path",
3287
+ "description": "The ID of the variable to be updated.",
3288
+ "required": true,
3289
+ "style": "simple",
3290
+ "schema": {
3291
+ "type": "string"
3292
+ }
3293
+ }
3294
+ ],
3295
+ "requestBody": {
3296
+ "description": "",
3297
+ "content": {
3298
+ "text/plain": {
3299
+ "schema": {
3300
+ "type": "string"
3301
+ }
3302
+ }
3303
+ },
3304
+ "required": false
3305
+ },
3306
+ "responses": {
3307
+ "200": {
3308
+ "description": "successful operation",
3309
+ "headers": {},
3310
+ "content": {
3311
+ "text/plain": {
3312
+ "schema": {
3313
+ "type": "string",
3314
+ "description": "successful operation"
3315
+ }
3316
+ }
3317
+ }
3318
+ },
3319
+ "400": {
3320
+ "description": "failed operation"
3321
+ }
3322
+ },
3323
+ "deprecated": false
3324
+ },
3325
+ "delete": {
3326
+ "tags": [
3327
+ "Variables"
3328
+ ],
3329
+ "summary": "deleteVariables",
3330
+ "description": "Delete Variables",
3331
+ "operationId": "deleteVariables",
3332
+ "parameters": [
3333
+ {
3334
+ "name": "variable_id",
3335
+ "in": "path",
3336
+ "description": "The ID of the variable to be deleted.",
3337
+ "required": true,
3338
+ "style": "simple",
3339
+ "schema": {
3340
+ "type": "string"
3341
+ }
3342
+ }
3343
+ ],
3344
+ "responses": {
3345
+ "200": {
3346
+ "description": "successful operation",
3347
+ "headers": {},
3348
+ "content": {
3349
+ "text/plain": {
3350
+ "schema": {
3351
+ "type": "string",
3352
+ "description": "successful operation"
3353
+ }
3354
+ }
3355
+ }
3356
+ },
3357
+ "400": {
3358
+ "description": "failed operation"
3359
+ }
3360
+ },
3361
+ "deprecated": false
3362
+ }
3363
+ },
3364
+ "/organizations/{organization_name}/workspaces": {
3365
+ "post": {
3366
+ "tags": [
3367
+ "Workspaces"
3368
+ ],
3369
+ "summary": "createWorkspace",
3370
+ "description": "Create a Workspace",
3371
+ "operationId": "createWorkspace",
3372
+ "parameters": [
3373
+ {
3374
+ "name": "organization_name",
3375
+ "in": "path",
3376
+ "description": "The name of the organization to create the workspace in. The organization must already exist in the system, and the user must have permissions to create new workspaces.",
3377
+ "required": true,
3378
+ "style": "simple",
3379
+ "schema": {
3380
+ "type": "string"
3381
+ }
3382
+ }
3383
+ ],
3384
+ "requestBody": {
3385
+ "description": "",
3386
+ "content": {
3387
+ "text/plain": {
3388
+ "schema": {
3389
+ "type": "string"
3390
+ }
3391
+ }
3392
+ },
3393
+ "required": false
3394
+ },
3395
+ "responses": {
3396
+ "200": {
3397
+ "description": "successful operation",
3398
+ "headers": {},
3399
+ "content": {
3400
+ "text/plain": {
3401
+ "schema": {
3402
+ "type": "string",
3403
+ "description": "successful operation"
3404
+ }
3405
+ }
3406
+ }
3407
+ },
3408
+ "400": {
3409
+ "description": "failed operation"
3410
+ }
3411
+ },
3412
+ "deprecated": false
3413
+ },
3414
+ "get": {
3415
+ "tags": [
3416
+ "Workspaces"
3417
+ ],
3418
+ "summary": "listWorkspaces",
3419
+ "description": "List Workspaces",
3420
+ "operationId": "listWorkspaces",
3421
+ "parameters": [
3422
+ {
3423
+ "name": "organization_name",
3424
+ "in": "path",
3425
+ "description": "The name of the organization to list the workspaces of.",
3426
+ "required": true,
3427
+ "style": "simple",
3428
+ "schema": {
3429
+ "type": "string"
3430
+ }
3431
+ },
3432
+ {
3433
+ "name": "page[number]",
3434
+ "in": "query",
3435
+ "description": "Optional. If omitted, the endpoint will return the first page.",
3436
+ "style": "form",
3437
+ "explode": true,
3438
+ "schema": {
3439
+ "type": "string"
3440
+ }
3441
+ },
3442
+ {
3443
+ "name": "page[size]",
3444
+ "in": "query",
3445
+ "description": "Optional. If omitted, the endpoint will return 150 workspaces per page.",
3446
+ "style": "form",
3447
+ "explode": true,
3448
+ "schema": {
3449
+ "type": "string"
3450
+ }
3451
+ }
3452
+ ],
3453
+ "responses": {
3454
+ "200": {
3455
+ "description": "successful operation",
3456
+ "headers": {},
3457
+ "content": {
3458
+ "text/plain": {
3459
+ "schema": {
3460
+ "type": "string",
3461
+ "description": "successful operation"
3462
+ }
3463
+ }
3464
+ }
3465
+ },
3466
+ "400": {
3467
+ "description": "failed operation"
3468
+ }
3469
+ },
3470
+ "deprecated": false
3471
+ }
3472
+ },
3473
+ "/workspaces/{workspace_id}": {
3474
+ "get": {
3475
+ "tags": [
3476
+ "Workspaces"
3477
+ ],
3478
+ "summary": "showWorkspace",
3479
+ "description": "Details on a workspace can be retrieved from two endpoints, which behave identically. One refers to a workspace by its ID, and the other by its name and organization.",
3480
+ "operationId": "showWorkspace",
3481
+ "parameters": [
3482
+ {
3483
+ "name": "workspace_id",
3484
+ "in": "path",
3485
+ "description": "The workspace ID",
3486
+ "required": true,
3487
+ "style": "simple",
3488
+ "schema": {
3489
+ "type": "string"
3490
+ }
3491
+ }
3492
+ ],
3493
+ "responses": {
3494
+ "200": {
3495
+ "description": "successful operation",
3496
+ "headers": {},
3497
+ "content": {
3498
+ "text/plain": {
3499
+ "schema": {
3500
+ "type": "string",
3501
+ "description": "successful operation"
3502
+ }
3503
+ }
3504
+ }
3505
+ },
3506
+ "400": {
3507
+ "description": "failed operation"
3508
+ }
3509
+ },
3510
+ "deprecated": false
3511
+ }
3512
+ },
3513
+ "/workspaces/{workspace_id}/actions/lock": {
3514
+ "post": {
3515
+ "tags": [
3516
+ "Workspaces"
3517
+ ],
3518
+ "summary": "lockWorkspace",
3519
+ "description": "This endpoint locks a workspace.",
3520
+ "operationId": "lockWorkspace",
3521
+ "parameters": [
3522
+ {
3523
+ "name": "workspace_id",
3524
+ "in": "path",
3525
+ "description": "The workspace ID to lock. Obtain this from the workspace settings or the Show Workspace endpoint.",
3526
+ "required": true,
3527
+ "style": "simple",
3528
+ "schema": {
3529
+ "type": "object"
3530
+ }
3531
+ }
3532
+ ],
3533
+ "responses": {
3534
+ "200": {
3535
+ "description": "successful operation",
3536
+ "headers": {},
3537
+ "content": {
3538
+ "text/plain": {
3539
+ "schema": {
3540
+ "type": "string",
3541
+ "description": "successful operation"
3542
+ }
3543
+ }
3544
+ }
3545
+ },
3546
+ "400": {
3547
+ "description": "failed operation"
3548
+ }
3549
+ },
3550
+ "deprecated": false
3551
+ }
3552
+ },
3553
+ "/workspaces/{workspace_id}/actions/unlock": {
3554
+ "post": {
3555
+ "tags": [
3556
+ "Workspaces"
3557
+ ],
3558
+ "summary": "unlockWorkspace",
3559
+ "description": "This endpoint unlocks a workspace.",
3560
+ "operationId": "unlockWorkspace",
3561
+ "parameters": [
3562
+ {
3563
+ "name": "workspace_id",
3564
+ "in": "path",
3565
+ "description": "The workspace ID to unlock. Obtain this from the workspace settings or the Show Workspace endpoint.",
3566
+ "required": true,
3567
+ "style": "simple",
3568
+ "schema": {
3569
+ "type": "string"
3570
+ }
3571
+ }
3572
+ ],
3573
+ "responses": {
3574
+ "200": {
3575
+ "description": "successful operation",
3576
+ "headers": {},
3577
+ "content": {
3578
+ "text/plain": {
3579
+ "schema": {
3580
+ "type": "string",
3581
+ "description": "successful operation"
3582
+ }
3583
+ }
3584
+ }
3585
+ },
3586
+ "400": {
3587
+ "description": "failed operation"
3588
+ }
3589
+ },
3590
+ "deprecated": false
3591
+ }
3592
+ },
3593
+ "/workspaces/{workspace_id}/actions/force-unlock": {
3594
+ "post": {
3595
+ "tags": [
3596
+ "Workspaces"
3597
+ ],
3598
+ "summary": "forceUnlockWorkspace",
3599
+ "description": "This endpoint force unlocks a workspace. Only users with admin access are authorized to force unlock a workspace.",
3600
+ "operationId": "forceUnlockWorkspace",
3601
+ "parameters": [
3602
+ {
3603
+ "name": "workspace_id",
3604
+ "in": "path",
3605
+ "description": "The workspace ID to force unlock. Obtain this from the workspace settings or the Show Workspace endpoint.",
3606
+ "required": true,
3607
+ "style": "simple",
3608
+ "schema": {
3609
+ "type": "string"
3610
+ }
3611
+ }
3612
+ ],
3613
+ "responses": {
3614
+ "200": {
3615
+ "description": "successful operation",
3616
+ "headers": {},
3617
+ "content": {
3618
+ "text/plain": {
3619
+ "schema": {
3620
+ "type": "string",
3621
+ "description": "successful operation"
3622
+ }
3623
+ }
3624
+ }
3625
+ },
3626
+ "400": {
3627
+ "description": "failed operation"
3628
+ }
3629
+ },
3630
+ "deprecated": false
3631
+ }
3632
+ },
3633
+ "/workspaces/{workspace_id}/relationships/ssh-key": {
3634
+ "patch": {
3635
+ "tags": [
3636
+ "Workspaces"
3637
+ ],
3638
+ "summary": "assignSSHKeyToWorkspace",
3639
+ "description": "This endpoint assigns and unassigns an SSH key to/from a workspace.",
3640
+ "operationId": "assignSSHKeyToWorkspace",
3641
+ "parameters": [
3642
+ {
3643
+ "name": "workspace_id",
3644
+ "in": "path",
3645
+ "description": "The workspace ID to assign the SSH key to. Obtain this from the workspace settings or the Show Workspace endpoint.",
3646
+ "required": true,
3647
+ "style": "simple",
3648
+ "schema": {
3649
+ "type": "string"
3650
+ }
3651
+ }
3652
+ ],
3653
+ "requestBody": {
3654
+ "description": "",
3655
+ "content": {
3656
+ "text/plain": {
3657
+ "schema": {
3658
+ "type": "string"
3659
+ }
3660
+ }
3661
+ },
3662
+ "required": false
3663
+ },
3664
+ "responses": {
3665
+ "200": {
3666
+ "description": "successful operation",
3667
+ "headers": {},
3668
+ "content": {
3669
+ "text/plain": {
3670
+ "schema": {
3671
+ "type": "string",
3672
+ "description": "successful operation"
3673
+ }
3674
+ }
3675
+ }
3676
+ },
3677
+ "400": {
3678
+ "description": "failed operation"
3679
+ }
3680
+ },
3681
+ "deprecated": false
3682
+ }
3683
+ },
3684
+ "/workspaces/{workspace_id}/vars": {
3685
+ "post": {
3686
+ "tags": [
3687
+ "WorkspacesVariables"
3688
+ ],
3689
+ "summary": "createWorkspaceVariable",
3690
+ "description": "Create a Workspace Variable",
3691
+ "operationId": "createWorkspaceVariable",
3692
+ "parameters": [
3693
+ {
3694
+ "name": "workspace_id",
3695
+ "in": "path",
3696
+ "description": "The ID of the workspace to create the variable in.",
3697
+ "required": true,
3698
+ "style": "simple",
3699
+ "schema": {
3700
+ "type": "string"
3701
+ }
3702
+ }
3703
+ ],
3704
+ "requestBody": {
3705
+ "description": "",
3706
+ "content": {
3707
+ "text/plain": {
3708
+ "schema": {
3709
+ "type": "string"
3710
+ }
3711
+ }
3712
+ },
3713
+ "required": false
3714
+ },
3715
+ "responses": {
3716
+ "200": {
3717
+ "description": "successful operation",
3718
+ "headers": {},
3719
+ "content": {
3720
+ "text/plain": {
3721
+ "schema": {
3722
+ "type": "string",
3723
+ "description": "successful operation"
3724
+ }
3725
+ }
3726
+ }
3727
+ },
3728
+ "400": {
3729
+ "description": "failed operation"
3730
+ }
3731
+ },
3732
+ "deprecated": false
3733
+ },
3734
+ "get": {
3735
+ "tags": [
3736
+ "WorkspacesVariables"
3737
+ ],
3738
+ "summary": "listWorkspaceVariables",
3739
+ "description": "List workspace variables",
3740
+ "operationId": "listWorkspaceVariables",
3741
+ "parameters": [
3742
+ {
3743
+ "name": "workspace_id",
3744
+ "in": "path",
3745
+ "description": "The ID of the workspace to list variables for.",
3746
+ "required": true,
3747
+ "style": "simple",
3748
+ "schema": {
3749
+ "type": "string"
3750
+ }
3751
+ }
3752
+ ],
3753
+ "responses": {
3754
+ "200": {
3755
+ "description": "successful operation",
3756
+ "headers": {},
3757
+ "content": {
3758
+ "text/plain": {
3759
+ "schema": {
3760
+ "type": "string",
3761
+ "description": "successful operation"
3762
+ }
3763
+ }
3764
+ }
3765
+ },
3766
+ "400": {
3767
+ "description": "failed operation"
3768
+ }
3769
+ },
3770
+ "deprecated": false
3771
+ }
3772
+ },
3773
+ "/workspaces/{workspace_id}/vars/{variable_id}": {
3774
+ "patch": {
3775
+ "tags": [
3776
+ "WorkspacesVariables"
3777
+ ],
3778
+ "summary": "updateWorkspaceVariables",
3779
+ "description": "Update Workspace Variables",
3780
+ "operationId": "updateWorkspaceVariables",
3781
+ "parameters": [
3782
+ {
3783
+ "name": "workspace_id",
3784
+ "in": "path",
3785
+ "description": "The ID of the workspace that owns the variable.",
3786
+ "required": true,
3787
+ "style": "simple",
3788
+ "schema": {
3789
+ "type": "string"
3790
+ }
3791
+ },
3792
+ {
3793
+ "name": "variable_id",
3794
+ "in": "path",
3795
+ "description": "The ID of the variable to be updated.",
3796
+ "required": true,
3797
+ "style": "simple",
3798
+ "schema": {
3799
+ "type": "string"
3800
+ }
3801
+ }
3802
+ ],
3803
+ "requestBody": {
3804
+ "description": "",
3805
+ "content": {
3806
+ "text/plain": {
3807
+ "schema": {
3808
+ "type": "string"
3809
+ }
3810
+ }
3811
+ },
3812
+ "required": false
3813
+ },
3814
+ "responses": {
3815
+ "200": {
3816
+ "description": "successful operation",
3817
+ "headers": {},
3818
+ "content": {
3819
+ "text/plain": {
3820
+ "schema": {
3821
+ "type": "string",
3822
+ "description": "successful operation"
3823
+ }
3824
+ }
3825
+ }
3826
+ },
3827
+ "400": {
3828
+ "description": "failed operation"
3829
+ }
3830
+ },
3831
+ "deprecated": false
3832
+ },
3833
+ "delete": {
3834
+ "tags": [
3835
+ "WorkspacesVariables"
3836
+ ],
3837
+ "summary": "deleteWorkspaceVariables",
3838
+ "description": "Delete Workspace Variables",
3839
+ "operationId": "deleteWorkspaceVariables",
3840
+ "parameters": [
3841
+ {
3842
+ "name": "workspace_id",
3843
+ "in": "path",
3844
+ "description": "The ID of the workspace that owns the variable.",
3845
+ "required": true,
3846
+ "style": "simple",
3847
+ "schema": {
3848
+ "type": "string"
3849
+ }
3850
+ },
3851
+ {
3852
+ "name": "variable_id",
3853
+ "in": "path",
3854
+ "description": "The ID of the variable to be deleted.",
3855
+ "required": true,
3856
+ "style": "simple",
3857
+ "schema": {
3858
+ "type": "string"
3859
+ }
3860
+ }
3861
+ ],
3862
+ "responses": {
3863
+ "200": {
3864
+ "description": "successful operation",
3865
+ "headers": {},
3866
+ "content": {
3867
+ "text/plain": {
3868
+ "schema": {
3869
+ "type": "string",
3870
+ "description": "successful operation"
3871
+ }
3872
+ }
3873
+ }
3874
+ },
3875
+ "400": {
3876
+ "description": "failed operation"
3877
+ }
3878
+ },
3879
+ "deprecated": false
3880
+ }
3881
+ }
3882
+ },
3883
+ "tags": [
3884
+ {
3885
+ "name": "default",
3886
+ "description": "",
3887
+ "externalDocs": {
3888
+ "url": "http://swagger.io"
3889
+ }
3890
+ },
3891
+ {
3892
+ "name": "Account",
3893
+ "description": "Account represents the current user interacting with Terraform. It returns the same type of object as the Users API, but also includes an email address, which is hidden when viewing info about other users."
3894
+ },
3895
+ {
3896
+ "name": "Applies",
3897
+ "description": "An apply represents the results of applying a Terraform Run's execution plan."
3898
+ },
3899
+ {
3900
+ "name": "CostEstimates",
3901
+ "description": "Cost estimate Information"
3902
+ },
3903
+ {
3904
+ "name": "NotificationConfigurations",
3905
+ "description": "Terraform Cloud can be configured to send notifications for run state transitions. The configuration allows you to specify a destination URL, request type, and what events will trigger the notification. Each workspace can have up to 20 notification configurations, and they apply to all runs for that workspace."
3906
+ },
3907
+ {
3908
+ "name": "OAuthClients",
3909
+ "description": "An OAuth Client represents the connection between an organization and a VCS provider."
3910
+ },
3911
+ {
3912
+ "name": "OAuthTokens",
3913
+ "description": "The oauth-token object represents a VCS configuration which includes the OAuth connection and the associated OAuth token. This object is used when creating a workspace to identify which VCS connection to use."
3914
+ },
3915
+ {
3916
+ "name": "Organizations",
3917
+ "description": "The Organizations API is used to list, show, create, update, and destroy organizations."
3918
+ },
3919
+ {
3920
+ "name": "OrganizationMemberships",
3921
+ "description": "Users are added to organizations by inviting them to join. Once accepted, they become members of the organization. The Organization Membership resource represents this membership.\nYou can invite users who already have an account, as well as new users. If the user has an existing account with the same email address used to invite them, they can reuse the same login."
3922
+ },
3923
+ {
3924
+ "name": "OrganizationToken",
3925
+ "description": "Organization Token API"
3926
+ },
3927
+ {
3928
+ "name": "PlanExports",
3929
+ "description": "Plan exports allow users to download data exported from the plan of a Run in a Terraform workspace. Currently, the only supported format for exporting plan data is to generate mock data for Sentinel."
3930
+ },
3931
+ {
3932
+ "name": "Plans",
3933
+ "description": "Plan exports allow users to download data exported from the plan of a Run in a Terraform workspace."
3934
+ },
3935
+ {
3936
+ "name": "Policies",
3937
+ "description": "Policies are configured on a per-organization level and are organized and grouped into policy sets, which define the workspaces on which policies are enforced during runs. In these workspaces, the plan's changes are validated against the relevant policies after the plan step."
3938
+ },
3939
+ {
3940
+ "name": "PolicyChecks",
3941
+ "description": "Policy Checks."
3942
+ },
3943
+ {
3944
+ "name": "PolicySets",
3945
+ "description": "Policy Sets."
3946
+ },
3947
+ {
3948
+ "name": "PolicySetParameters",
3949
+ "description": "Policy Set Parameters."
3950
+ },
3951
+ {
3952
+ "name": "Runs",
3953
+ "description": "Performing a run on a new configuration is a multi-step process. Create a configuration version on the workspace. Upload configuration files to the configuration version. Create a run on the workspace; this is done automatically when a configuration file is uploaded. Create and queue an apply on the run; if the run can't be auto-applied. Alternatively, you can create a run with a pre-existing configuration version, even one from another workspace. This is useful for promoting known good code from one workspace to another."
3954
+ },
3955
+ {
3956
+ "name": "StateVersions",
3957
+ "description": "State Versions."
3958
+ },
3959
+ {
3960
+ "name": "StateVersionOutputs",
3961
+ "description": "State Version Outputs."
3962
+ },
3963
+ {
3964
+ "name": "Users",
3965
+ "description": "Terraform Cloud's user objects do not contain any identifying information about a user, other than their Terraform Cloud username and avatar image; they are intended for displaying names and avatars in contexts that refer to a user by ID, like lists of team members or the details of a run. Most of these contexts can already include user objects via an ?include parameter, so you shouldn't usually need to make a separate call to this endpoint."
3966
+ },
3967
+ {
3968
+ "name": "Variables",
3969
+ "description": "This set of APIs covers create, update, list and delete operations on variables."
3970
+ },
3971
+ {
3972
+ "name": "Workspaces",
3973
+ "description": "Workspaces represent running infrastructure managed by Terraform."
3974
+ },
3975
+ {
3976
+ "name": "WorkspacesVariables",
3977
+ "description": "This set of APIs covers create, update, list and delete operations on workspace variables"
3978
+ }
3979
+ ],
3980
+ "externalDocs": {
3981
+ "description": "Find out more about Swagger",
3982
+ "url": "http://swagger.io"
3983
+ }
3984
+ }