@netlify/open-api 2.52.0 → 2.53.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +854 -12
- package/dist/swagger.json +1556 -166
- package/package.json +1 -1
package/dist/swagger.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"swagger": "2.0",
|
|
3
3
|
"info": {
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.53.0",
|
|
5
5
|
"title": "Netlify's API documentation",
|
|
6
6
|
"description": "Netlify is a hosting service for the programmable web. It understands your documents and provides an API to handle atomic deploys of websites, manage form submissions, inject JavaScript snippets, and much more. This is a REST-style API that uses JSON for serialization and OAuth 2 for authentication.\n\nThis document is an OpenAPI reference for the Netlify API that you can explore. For more detailed instructions for common uses, please visit the [online documentation](https://www.netlify.com/docs/api/). Visit our Community forum to join the conversation about [understanding and using Netlify's API](https://community.netlify.com/t/common-issue-understanding-and-using-netlifys-api/160).\n\nAdditionally, we have two API clients for your convenience:\n- [Go Client](https://github.com/netlify/open-api#go-client)\n- [JS Client](https://github.com/netlify/build/tree/main/packages/js-client)",
|
|
7
7
|
"termsOfService": "https://www.netlify.com/legal/terms-of-use/",
|
|
@@ -17310,7 +17310,6 @@
|
|
|
17310
17310
|
}
|
|
17311
17311
|
],
|
|
17312
17312
|
"post": {
|
|
17313
|
-
"x-internal": true,
|
|
17314
17313
|
"operationId": "createSiteDatabase",
|
|
17315
17314
|
"tags": [
|
|
17316
17315
|
"database"
|
|
@@ -17384,12 +17383,23 @@
|
|
|
17384
17383
|
}
|
|
17385
17384
|
},
|
|
17386
17385
|
"get": {
|
|
17387
|
-
"x-internal": true,
|
|
17388
17386
|
"operationId": "getSiteDatabase",
|
|
17389
17387
|
"tags": [
|
|
17390
17388
|
"database"
|
|
17391
17389
|
],
|
|
17392
17390
|
"description": "Returns the database connection string for the specified site.",
|
|
17391
|
+
"parameters": [
|
|
17392
|
+
{
|
|
17393
|
+
"name": "role",
|
|
17394
|
+
"type": "string",
|
|
17395
|
+
"in": "query",
|
|
17396
|
+
"description": "The database role to use for the connection string. Defaults to netlifydb_owner if not specified.",
|
|
17397
|
+
"enum": [
|
|
17398
|
+
"netlifydb_owner",
|
|
17399
|
+
"netlifydb_readonly"
|
|
17400
|
+
]
|
|
17401
|
+
}
|
|
17402
|
+
],
|
|
17393
17403
|
"responses": {
|
|
17394
17404
|
"200": {
|
|
17395
17405
|
"description": "OK",
|
|
@@ -17426,7 +17436,6 @@
|
|
|
17426
17436
|
}
|
|
17427
17437
|
},
|
|
17428
17438
|
"delete": {
|
|
17429
|
-
"x-internal": true,
|
|
17430
17439
|
"operationId": "deleteSiteDatabase",
|
|
17431
17440
|
"tags": [
|
|
17432
17441
|
"database"
|
|
@@ -17468,12 +17477,11 @@
|
|
|
17468
17477
|
}
|
|
17469
17478
|
],
|
|
17470
17479
|
"post": {
|
|
17471
|
-
"x-internal": true,
|
|
17472
17480
|
"operationId": "createSiteDatabaseBranch",
|
|
17473
17481
|
"tags": [
|
|
17474
17482
|
"database"
|
|
17475
17483
|
],
|
|
17476
|
-
"description": "Creates a new database branch
|
|
17484
|
+
"description": "Creates a new database branch. If a branch already exists for the specified branch ID, returns the existing connection string.",
|
|
17477
17485
|
"consumes": [
|
|
17478
17486
|
"application/json"
|
|
17479
17487
|
],
|
|
@@ -17485,16 +17493,21 @@
|
|
|
17485
17493
|
"type": "object",
|
|
17486
17494
|
"description": "Request body for creating a database branch",
|
|
17487
17495
|
"required": [
|
|
17488
|
-
"
|
|
17496
|
+
"branch_id"
|
|
17489
17497
|
],
|
|
17490
17498
|
"properties": {
|
|
17491
17499
|
"parent_branch_id": {
|
|
17492
17500
|
"type": "string",
|
|
17493
17501
|
"description": "The ID of the parent branch to create the new branch from. Defaults to the production branch if not specified."
|
|
17494
17502
|
},
|
|
17495
|
-
"
|
|
17503
|
+
"branch_id": {
|
|
17496
17504
|
"type": "string",
|
|
17497
|
-
"description": "The
|
|
17505
|
+
"description": "The branch identifier"
|
|
17506
|
+
},
|
|
17507
|
+
"metadata": {
|
|
17508
|
+
"type": "object",
|
|
17509
|
+
"description": "Arbitrary metadata to associate with the branch",
|
|
17510
|
+
"additionalProperties": true
|
|
17498
17511
|
}
|
|
17499
17512
|
}
|
|
17500
17513
|
},
|
|
@@ -17503,7 +17516,7 @@
|
|
|
17503
17516
|
],
|
|
17504
17517
|
"responses": {
|
|
17505
17518
|
"200": {
|
|
17506
|
-
"description": "Branch already exists
|
|
17519
|
+
"description": "Branch already exists",
|
|
17507
17520
|
"schema": {
|
|
17508
17521
|
"type": "object",
|
|
17509
17522
|
"description": "Response containing the database branch connection string",
|
|
@@ -17511,6 +17524,11 @@
|
|
|
17511
17524
|
"connection_string": {
|
|
17512
17525
|
"type": "string",
|
|
17513
17526
|
"description": "The connection string for the database branch"
|
|
17527
|
+
},
|
|
17528
|
+
"metadata": {
|
|
17529
|
+
"type": "object",
|
|
17530
|
+
"description": "Metadata associated with the branch",
|
|
17531
|
+
"additionalProperties": true
|
|
17514
17532
|
}
|
|
17515
17533
|
}
|
|
17516
17534
|
}
|
|
@@ -17524,6 +17542,150 @@
|
|
|
17524
17542
|
"connection_string": {
|
|
17525
17543
|
"type": "string",
|
|
17526
17544
|
"description": "The connection string for the database branch"
|
|
17545
|
+
},
|
|
17546
|
+
"metadata": {
|
|
17547
|
+
"type": "object",
|
|
17548
|
+
"description": "Metadata associated with the branch",
|
|
17549
|
+
"additionalProperties": true
|
|
17550
|
+
}
|
|
17551
|
+
}
|
|
17552
|
+
}
|
|
17553
|
+
},
|
|
17554
|
+
"default": {
|
|
17555
|
+
"description": "error",
|
|
17556
|
+
"schema": {
|
|
17557
|
+
"type": "object",
|
|
17558
|
+
"required": [
|
|
17559
|
+
"message"
|
|
17560
|
+
],
|
|
17561
|
+
"properties": {
|
|
17562
|
+
"code": {
|
|
17563
|
+
"type": "integer",
|
|
17564
|
+
"format": "int64"
|
|
17565
|
+
},
|
|
17566
|
+
"message": {
|
|
17567
|
+
"type": "string",
|
|
17568
|
+
"x-nullable": false
|
|
17569
|
+
}
|
|
17570
|
+
}
|
|
17571
|
+
}
|
|
17572
|
+
}
|
|
17573
|
+
}
|
|
17574
|
+
}
|
|
17575
|
+
},
|
|
17576
|
+
"/sites/{site_id}/database/branches": {
|
|
17577
|
+
"parameters": [
|
|
17578
|
+
{
|
|
17579
|
+
"name": "site_id",
|
|
17580
|
+
"type": "string",
|
|
17581
|
+
"in": "path",
|
|
17582
|
+
"required": true
|
|
17583
|
+
}
|
|
17584
|
+
],
|
|
17585
|
+
"get": {
|
|
17586
|
+
"operationId": "listSiteDatabaseBranches",
|
|
17587
|
+
"tags": [
|
|
17588
|
+
"database"
|
|
17589
|
+
],
|
|
17590
|
+
"description": "Returns all branches for the site's database with compute status and metadata.",
|
|
17591
|
+
"responses": {
|
|
17592
|
+
"200": {
|
|
17593
|
+
"description": "OK",
|
|
17594
|
+
"schema": {
|
|
17595
|
+
"type": "object",
|
|
17596
|
+
"description": "Response containing a list of database branches",
|
|
17597
|
+
"properties": {
|
|
17598
|
+
"branches": {
|
|
17599
|
+
"type": "array",
|
|
17600
|
+
"items": {
|
|
17601
|
+
"type": "object",
|
|
17602
|
+
"description": "Detailed information about a database branch",
|
|
17603
|
+
"properties": {
|
|
17604
|
+
"branch_id": {
|
|
17605
|
+
"type": "string",
|
|
17606
|
+
"description": "The branch identifier"
|
|
17607
|
+
},
|
|
17608
|
+
"name": {
|
|
17609
|
+
"type": "string",
|
|
17610
|
+
"description": "The branch name"
|
|
17611
|
+
},
|
|
17612
|
+
"connection_string": {
|
|
17613
|
+
"type": "string",
|
|
17614
|
+
"description": "The connection string for the branch"
|
|
17615
|
+
},
|
|
17616
|
+
"state": {
|
|
17617
|
+
"type": "string",
|
|
17618
|
+
"description": "The current state of the branch",
|
|
17619
|
+
"enum": [
|
|
17620
|
+
"init",
|
|
17621
|
+
"creating",
|
|
17622
|
+
"resetting",
|
|
17623
|
+
"ready",
|
|
17624
|
+
"archived"
|
|
17625
|
+
]
|
|
17626
|
+
},
|
|
17627
|
+
"logical_size_bytes": {
|
|
17628
|
+
"type": "integer",
|
|
17629
|
+
"format": "int64",
|
|
17630
|
+
"description": "The logical size of the branch in bytes"
|
|
17631
|
+
},
|
|
17632
|
+
"created_at": {
|
|
17633
|
+
"type": "string",
|
|
17634
|
+
"format": "dateTime",
|
|
17635
|
+
"description": "When the branch was created"
|
|
17636
|
+
},
|
|
17637
|
+
"updated_at": {
|
|
17638
|
+
"type": "string",
|
|
17639
|
+
"format": "dateTime",
|
|
17640
|
+
"description": "When the branch was last updated"
|
|
17641
|
+
},
|
|
17642
|
+
"last_active_at": {
|
|
17643
|
+
"type": "string",
|
|
17644
|
+
"format": "dateTime",
|
|
17645
|
+
"description": "When the branch was last active"
|
|
17646
|
+
},
|
|
17647
|
+
"compute": {
|
|
17648
|
+
"type": "object",
|
|
17649
|
+
"description": "Compute endpoint status for a branch",
|
|
17650
|
+
"properties": {
|
|
17651
|
+
"current_state": {
|
|
17652
|
+
"type": "string",
|
|
17653
|
+
"description": "The current state of the compute endpoint",
|
|
17654
|
+
"enum": [
|
|
17655
|
+
"active",
|
|
17656
|
+
"idle"
|
|
17657
|
+
]
|
|
17658
|
+
},
|
|
17659
|
+
"autoscaling_limit_min_cu": {
|
|
17660
|
+
"type": "number",
|
|
17661
|
+
"format": "double",
|
|
17662
|
+
"description": "Minimum compute units for autoscaling"
|
|
17663
|
+
},
|
|
17664
|
+
"autoscaling_limit_max_cu": {
|
|
17665
|
+
"type": "number",
|
|
17666
|
+
"format": "double",
|
|
17667
|
+
"description": "Maximum compute units for autoscaling"
|
|
17668
|
+
},
|
|
17669
|
+
"suspend_timeout_seconds": {
|
|
17670
|
+
"type": "integer",
|
|
17671
|
+
"format": "int64",
|
|
17672
|
+
"description": "Seconds of inactivity before the compute endpoint is suspended"
|
|
17673
|
+
},
|
|
17674
|
+
"last_active": {
|
|
17675
|
+
"type": "string",
|
|
17676
|
+
"format": "dateTime",
|
|
17677
|
+
"description": "When the compute endpoint was last active"
|
|
17678
|
+
}
|
|
17679
|
+
}
|
|
17680
|
+
},
|
|
17681
|
+
"metadata": {
|
|
17682
|
+
"type": "object",
|
|
17683
|
+
"description": "Metadata associated with the branch",
|
|
17684
|
+
"additionalProperties": true
|
|
17685
|
+
}
|
|
17686
|
+
}
|
|
17687
|
+
},
|
|
17688
|
+
"description": "List of database branches"
|
|
17527
17689
|
}
|
|
17528
17690
|
}
|
|
17529
17691
|
}
|
|
@@ -17550,7 +17712,7 @@
|
|
|
17550
17712
|
}
|
|
17551
17713
|
}
|
|
17552
17714
|
},
|
|
17553
|
-
"/sites/{site_id}/database/branch/{
|
|
17715
|
+
"/sites/{site_id}/database/branch/{branch_id}": {
|
|
17554
17716
|
"parameters": [
|
|
17555
17717
|
{
|
|
17556
17718
|
"name": "site_id",
|
|
@@ -17559,20 +17721,31 @@
|
|
|
17559
17721
|
"required": true
|
|
17560
17722
|
},
|
|
17561
17723
|
{
|
|
17562
|
-
"name": "
|
|
17724
|
+
"name": "branch_id",
|
|
17563
17725
|
"type": "string",
|
|
17564
17726
|
"in": "path",
|
|
17565
17727
|
"required": true,
|
|
17566
|
-
"description": "The
|
|
17728
|
+
"description": "The branch ID"
|
|
17567
17729
|
}
|
|
17568
17730
|
],
|
|
17569
17731
|
"get": {
|
|
17570
|
-
"x-internal": true,
|
|
17571
17732
|
"operationId": "getSiteDatabaseBranch",
|
|
17572
17733
|
"tags": [
|
|
17573
17734
|
"database"
|
|
17574
17735
|
],
|
|
17575
|
-
"description": "Returns the database branch connection string for a specific
|
|
17736
|
+
"description": "Returns the database branch connection string for a specific branch.",
|
|
17737
|
+
"parameters": [
|
|
17738
|
+
{
|
|
17739
|
+
"name": "role",
|
|
17740
|
+
"type": "string",
|
|
17741
|
+
"in": "query",
|
|
17742
|
+
"description": "The database role to use for the connection string. Defaults to netlifydb_owner if not specified.",
|
|
17743
|
+
"enum": [
|
|
17744
|
+
"netlifydb_owner",
|
|
17745
|
+
"netlifydb_readonly"
|
|
17746
|
+
]
|
|
17747
|
+
}
|
|
17748
|
+
],
|
|
17576
17749
|
"responses": {
|
|
17577
17750
|
"200": {
|
|
17578
17751
|
"description": "OK",
|
|
@@ -17583,12 +17756,17 @@
|
|
|
17583
17756
|
"connection_string": {
|
|
17584
17757
|
"type": "string",
|
|
17585
17758
|
"description": "The connection string for the database branch"
|
|
17759
|
+
},
|
|
17760
|
+
"metadata": {
|
|
17761
|
+
"type": "object",
|
|
17762
|
+
"description": "Metadata associated with the branch",
|
|
17763
|
+
"additionalProperties": true
|
|
17586
17764
|
}
|
|
17587
17765
|
}
|
|
17588
17766
|
}
|
|
17589
17767
|
},
|
|
17590
17768
|
"404": {
|
|
17591
|
-
"description": "Branch not found
|
|
17769
|
+
"description": "Branch not found"
|
|
17592
17770
|
},
|
|
17593
17771
|
"default": {
|
|
17594
17772
|
"description": "error",
|
|
@@ -17612,12 +17790,11 @@
|
|
|
17612
17790
|
}
|
|
17613
17791
|
},
|
|
17614
17792
|
"delete": {
|
|
17615
|
-
"x-internal": true,
|
|
17616
17793
|
"operationId": "deleteSiteDatabaseBranch",
|
|
17617
17794
|
"tags": [
|
|
17618
17795
|
"database"
|
|
17619
17796
|
],
|
|
17620
|
-
"description": "Deletes a database branch
|
|
17797
|
+
"description": "Deletes a database branch.",
|
|
17621
17798
|
"responses": {
|
|
17622
17799
|
"204": {
|
|
17623
17800
|
"description": "Deleted"
|
|
@@ -17644,68 +17821,92 @@
|
|
|
17644
17821
|
}
|
|
17645
17822
|
}
|
|
17646
17823
|
},
|
|
17647
|
-
"/sites/{site_id}/database/
|
|
17824
|
+
"/sites/{site_id}/database/branch/{branch_id}/reset": {
|
|
17648
17825
|
"parameters": [
|
|
17649
17826
|
{
|
|
17650
17827
|
"name": "site_id",
|
|
17651
17828
|
"type": "string",
|
|
17652
17829
|
"in": "path",
|
|
17653
17830
|
"required": true
|
|
17831
|
+
},
|
|
17832
|
+
{
|
|
17833
|
+
"name": "branch_id",
|
|
17834
|
+
"type": "string",
|
|
17835
|
+
"in": "path",
|
|
17836
|
+
"required": true,
|
|
17837
|
+
"description": "The branch ID to reset"
|
|
17654
17838
|
}
|
|
17655
17839
|
],
|
|
17656
17840
|
"post": {
|
|
17657
|
-
"
|
|
17658
|
-
"operationId": "createSiteDatabaseSnapshot",
|
|
17841
|
+
"operationId": "resetSiteDatabaseBranch",
|
|
17659
17842
|
"tags": [
|
|
17660
17843
|
"database"
|
|
17661
17844
|
],
|
|
17662
|
-
"description": "
|
|
17845
|
+
"description": "Resets a non-production database branch by re-forking it from a source branch (defaults to the production branch). If the target branch is already in sync with the source, returns the existing connection string without performing a reset, unless `force=true` is passed. The production branch cannot be reset.",
|
|
17663
17846
|
"consumes": [
|
|
17664
17847
|
"application/json"
|
|
17665
17848
|
],
|
|
17666
17849
|
"parameters": [
|
|
17667
17850
|
{
|
|
17668
|
-
"name": "
|
|
17851
|
+
"name": "force",
|
|
17852
|
+
"type": "boolean",
|
|
17853
|
+
"in": "query",
|
|
17854
|
+
"description": "If true, resets the branch even when it is already in sync with the source."
|
|
17855
|
+
},
|
|
17856
|
+
{
|
|
17857
|
+
"name": "role",
|
|
17858
|
+
"type": "string",
|
|
17859
|
+
"in": "query",
|
|
17860
|
+
"description": "The database role to use for the returned connection string. Defaults to netlifydb_owner if not specified.",
|
|
17861
|
+
"enum": [
|
|
17862
|
+
"netlifydb_owner",
|
|
17863
|
+
"netlifydb_readonly"
|
|
17864
|
+
]
|
|
17865
|
+
},
|
|
17866
|
+
{
|
|
17867
|
+
"name": "reset",
|
|
17669
17868
|
"in": "body",
|
|
17670
17869
|
"schema": {
|
|
17671
17870
|
"type": "object",
|
|
17672
|
-
"description": "Request body for
|
|
17871
|
+
"description": "Request body for resetting a database branch",
|
|
17673
17872
|
"properties": {
|
|
17674
|
-
"
|
|
17675
|
-
"type": "string",
|
|
17676
|
-
"description": "The name of the branch to snapshot. Defaults to \"production\" if not specified."
|
|
17677
|
-
},
|
|
17678
|
-
"name": {
|
|
17873
|
+
"source_branch_id": {
|
|
17679
17874
|
"type": "string",
|
|
17680
|
-
"description": "
|
|
17875
|
+
"description": "The ID of the branch to re-fork the target branch from. Defaults to \"production\" if not specified."
|
|
17681
17876
|
}
|
|
17682
17877
|
}
|
|
17683
17878
|
}
|
|
17684
17879
|
}
|
|
17685
17880
|
],
|
|
17686
17881
|
"responses": {
|
|
17687
|
-
"
|
|
17688
|
-
"description": "
|
|
17882
|
+
"200": {
|
|
17883
|
+
"description": "OK",
|
|
17689
17884
|
"schema": {
|
|
17690
17885
|
"type": "object",
|
|
17691
|
-
"description": "
|
|
17886
|
+
"description": "Response for a database branch reset",
|
|
17692
17887
|
"properties": {
|
|
17693
|
-
"
|
|
17694
|
-
"type": "
|
|
17695
|
-
"description": "
|
|
17888
|
+
"reset": {
|
|
17889
|
+
"type": "boolean",
|
|
17890
|
+
"description": "Whether the branch was actually re-forked. False when the target was already in sync with the source and `force=true` was not set."
|
|
17696
17891
|
},
|
|
17697
|
-
"
|
|
17892
|
+
"connection_string": {
|
|
17698
17893
|
"type": "string",
|
|
17699
|
-
"
|
|
17700
|
-
"description": "The timestamp when the snapshot was created"
|
|
17894
|
+
"description": "The connection string for the reset (or unchanged) branch"
|
|
17701
17895
|
},
|
|
17702
|
-
"
|
|
17703
|
-
"type": "
|
|
17704
|
-
"description": "
|
|
17896
|
+
"metadata": {
|
|
17897
|
+
"type": "object",
|
|
17898
|
+
"description": "Metadata associated with the branch",
|
|
17899
|
+
"additionalProperties": true
|
|
17705
17900
|
}
|
|
17706
17901
|
}
|
|
17707
17902
|
}
|
|
17708
17903
|
},
|
|
17904
|
+
"400": {
|
|
17905
|
+
"description": "Invalid request — for example, the target is the production branch or the source branch is the same as the target."
|
|
17906
|
+
},
|
|
17907
|
+
"404": {
|
|
17908
|
+
"description": "Database or branch not found"
|
|
17909
|
+
},
|
|
17709
17910
|
"default": {
|
|
17710
17911
|
"description": "error",
|
|
17711
17912
|
"schema": {
|
|
@@ -17728,55 +17929,95 @@
|
|
|
17728
17929
|
}
|
|
17729
17930
|
}
|
|
17730
17931
|
},
|
|
17731
|
-
"/sites/{site_id}/database/
|
|
17932
|
+
"/sites/{site_id}/database/branch/{branch_id}/compute/settings": {
|
|
17732
17933
|
"parameters": [
|
|
17733
17934
|
{
|
|
17734
17935
|
"name": "site_id",
|
|
17735
17936
|
"type": "string",
|
|
17736
17937
|
"in": "path",
|
|
17737
17938
|
"required": true
|
|
17939
|
+
},
|
|
17940
|
+
{
|
|
17941
|
+
"name": "branch_id",
|
|
17942
|
+
"type": "string",
|
|
17943
|
+
"in": "path",
|
|
17944
|
+
"required": true,
|
|
17945
|
+
"description": "The branch ID"
|
|
17738
17946
|
}
|
|
17739
17947
|
],
|
|
17740
|
-
"
|
|
17741
|
-
"
|
|
17742
|
-
"operationId": "listSiteDatabaseSnapshots",
|
|
17948
|
+
"put": {
|
|
17949
|
+
"operationId": "setSiteDatabaseBranchComputeSettings",
|
|
17743
17950
|
"tags": [
|
|
17744
17951
|
"database"
|
|
17745
17952
|
],
|
|
17746
|
-
"description": "
|
|
17953
|
+
"description": "Sets compute settings for a specific database branch, overriding project-level settings. Requires a Pro or higher plan.",
|
|
17954
|
+
"consumes": [
|
|
17955
|
+
"application/json"
|
|
17956
|
+
],
|
|
17957
|
+
"parameters": [
|
|
17958
|
+
{
|
|
17959
|
+
"name": "computeSettings",
|
|
17960
|
+
"in": "body",
|
|
17961
|
+
"schema": {
|
|
17962
|
+
"type": "object",
|
|
17963
|
+
"description": "Request body for setting compute settings. All fields are optional; only provided fields are updated.",
|
|
17964
|
+
"properties": {
|
|
17965
|
+
"min_cu": {
|
|
17966
|
+
"type": "number",
|
|
17967
|
+
"format": "double",
|
|
17968
|
+
"minimum": 0.25,
|
|
17969
|
+
"maximum": 16,
|
|
17970
|
+
"x-nullable": true,
|
|
17971
|
+
"description": "Minimum compute units (0.25 to 16.0). Must be less than or equal to max_cu."
|
|
17972
|
+
},
|
|
17973
|
+
"max_cu": {
|
|
17974
|
+
"type": "number",
|
|
17975
|
+
"format": "double",
|
|
17976
|
+
"minimum": 0.25,
|
|
17977
|
+
"maximum": 16,
|
|
17978
|
+
"x-nullable": true,
|
|
17979
|
+
"description": "Maximum compute units (0.25 to 16.0). Must be greater than or equal to min_cu. max_cu - min_cu must not exceed 8.0."
|
|
17980
|
+
},
|
|
17981
|
+
"sleep_timeout_seconds": {
|
|
17982
|
+
"type": "integer",
|
|
17983
|
+
"format": "int64",
|
|
17984
|
+
"minimum": -1,
|
|
17985
|
+
"x-nullable": true,
|
|
17986
|
+
"description": "Seconds of inactivity before the compute endpoint is suspended. Use -1 for always on, or a non-negative value."
|
|
17987
|
+
}
|
|
17988
|
+
}
|
|
17989
|
+
},
|
|
17990
|
+
"required": true
|
|
17991
|
+
}
|
|
17992
|
+
],
|
|
17747
17993
|
"responses": {
|
|
17748
17994
|
"200": {
|
|
17749
17995
|
"description": "OK",
|
|
17750
17996
|
"schema": {
|
|
17751
17997
|
"type": "object",
|
|
17752
|
-
"description": "
|
|
17998
|
+
"description": "Compute settings for a database or branch",
|
|
17753
17999
|
"properties": {
|
|
17754
|
-
"
|
|
17755
|
-
"type": "
|
|
17756
|
-
"
|
|
17757
|
-
|
|
17758
|
-
|
|
17759
|
-
|
|
17760
|
-
|
|
17761
|
-
|
|
17762
|
-
|
|
17763
|
-
|
|
17764
|
-
|
|
17765
|
-
|
|
17766
|
-
|
|
17767
|
-
|
|
17768
|
-
},
|
|
17769
|
-
"source_branch_id": {
|
|
17770
|
-
"type": "string",
|
|
17771
|
-
"description": "The ID of the branch that was snapshotted"
|
|
17772
|
-
}
|
|
17773
|
-
}
|
|
17774
|
-
},
|
|
17775
|
-
"description": "List of database snapshots"
|
|
18000
|
+
"min_cu": {
|
|
18001
|
+
"type": "number",
|
|
18002
|
+
"format": "double",
|
|
18003
|
+
"description": "Minimum compute units"
|
|
18004
|
+
},
|
|
18005
|
+
"max_cu": {
|
|
18006
|
+
"type": "number",
|
|
18007
|
+
"format": "double",
|
|
18008
|
+
"description": "Maximum compute units"
|
|
18009
|
+
},
|
|
18010
|
+
"sleep_timeout_seconds": {
|
|
18011
|
+
"type": "integer",
|
|
18012
|
+
"format": "int64",
|
|
18013
|
+
"description": "Seconds of inactivity before suspension"
|
|
17776
18014
|
}
|
|
17777
18015
|
}
|
|
17778
18016
|
}
|
|
17779
18017
|
},
|
|
18018
|
+
"403": {
|
|
18019
|
+
"description": "Compute customization requires a Pro or higher plan"
|
|
18020
|
+
},
|
|
17780
18021
|
"default": {
|
|
17781
18022
|
"description": "error",
|
|
17782
18023
|
"schema": {
|
|
@@ -17799,44 +18040,708 @@
|
|
|
17799
18040
|
}
|
|
17800
18041
|
}
|
|
17801
18042
|
},
|
|
17802
|
-
"/sites/{site_id}/database/
|
|
18043
|
+
"/sites/{site_id}/database/compute/settings": {
|
|
17803
18044
|
"parameters": [
|
|
17804
18045
|
{
|
|
17805
18046
|
"name": "site_id",
|
|
17806
18047
|
"type": "string",
|
|
17807
18048
|
"in": "path",
|
|
17808
18049
|
"required": true
|
|
17809
|
-
},
|
|
17810
|
-
{
|
|
17811
|
-
"name": "snapshot_id",
|
|
17812
|
-
"type": "string",
|
|
17813
|
-
"in": "path",
|
|
17814
|
-
"required": true,
|
|
17815
|
-
"description": "The snapshot ID"
|
|
17816
18050
|
}
|
|
17817
18051
|
],
|
|
17818
|
-
"
|
|
17819
|
-
"
|
|
17820
|
-
"operationId": "deleteSiteDatabaseSnapshot",
|
|
18052
|
+
"put": {
|
|
18053
|
+
"operationId": "setSiteDatabaseComputeSettings",
|
|
17821
18054
|
"tags": [
|
|
17822
18055
|
"database"
|
|
17823
18056
|
],
|
|
17824
|
-
"description": "
|
|
17825
|
-
"
|
|
17826
|
-
"
|
|
17827
|
-
|
|
17828
|
-
|
|
17829
|
-
|
|
17830
|
-
"
|
|
18057
|
+
"description": "Sets project-level compute settings for the database. Applied to new branches. Can be overridden per-branch. Requires a Pro or higher plan.",
|
|
18058
|
+
"consumes": [
|
|
18059
|
+
"application/json"
|
|
18060
|
+
],
|
|
18061
|
+
"parameters": [
|
|
18062
|
+
{
|
|
18063
|
+
"name": "computeSettings",
|
|
18064
|
+
"in": "body",
|
|
17831
18065
|
"schema": {
|
|
17832
18066
|
"type": "object",
|
|
17833
|
-
"
|
|
17834
|
-
"message"
|
|
17835
|
-
],
|
|
18067
|
+
"description": "Request body for setting compute settings. All fields are optional; only provided fields are updated.",
|
|
17836
18068
|
"properties": {
|
|
17837
|
-
"
|
|
17838
|
-
"type": "
|
|
17839
|
-
"format": "
|
|
18069
|
+
"min_cu": {
|
|
18070
|
+
"type": "number",
|
|
18071
|
+
"format": "double",
|
|
18072
|
+
"minimum": 0.25,
|
|
18073
|
+
"maximum": 16,
|
|
18074
|
+
"x-nullable": true,
|
|
18075
|
+
"description": "Minimum compute units (0.25 to 16.0). Must be less than or equal to max_cu."
|
|
18076
|
+
},
|
|
18077
|
+
"max_cu": {
|
|
18078
|
+
"type": "number",
|
|
18079
|
+
"format": "double",
|
|
18080
|
+
"minimum": 0.25,
|
|
18081
|
+
"maximum": 16,
|
|
18082
|
+
"x-nullable": true,
|
|
18083
|
+
"description": "Maximum compute units (0.25 to 16.0). Must be greater than or equal to min_cu. max_cu - min_cu must not exceed 8.0."
|
|
18084
|
+
},
|
|
18085
|
+
"sleep_timeout_seconds": {
|
|
18086
|
+
"type": "integer",
|
|
18087
|
+
"format": "int64",
|
|
18088
|
+
"minimum": -1,
|
|
18089
|
+
"x-nullable": true,
|
|
18090
|
+
"description": "Seconds of inactivity before the compute endpoint is suspended. Use -1 for always on, or a non-negative value."
|
|
18091
|
+
}
|
|
18092
|
+
}
|
|
18093
|
+
},
|
|
18094
|
+
"required": true
|
|
18095
|
+
}
|
|
18096
|
+
],
|
|
18097
|
+
"responses": {
|
|
18098
|
+
"200": {
|
|
18099
|
+
"description": "OK",
|
|
18100
|
+
"schema": {
|
|
18101
|
+
"type": "object",
|
|
18102
|
+
"description": "Compute settings for a database or branch",
|
|
18103
|
+
"properties": {
|
|
18104
|
+
"min_cu": {
|
|
18105
|
+
"type": "number",
|
|
18106
|
+
"format": "double",
|
|
18107
|
+
"description": "Minimum compute units"
|
|
18108
|
+
},
|
|
18109
|
+
"max_cu": {
|
|
18110
|
+
"type": "number",
|
|
18111
|
+
"format": "double",
|
|
18112
|
+
"description": "Maximum compute units"
|
|
18113
|
+
},
|
|
18114
|
+
"sleep_timeout_seconds": {
|
|
18115
|
+
"type": "integer",
|
|
18116
|
+
"format": "int64",
|
|
18117
|
+
"description": "Seconds of inactivity before suspension"
|
|
18118
|
+
}
|
|
18119
|
+
}
|
|
18120
|
+
}
|
|
18121
|
+
},
|
|
18122
|
+
"403": {
|
|
18123
|
+
"description": "Compute customization requires a Pro or higher plan"
|
|
18124
|
+
},
|
|
18125
|
+
"default": {
|
|
18126
|
+
"description": "error",
|
|
18127
|
+
"schema": {
|
|
18128
|
+
"type": "object",
|
|
18129
|
+
"required": [
|
|
18130
|
+
"message"
|
|
18131
|
+
],
|
|
18132
|
+
"properties": {
|
|
18133
|
+
"code": {
|
|
18134
|
+
"type": "integer",
|
|
18135
|
+
"format": "int64"
|
|
18136
|
+
},
|
|
18137
|
+
"message": {
|
|
18138
|
+
"type": "string",
|
|
18139
|
+
"x-nullable": false
|
|
18140
|
+
}
|
|
18141
|
+
}
|
|
18142
|
+
}
|
|
18143
|
+
}
|
|
18144
|
+
}
|
|
18145
|
+
},
|
|
18146
|
+
"get": {
|
|
18147
|
+
"operationId": "getSiteDatabaseComputeSettings",
|
|
18148
|
+
"tags": [
|
|
18149
|
+
"database"
|
|
18150
|
+
],
|
|
18151
|
+
"description": "Returns the project-level compute settings for the database. Returns effective settings (custom or tier defaults). Requires a Pro or higher plan.",
|
|
18152
|
+
"responses": {
|
|
18153
|
+
"200": {
|
|
18154
|
+
"description": "OK",
|
|
18155
|
+
"schema": {
|
|
18156
|
+
"type": "object",
|
|
18157
|
+
"description": "Compute settings for a database or branch",
|
|
18158
|
+
"properties": {
|
|
18159
|
+
"min_cu": {
|
|
18160
|
+
"type": "number",
|
|
18161
|
+
"format": "double",
|
|
18162
|
+
"description": "Minimum compute units"
|
|
18163
|
+
},
|
|
18164
|
+
"max_cu": {
|
|
18165
|
+
"type": "number",
|
|
18166
|
+
"format": "double",
|
|
18167
|
+
"description": "Maximum compute units"
|
|
18168
|
+
},
|
|
18169
|
+
"sleep_timeout_seconds": {
|
|
18170
|
+
"type": "integer",
|
|
18171
|
+
"format": "int64",
|
|
18172
|
+
"description": "Seconds of inactivity before suspension"
|
|
18173
|
+
}
|
|
18174
|
+
}
|
|
18175
|
+
}
|
|
18176
|
+
},
|
|
18177
|
+
"403": {
|
|
18178
|
+
"description": "Compute customization requires a Pro or higher plan"
|
|
18179
|
+
},
|
|
18180
|
+
"default": {
|
|
18181
|
+
"description": "error",
|
|
18182
|
+
"schema": {
|
|
18183
|
+
"type": "object",
|
|
18184
|
+
"required": [
|
|
18185
|
+
"message"
|
|
18186
|
+
],
|
|
18187
|
+
"properties": {
|
|
18188
|
+
"code": {
|
|
18189
|
+
"type": "integer",
|
|
18190
|
+
"format": "int64"
|
|
18191
|
+
},
|
|
18192
|
+
"message": {
|
|
18193
|
+
"type": "string",
|
|
18194
|
+
"x-nullable": false
|
|
18195
|
+
}
|
|
18196
|
+
}
|
|
18197
|
+
}
|
|
18198
|
+
}
|
|
18199
|
+
}
|
|
18200
|
+
},
|
|
18201
|
+
"delete": {
|
|
18202
|
+
"operationId": "clearSiteDatabaseComputeSettings",
|
|
18203
|
+
"tags": [
|
|
18204
|
+
"database"
|
|
18205
|
+
],
|
|
18206
|
+
"description": "Resets project-level compute settings to tier defaults. Requires a Pro or higher plan.",
|
|
18207
|
+
"responses": {
|
|
18208
|
+
"204": {
|
|
18209
|
+
"description": "Cleared"
|
|
18210
|
+
},
|
|
18211
|
+
"403": {
|
|
18212
|
+
"description": "Compute customization requires a Pro or higher plan"
|
|
18213
|
+
},
|
|
18214
|
+
"default": {
|
|
18215
|
+
"description": "error",
|
|
18216
|
+
"schema": {
|
|
18217
|
+
"type": "object",
|
|
18218
|
+
"required": [
|
|
18219
|
+
"message"
|
|
18220
|
+
],
|
|
18221
|
+
"properties": {
|
|
18222
|
+
"code": {
|
|
18223
|
+
"type": "integer",
|
|
18224
|
+
"format": "int64"
|
|
18225
|
+
},
|
|
18226
|
+
"message": {
|
|
18227
|
+
"type": "string",
|
|
18228
|
+
"x-nullable": false
|
|
18229
|
+
}
|
|
18230
|
+
}
|
|
18231
|
+
}
|
|
18232
|
+
}
|
|
18233
|
+
}
|
|
18234
|
+
}
|
|
18235
|
+
},
|
|
18236
|
+
"/sites/{site_id}/database/migrations": {
|
|
18237
|
+
"parameters": [
|
|
18238
|
+
{
|
|
18239
|
+
"name": "site_id",
|
|
18240
|
+
"type": "string",
|
|
18241
|
+
"in": "path",
|
|
18242
|
+
"required": true
|
|
18243
|
+
}
|
|
18244
|
+
],
|
|
18245
|
+
"get": {
|
|
18246
|
+
"operationId": "listSiteDatabaseMigrations",
|
|
18247
|
+
"tags": [
|
|
18248
|
+
"database"
|
|
18249
|
+
],
|
|
18250
|
+
"description": "Returns the list of migrations available for the specified branch, indicating which ones have been applied to the database.",
|
|
18251
|
+
"parameters": [
|
|
18252
|
+
{
|
|
18253
|
+
"name": "branch",
|
|
18254
|
+
"type": "string",
|
|
18255
|
+
"in": "query",
|
|
18256
|
+
"description": "The branch ID to list migrations for. Defaults to \"production\" if not specified."
|
|
18257
|
+
}
|
|
18258
|
+
],
|
|
18259
|
+
"responses": {
|
|
18260
|
+
"200": {
|
|
18261
|
+
"description": "OK",
|
|
18262
|
+
"schema": {
|
|
18263
|
+
"type": "object",
|
|
18264
|
+
"description": "Response containing the list of migrations for a branch",
|
|
18265
|
+
"properties": {
|
|
18266
|
+
"migrations": {
|
|
18267
|
+
"type": "array",
|
|
18268
|
+
"items": {
|
|
18269
|
+
"type": "object",
|
|
18270
|
+
"description": "A migration available to a database branch",
|
|
18271
|
+
"properties": {
|
|
18272
|
+
"version": {
|
|
18273
|
+
"type": "integer",
|
|
18274
|
+
"format": "int64",
|
|
18275
|
+
"description": "The migration version number"
|
|
18276
|
+
},
|
|
18277
|
+
"name": {
|
|
18278
|
+
"type": "string",
|
|
18279
|
+
"description": "The migration name"
|
|
18280
|
+
},
|
|
18281
|
+
"path": {
|
|
18282
|
+
"type": "string",
|
|
18283
|
+
"description": "The path to the migration file in the deploy bundle"
|
|
18284
|
+
},
|
|
18285
|
+
"applied": {
|
|
18286
|
+
"type": "boolean",
|
|
18287
|
+
"description": "Whether this migration has been applied to the branch"
|
|
18288
|
+
}
|
|
18289
|
+
}
|
|
18290
|
+
},
|
|
18291
|
+
"description": "List of migrations"
|
|
18292
|
+
}
|
|
18293
|
+
}
|
|
18294
|
+
}
|
|
18295
|
+
},
|
|
18296
|
+
"404": {
|
|
18297
|
+
"description": "Database or branch not found"
|
|
18298
|
+
},
|
|
18299
|
+
"423": {
|
|
18300
|
+
"description": "Database is disabled"
|
|
18301
|
+
},
|
|
18302
|
+
"default": {
|
|
18303
|
+
"description": "error",
|
|
18304
|
+
"schema": {
|
|
18305
|
+
"type": "object",
|
|
18306
|
+
"required": [
|
|
18307
|
+
"message"
|
|
18308
|
+
],
|
|
18309
|
+
"properties": {
|
|
18310
|
+
"code": {
|
|
18311
|
+
"type": "integer",
|
|
18312
|
+
"format": "int64"
|
|
18313
|
+
},
|
|
18314
|
+
"message": {
|
|
18315
|
+
"type": "string",
|
|
18316
|
+
"x-nullable": false
|
|
18317
|
+
}
|
|
18318
|
+
}
|
|
18319
|
+
}
|
|
18320
|
+
}
|
|
18321
|
+
}
|
|
18322
|
+
}
|
|
18323
|
+
},
|
|
18324
|
+
"/sites/{site_id}/database/migrations/{name}": {
|
|
18325
|
+
"parameters": [
|
|
18326
|
+
{
|
|
18327
|
+
"name": "site_id",
|
|
18328
|
+
"type": "string",
|
|
18329
|
+
"in": "path",
|
|
18330
|
+
"required": true
|
|
18331
|
+
},
|
|
18332
|
+
{
|
|
18333
|
+
"name": "name",
|
|
18334
|
+
"type": "string",
|
|
18335
|
+
"in": "path",
|
|
18336
|
+
"required": true,
|
|
18337
|
+
"description": "The migration name"
|
|
18338
|
+
}
|
|
18339
|
+
],
|
|
18340
|
+
"get": {
|
|
18341
|
+
"operationId": "getSiteDatabaseMigration",
|
|
18342
|
+
"tags": [
|
|
18343
|
+
"database"
|
|
18344
|
+
],
|
|
18345
|
+
"description": "Returns the contents of a named migration for the specified branch.",
|
|
18346
|
+
"parameters": [
|
|
18347
|
+
{
|
|
18348
|
+
"name": "branch",
|
|
18349
|
+
"type": "string",
|
|
18350
|
+
"in": "query",
|
|
18351
|
+
"description": "The branch ID to look up the migration on. Defaults to the currently published deploy's branch."
|
|
18352
|
+
}
|
|
18353
|
+
],
|
|
18354
|
+
"responses": {
|
|
18355
|
+
"200": {
|
|
18356
|
+
"description": "OK",
|
|
18357
|
+
"schema": {
|
|
18358
|
+
"type": "object",
|
|
18359
|
+
"description": "A migration with its file contents",
|
|
18360
|
+
"properties": {
|
|
18361
|
+
"version": {
|
|
18362
|
+
"type": "integer",
|
|
18363
|
+
"format": "int64",
|
|
18364
|
+
"description": "The migration version number"
|
|
18365
|
+
},
|
|
18366
|
+
"name": {
|
|
18367
|
+
"type": "string",
|
|
18368
|
+
"description": "The migration name"
|
|
18369
|
+
},
|
|
18370
|
+
"path": {
|
|
18371
|
+
"type": "string",
|
|
18372
|
+
"description": "The path to the migration file in the deploy bundle"
|
|
18373
|
+
},
|
|
18374
|
+
"content": {
|
|
18375
|
+
"type": "string",
|
|
18376
|
+
"description": "The raw contents of the migration file"
|
|
18377
|
+
}
|
|
18378
|
+
}
|
|
18379
|
+
}
|
|
18380
|
+
},
|
|
18381
|
+
"404": {
|
|
18382
|
+
"description": "Migration, database, or branch not found"
|
|
18383
|
+
},
|
|
18384
|
+
"423": {
|
|
18385
|
+
"description": "Database is disabled"
|
|
18386
|
+
},
|
|
18387
|
+
"default": {
|
|
18388
|
+
"description": "error",
|
|
18389
|
+
"schema": {
|
|
18390
|
+
"type": "object",
|
|
18391
|
+
"required": [
|
|
18392
|
+
"message"
|
|
18393
|
+
],
|
|
18394
|
+
"properties": {
|
|
18395
|
+
"code": {
|
|
18396
|
+
"type": "integer",
|
|
18397
|
+
"format": "int64"
|
|
18398
|
+
},
|
|
18399
|
+
"message": {
|
|
18400
|
+
"type": "string",
|
|
18401
|
+
"x-nullable": false
|
|
18402
|
+
}
|
|
18403
|
+
}
|
|
18404
|
+
}
|
|
18405
|
+
}
|
|
18406
|
+
}
|
|
18407
|
+
}
|
|
18408
|
+
},
|
|
18409
|
+
"/sites/{site_id}/database/migrations/{deploy_id}": {
|
|
18410
|
+
"parameters": [
|
|
18411
|
+
{
|
|
18412
|
+
"name": "site_id",
|
|
18413
|
+
"type": "string",
|
|
18414
|
+
"in": "path",
|
|
18415
|
+
"required": true
|
|
18416
|
+
},
|
|
18417
|
+
{
|
|
18418
|
+
"name": "deploy_id",
|
|
18419
|
+
"type": "string",
|
|
18420
|
+
"in": "path",
|
|
18421
|
+
"required": true,
|
|
18422
|
+
"description": "The deploy ID to run migrations for"
|
|
18423
|
+
}
|
|
18424
|
+
],
|
|
18425
|
+
"post": {
|
|
18426
|
+
"operationId": "runSiteDatabaseMigrations",
|
|
18427
|
+
"tags": [
|
|
18428
|
+
"database"
|
|
18429
|
+
],
|
|
18430
|
+
"description": "Runs database migrations for the specified deploy. Finds the deploy and determines the appropriate branch.",
|
|
18431
|
+
"consumes": [
|
|
18432
|
+
"application/json"
|
|
18433
|
+
],
|
|
18434
|
+
"parameters": [
|
|
18435
|
+
{
|
|
18436
|
+
"name": "migrations",
|
|
18437
|
+
"in": "body",
|
|
18438
|
+
"schema": {
|
|
18439
|
+
"type": "object",
|
|
18440
|
+
"description": "Request body for running database migrations",
|
|
18441
|
+
"properties": {
|
|
18442
|
+
"dry_run": {
|
|
18443
|
+
"type": "boolean",
|
|
18444
|
+
"description": "If true, validates migrations without applying them."
|
|
18445
|
+
}
|
|
18446
|
+
}
|
|
18447
|
+
}
|
|
18448
|
+
}
|
|
18449
|
+
],
|
|
18450
|
+
"responses": {
|
|
18451
|
+
"200": {
|
|
18452
|
+
"description": "OK"
|
|
18453
|
+
},
|
|
18454
|
+
"409": {
|
|
18455
|
+
"description": "Migration conflict - migration modified or removed after being applied"
|
|
18456
|
+
},
|
|
18457
|
+
"422": {
|
|
18458
|
+
"description": "Migration validation failed"
|
|
18459
|
+
},
|
|
18460
|
+
"default": {
|
|
18461
|
+
"description": "error",
|
|
18462
|
+
"schema": {
|
|
18463
|
+
"type": "object",
|
|
18464
|
+
"required": [
|
|
18465
|
+
"message"
|
|
18466
|
+
],
|
|
18467
|
+
"properties": {
|
|
18468
|
+
"code": {
|
|
18469
|
+
"type": "integer",
|
|
18470
|
+
"format": "int64"
|
|
18471
|
+
},
|
|
18472
|
+
"message": {
|
|
18473
|
+
"type": "string",
|
|
18474
|
+
"x-nullable": false
|
|
18475
|
+
}
|
|
18476
|
+
}
|
|
18477
|
+
}
|
|
18478
|
+
}
|
|
18479
|
+
}
|
|
18480
|
+
}
|
|
18481
|
+
},
|
|
18482
|
+
"/sites/{site_id}/database/snapshot": {
|
|
18483
|
+
"parameters": [
|
|
18484
|
+
{
|
|
18485
|
+
"name": "site_id",
|
|
18486
|
+
"type": "string",
|
|
18487
|
+
"in": "path",
|
|
18488
|
+
"required": true
|
|
18489
|
+
}
|
|
18490
|
+
],
|
|
18491
|
+
"post": {
|
|
18492
|
+
"operationId": "createSiteDatabaseSnapshot",
|
|
18493
|
+
"tags": [
|
|
18494
|
+
"database"
|
|
18495
|
+
],
|
|
18496
|
+
"description": "Creates a point-in-time snapshot of a database branch. Defaults to the production branch if no branch name is specified.",
|
|
18497
|
+
"consumes": [
|
|
18498
|
+
"application/json"
|
|
18499
|
+
],
|
|
18500
|
+
"parameters": [
|
|
18501
|
+
{
|
|
18502
|
+
"name": "snapshot",
|
|
18503
|
+
"in": "body",
|
|
18504
|
+
"schema": {
|
|
18505
|
+
"type": "object",
|
|
18506
|
+
"description": "Request body for creating a database snapshot",
|
|
18507
|
+
"properties": {
|
|
18508
|
+
"branch_id": {
|
|
18509
|
+
"type": "string",
|
|
18510
|
+
"description": "The ID of the branch to snapshot. Defaults to \"production\" if not specified."
|
|
18511
|
+
},
|
|
18512
|
+
"name": {
|
|
18513
|
+
"type": "string",
|
|
18514
|
+
"description": "A name for the snapshot"
|
|
18515
|
+
},
|
|
18516
|
+
"metadata": {
|
|
18517
|
+
"type": "object",
|
|
18518
|
+
"description": "Metadata associated with a snapshot",
|
|
18519
|
+
"properties": {
|
|
18520
|
+
"deploy": {
|
|
18521
|
+
"type": "object",
|
|
18522
|
+
"description": "Deploy information associated with the snapshot",
|
|
18523
|
+
"additionalProperties": true
|
|
18524
|
+
},
|
|
18525
|
+
"source": {
|
|
18526
|
+
"type": "string",
|
|
18527
|
+
"description": "The source that created the snapshot"
|
|
18528
|
+
}
|
|
18529
|
+
}
|
|
18530
|
+
}
|
|
18531
|
+
}
|
|
18532
|
+
}
|
|
18533
|
+
}
|
|
18534
|
+
],
|
|
18535
|
+
"responses": {
|
|
18536
|
+
"201": {
|
|
18537
|
+
"description": "Created",
|
|
18538
|
+
"schema": {
|
|
18539
|
+
"type": "object",
|
|
18540
|
+
"description": "A point-in-time snapshot of a database branch",
|
|
18541
|
+
"properties": {
|
|
18542
|
+
"id": {
|
|
18543
|
+
"type": "string",
|
|
18544
|
+
"description": "The unique identifier of the snapshot"
|
|
18545
|
+
},
|
|
18546
|
+
"source_branch_id": {
|
|
18547
|
+
"type": "string",
|
|
18548
|
+
"description": "The ID of the branch that was snapshotted"
|
|
18549
|
+
},
|
|
18550
|
+
"manual": {
|
|
18551
|
+
"type": "boolean",
|
|
18552
|
+
"description": "Whether this snapshot was manually created"
|
|
18553
|
+
},
|
|
18554
|
+
"created_at": {
|
|
18555
|
+
"type": "string",
|
|
18556
|
+
"format": "dateTime",
|
|
18557
|
+
"description": "When the snapshot was created"
|
|
18558
|
+
},
|
|
18559
|
+
"expires_at": {
|
|
18560
|
+
"type": "string",
|
|
18561
|
+
"format": "dateTime",
|
|
18562
|
+
"description": "When the snapshot expires"
|
|
18563
|
+
},
|
|
18564
|
+
"timestamp": {
|
|
18565
|
+
"type": "string",
|
|
18566
|
+
"format": "dateTime",
|
|
18567
|
+
"description": "The point-in-time timestamp of the snapshot"
|
|
18568
|
+
},
|
|
18569
|
+
"metadata": {
|
|
18570
|
+
"type": "object",
|
|
18571
|
+
"description": "Metadata associated with a snapshot",
|
|
18572
|
+
"properties": {
|
|
18573
|
+
"deploy": {
|
|
18574
|
+
"type": "object",
|
|
18575
|
+
"description": "Deploy information associated with the snapshot",
|
|
18576
|
+
"additionalProperties": true
|
|
18577
|
+
},
|
|
18578
|
+
"source": {
|
|
18579
|
+
"type": "string",
|
|
18580
|
+
"description": "The source that created the snapshot"
|
|
18581
|
+
}
|
|
18582
|
+
}
|
|
18583
|
+
}
|
|
18584
|
+
}
|
|
18585
|
+
}
|
|
18586
|
+
},
|
|
18587
|
+
"default": {
|
|
18588
|
+
"description": "error",
|
|
18589
|
+
"schema": {
|
|
18590
|
+
"type": "object",
|
|
18591
|
+
"required": [
|
|
18592
|
+
"message"
|
|
18593
|
+
],
|
|
18594
|
+
"properties": {
|
|
18595
|
+
"code": {
|
|
18596
|
+
"type": "integer",
|
|
18597
|
+
"format": "int64"
|
|
18598
|
+
},
|
|
18599
|
+
"message": {
|
|
18600
|
+
"type": "string",
|
|
18601
|
+
"x-nullable": false
|
|
18602
|
+
}
|
|
18603
|
+
}
|
|
18604
|
+
}
|
|
18605
|
+
}
|
|
18606
|
+
}
|
|
18607
|
+
}
|
|
18608
|
+
},
|
|
18609
|
+
"/sites/{site_id}/database/snapshots": {
|
|
18610
|
+
"parameters": [
|
|
18611
|
+
{
|
|
18612
|
+
"name": "site_id",
|
|
18613
|
+
"type": "string",
|
|
18614
|
+
"in": "path",
|
|
18615
|
+
"required": true
|
|
18616
|
+
}
|
|
18617
|
+
],
|
|
18618
|
+
"get": {
|
|
18619
|
+
"operationId": "listSiteDatabaseSnapshots",
|
|
18620
|
+
"tags": [
|
|
18621
|
+
"database"
|
|
18622
|
+
],
|
|
18623
|
+
"description": "Returns all snapshots for the site's database.",
|
|
18624
|
+
"responses": {
|
|
18625
|
+
"200": {
|
|
18626
|
+
"description": "OK",
|
|
18627
|
+
"schema": {
|
|
18628
|
+
"type": "object",
|
|
18629
|
+
"description": "Response containing a list of database snapshots",
|
|
18630
|
+
"properties": {
|
|
18631
|
+
"snapshots": {
|
|
18632
|
+
"type": "array",
|
|
18633
|
+
"items": {
|
|
18634
|
+
"type": "object",
|
|
18635
|
+
"description": "A point-in-time snapshot of a database branch",
|
|
18636
|
+
"properties": {
|
|
18637
|
+
"id": {
|
|
18638
|
+
"type": "string",
|
|
18639
|
+
"description": "The unique identifier of the snapshot"
|
|
18640
|
+
},
|
|
18641
|
+
"source_branch_id": {
|
|
18642
|
+
"type": "string",
|
|
18643
|
+
"description": "The ID of the branch that was snapshotted"
|
|
18644
|
+
},
|
|
18645
|
+
"manual": {
|
|
18646
|
+
"type": "boolean",
|
|
18647
|
+
"description": "Whether this snapshot was manually created"
|
|
18648
|
+
},
|
|
18649
|
+
"created_at": {
|
|
18650
|
+
"type": "string",
|
|
18651
|
+
"format": "dateTime",
|
|
18652
|
+
"description": "When the snapshot was created"
|
|
18653
|
+
},
|
|
18654
|
+
"expires_at": {
|
|
18655
|
+
"type": "string",
|
|
18656
|
+
"format": "dateTime",
|
|
18657
|
+
"description": "When the snapshot expires"
|
|
18658
|
+
},
|
|
18659
|
+
"timestamp": {
|
|
18660
|
+
"type": "string",
|
|
18661
|
+
"format": "dateTime",
|
|
18662
|
+
"description": "The point-in-time timestamp of the snapshot"
|
|
18663
|
+
},
|
|
18664
|
+
"metadata": {
|
|
18665
|
+
"type": "object",
|
|
18666
|
+
"description": "Metadata associated with a snapshot",
|
|
18667
|
+
"properties": {
|
|
18668
|
+
"deploy": {
|
|
18669
|
+
"type": "object",
|
|
18670
|
+
"description": "Deploy information associated with the snapshot",
|
|
18671
|
+
"additionalProperties": true
|
|
18672
|
+
},
|
|
18673
|
+
"source": {
|
|
18674
|
+
"type": "string",
|
|
18675
|
+
"description": "The source that created the snapshot"
|
|
18676
|
+
}
|
|
18677
|
+
}
|
|
18678
|
+
}
|
|
18679
|
+
}
|
|
18680
|
+
},
|
|
18681
|
+
"description": "List of database snapshots"
|
|
18682
|
+
}
|
|
18683
|
+
}
|
|
18684
|
+
}
|
|
18685
|
+
},
|
|
18686
|
+
"default": {
|
|
18687
|
+
"description": "error",
|
|
18688
|
+
"schema": {
|
|
18689
|
+
"type": "object",
|
|
18690
|
+
"required": [
|
|
18691
|
+
"message"
|
|
18692
|
+
],
|
|
18693
|
+
"properties": {
|
|
18694
|
+
"code": {
|
|
18695
|
+
"type": "integer",
|
|
18696
|
+
"format": "int64"
|
|
18697
|
+
},
|
|
18698
|
+
"message": {
|
|
18699
|
+
"type": "string",
|
|
18700
|
+
"x-nullable": false
|
|
18701
|
+
}
|
|
18702
|
+
}
|
|
18703
|
+
}
|
|
18704
|
+
}
|
|
18705
|
+
}
|
|
18706
|
+
}
|
|
18707
|
+
},
|
|
18708
|
+
"/sites/{site_id}/database/snapshot/{snapshot_id}": {
|
|
18709
|
+
"parameters": [
|
|
18710
|
+
{
|
|
18711
|
+
"name": "site_id",
|
|
18712
|
+
"type": "string",
|
|
18713
|
+
"in": "path",
|
|
18714
|
+
"required": true
|
|
18715
|
+
},
|
|
18716
|
+
{
|
|
18717
|
+
"name": "snapshot_id",
|
|
18718
|
+
"type": "string",
|
|
18719
|
+
"in": "path",
|
|
18720
|
+
"required": true,
|
|
18721
|
+
"description": "The snapshot ID"
|
|
18722
|
+
}
|
|
18723
|
+
],
|
|
18724
|
+
"delete": {
|
|
18725
|
+
"operationId": "deleteSiteDatabaseSnapshot",
|
|
18726
|
+
"tags": [
|
|
18727
|
+
"database"
|
|
18728
|
+
],
|
|
18729
|
+
"description": "Deletes a database snapshot.",
|
|
18730
|
+
"responses": {
|
|
18731
|
+
"204": {
|
|
18732
|
+
"description": "Deleted"
|
|
18733
|
+
},
|
|
18734
|
+
"default": {
|
|
18735
|
+
"description": "error",
|
|
18736
|
+
"schema": {
|
|
18737
|
+
"type": "object",
|
|
18738
|
+
"required": [
|
|
18739
|
+
"message"
|
|
18740
|
+
],
|
|
18741
|
+
"properties": {
|
|
18742
|
+
"code": {
|
|
18743
|
+
"type": "integer",
|
|
18744
|
+
"format": "int64"
|
|
17840
18745
|
},
|
|
17841
18746
|
"message": {
|
|
17842
18747
|
"type": "string",
|
|
@@ -17865,7 +18770,6 @@
|
|
|
17865
18770
|
}
|
|
17866
18771
|
],
|
|
17867
18772
|
"post": {
|
|
17868
|
-
"x-internal": true,
|
|
17869
18773
|
"operationId": "restoreSiteDatabaseSnapshot",
|
|
17870
18774
|
"tags": [
|
|
17871
18775
|
"database"
|
|
@@ -17882,86 +18786,316 @@
|
|
|
17882
18786
|
"type": "object",
|
|
17883
18787
|
"description": "Request body for restoring a database snapshot",
|
|
17884
18788
|
"properties": {
|
|
17885
|
-
"
|
|
18789
|
+
"branch_id": {
|
|
18790
|
+
"type": "string",
|
|
18791
|
+
"description": "The ID of the branch to restore the snapshot to. Defaults to \"production\" if not specified."
|
|
18792
|
+
}
|
|
18793
|
+
}
|
|
18794
|
+
}
|
|
18795
|
+
}
|
|
18796
|
+
],
|
|
18797
|
+
"responses": {
|
|
18798
|
+
"200": {
|
|
18799
|
+
"description": "OK"
|
|
18800
|
+
},
|
|
18801
|
+
"default": {
|
|
18802
|
+
"description": "error",
|
|
18803
|
+
"schema": {
|
|
18804
|
+
"type": "object",
|
|
18805
|
+
"required": [
|
|
18806
|
+
"message"
|
|
18807
|
+
],
|
|
18808
|
+
"properties": {
|
|
18809
|
+
"code": {
|
|
18810
|
+
"type": "integer",
|
|
18811
|
+
"format": "int64"
|
|
18812
|
+
},
|
|
18813
|
+
"message": {
|
|
17886
18814
|
"type": "string",
|
|
17887
|
-
"
|
|
18815
|
+
"x-nullable": false
|
|
18816
|
+
}
|
|
18817
|
+
}
|
|
18818
|
+
}
|
|
18819
|
+
}
|
|
18820
|
+
}
|
|
18821
|
+
}
|
|
18822
|
+
}
|
|
18823
|
+
},
|
|
18824
|
+
"definitions": {
|
|
18825
|
+
"createDatabaseRequest": {
|
|
18826
|
+
"type": "object",
|
|
18827
|
+
"description": "Request body for creating a database",
|
|
18828
|
+
"properties": {
|
|
18829
|
+
"region": {
|
|
18830
|
+
"type": "string",
|
|
18831
|
+
"description": "The region where the database should be created. Defaults to the site's functions region if not specified."
|
|
18832
|
+
}
|
|
18833
|
+
}
|
|
18834
|
+
},
|
|
18835
|
+
"databaseResponse": {
|
|
18836
|
+
"type": "object",
|
|
18837
|
+
"description": "Response containing the database connection string",
|
|
18838
|
+
"properties": {
|
|
18839
|
+
"connection_string": {
|
|
18840
|
+
"type": "string",
|
|
18841
|
+
"description": "The connection string for the database"
|
|
18842
|
+
}
|
|
18843
|
+
}
|
|
18844
|
+
},
|
|
18845
|
+
"createDatabaseBranchRequest": {
|
|
18846
|
+
"type": "object",
|
|
18847
|
+
"description": "Request body for creating a database branch",
|
|
18848
|
+
"required": [
|
|
18849
|
+
"branch_id"
|
|
18850
|
+
],
|
|
18851
|
+
"properties": {
|
|
18852
|
+
"parent_branch_id": {
|
|
18853
|
+
"type": "string",
|
|
18854
|
+
"description": "The ID of the parent branch to create the new branch from. Defaults to the production branch if not specified."
|
|
18855
|
+
},
|
|
18856
|
+
"branch_id": {
|
|
18857
|
+
"type": "string",
|
|
18858
|
+
"description": "The branch identifier"
|
|
18859
|
+
},
|
|
18860
|
+
"metadata": {
|
|
18861
|
+
"type": "object",
|
|
18862
|
+
"description": "Arbitrary metadata to associate with the branch",
|
|
18863
|
+
"additionalProperties": true
|
|
18864
|
+
}
|
|
18865
|
+
}
|
|
18866
|
+
},
|
|
18867
|
+
"databaseBranchResponse": {
|
|
18868
|
+
"type": "object",
|
|
18869
|
+
"description": "Response containing the database branch connection string",
|
|
18870
|
+
"properties": {
|
|
18871
|
+
"connection_string": {
|
|
18872
|
+
"type": "string",
|
|
18873
|
+
"description": "The connection string for the database branch"
|
|
18874
|
+
},
|
|
18875
|
+
"metadata": {
|
|
18876
|
+
"type": "object",
|
|
18877
|
+
"description": "Metadata associated with the branch",
|
|
18878
|
+
"additionalProperties": true
|
|
18879
|
+
}
|
|
18880
|
+
}
|
|
18881
|
+
},
|
|
18882
|
+
"databaseBranchesResponse": {
|
|
18883
|
+
"type": "object",
|
|
18884
|
+
"description": "Response containing a list of database branches",
|
|
18885
|
+
"properties": {
|
|
18886
|
+
"branches": {
|
|
18887
|
+
"type": "array",
|
|
18888
|
+
"items": {
|
|
18889
|
+
"type": "object",
|
|
18890
|
+
"description": "Detailed information about a database branch",
|
|
18891
|
+
"properties": {
|
|
18892
|
+
"branch_id": {
|
|
18893
|
+
"type": "string",
|
|
18894
|
+
"description": "The branch identifier"
|
|
18895
|
+
},
|
|
18896
|
+
"name": {
|
|
18897
|
+
"type": "string",
|
|
18898
|
+
"description": "The branch name"
|
|
18899
|
+
},
|
|
18900
|
+
"connection_string": {
|
|
18901
|
+
"type": "string",
|
|
18902
|
+
"description": "The connection string for the branch"
|
|
18903
|
+
},
|
|
18904
|
+
"state": {
|
|
18905
|
+
"type": "string",
|
|
18906
|
+
"description": "The current state of the branch",
|
|
18907
|
+
"enum": [
|
|
18908
|
+
"init",
|
|
18909
|
+
"creating",
|
|
18910
|
+
"resetting",
|
|
18911
|
+
"ready",
|
|
18912
|
+
"archived"
|
|
18913
|
+
]
|
|
18914
|
+
},
|
|
18915
|
+
"logical_size_bytes": {
|
|
18916
|
+
"type": "integer",
|
|
18917
|
+
"format": "int64",
|
|
18918
|
+
"description": "The logical size of the branch in bytes"
|
|
18919
|
+
},
|
|
18920
|
+
"created_at": {
|
|
18921
|
+
"type": "string",
|
|
18922
|
+
"format": "dateTime",
|
|
18923
|
+
"description": "When the branch was created"
|
|
18924
|
+
},
|
|
18925
|
+
"updated_at": {
|
|
18926
|
+
"type": "string",
|
|
18927
|
+
"format": "dateTime",
|
|
18928
|
+
"description": "When the branch was last updated"
|
|
18929
|
+
},
|
|
18930
|
+
"last_active_at": {
|
|
18931
|
+
"type": "string",
|
|
18932
|
+
"format": "dateTime",
|
|
18933
|
+
"description": "When the branch was last active"
|
|
18934
|
+
},
|
|
18935
|
+
"compute": {
|
|
18936
|
+
"type": "object",
|
|
18937
|
+
"description": "Compute endpoint status for a branch",
|
|
18938
|
+
"properties": {
|
|
18939
|
+
"current_state": {
|
|
18940
|
+
"type": "string",
|
|
18941
|
+
"description": "The current state of the compute endpoint",
|
|
18942
|
+
"enum": [
|
|
18943
|
+
"active",
|
|
18944
|
+
"idle"
|
|
18945
|
+
]
|
|
18946
|
+
},
|
|
18947
|
+
"autoscaling_limit_min_cu": {
|
|
18948
|
+
"type": "number",
|
|
18949
|
+
"format": "double",
|
|
18950
|
+
"description": "Minimum compute units for autoscaling"
|
|
18951
|
+
},
|
|
18952
|
+
"autoscaling_limit_max_cu": {
|
|
18953
|
+
"type": "number",
|
|
18954
|
+
"format": "double",
|
|
18955
|
+
"description": "Maximum compute units for autoscaling"
|
|
18956
|
+
},
|
|
18957
|
+
"suspend_timeout_seconds": {
|
|
18958
|
+
"type": "integer",
|
|
18959
|
+
"format": "int64",
|
|
18960
|
+
"description": "Seconds of inactivity before the compute endpoint is suspended"
|
|
18961
|
+
},
|
|
18962
|
+
"last_active": {
|
|
18963
|
+
"type": "string",
|
|
18964
|
+
"format": "dateTime",
|
|
18965
|
+
"description": "When the compute endpoint was last active"
|
|
18966
|
+
}
|
|
17888
18967
|
}
|
|
18968
|
+
},
|
|
18969
|
+
"metadata": {
|
|
18970
|
+
"type": "object",
|
|
18971
|
+
"description": "Metadata associated with the branch",
|
|
18972
|
+
"additionalProperties": true
|
|
17889
18973
|
}
|
|
17890
18974
|
}
|
|
17891
|
-
}
|
|
17892
|
-
],
|
|
17893
|
-
"responses": {
|
|
17894
|
-
"200": {
|
|
17895
|
-
"description": "OK"
|
|
17896
18975
|
},
|
|
17897
|
-
"
|
|
17898
|
-
"description": "error",
|
|
17899
|
-
"schema": {
|
|
17900
|
-
"type": "object",
|
|
17901
|
-
"required": [
|
|
17902
|
-
"message"
|
|
17903
|
-
],
|
|
17904
|
-
"properties": {
|
|
17905
|
-
"code": {
|
|
17906
|
-
"type": "integer",
|
|
17907
|
-
"format": "int64"
|
|
17908
|
-
},
|
|
17909
|
-
"message": {
|
|
17910
|
-
"type": "string",
|
|
17911
|
-
"x-nullable": false
|
|
17912
|
-
}
|
|
17913
|
-
}
|
|
17914
|
-
}
|
|
17915
|
-
}
|
|
17916
|
-
}
|
|
17917
|
-
}
|
|
17918
|
-
}
|
|
17919
|
-
},
|
|
17920
|
-
"definitions": {
|
|
17921
|
-
"createDatabaseRequest": {
|
|
17922
|
-
"type": "object",
|
|
17923
|
-
"description": "Request body for creating a database",
|
|
17924
|
-
"properties": {
|
|
17925
|
-
"region": {
|
|
17926
|
-
"type": "string",
|
|
17927
|
-
"description": "The region where the database should be created. Defaults to the site's functions region if not specified."
|
|
18976
|
+
"description": "List of database branches"
|
|
17928
18977
|
}
|
|
17929
18978
|
}
|
|
17930
18979
|
},
|
|
17931
|
-
"
|
|
18980
|
+
"databaseBranchDetail": {
|
|
17932
18981
|
"type": "object",
|
|
17933
|
-
"description": "
|
|
18982
|
+
"description": "Detailed information about a database branch",
|
|
17934
18983
|
"properties": {
|
|
18984
|
+
"branch_id": {
|
|
18985
|
+
"type": "string",
|
|
18986
|
+
"description": "The branch identifier"
|
|
18987
|
+
},
|
|
18988
|
+
"name": {
|
|
18989
|
+
"type": "string",
|
|
18990
|
+
"description": "The branch name"
|
|
18991
|
+
},
|
|
17935
18992
|
"connection_string": {
|
|
17936
18993
|
"type": "string",
|
|
17937
|
-
"description": "The connection string for the
|
|
17938
|
-
}
|
|
17939
|
-
|
|
17940
|
-
},
|
|
17941
|
-
"createDatabaseBranchRequest": {
|
|
17942
|
-
"type": "object",
|
|
17943
|
-
"description": "Request body for creating a database branch",
|
|
17944
|
-
"required": [
|
|
17945
|
-
"deploy_id"
|
|
17946
|
-
],
|
|
17947
|
-
"properties": {
|
|
17948
|
-
"parent_branch_id": {
|
|
18994
|
+
"description": "The connection string for the branch"
|
|
18995
|
+
},
|
|
18996
|
+
"state": {
|
|
17949
18997
|
"type": "string",
|
|
17950
|
-
"description": "The
|
|
18998
|
+
"description": "The current state of the branch",
|
|
18999
|
+
"enum": [
|
|
19000
|
+
"init",
|
|
19001
|
+
"creating",
|
|
19002
|
+
"resetting",
|
|
19003
|
+
"ready",
|
|
19004
|
+
"archived"
|
|
19005
|
+
]
|
|
17951
19006
|
},
|
|
17952
|
-
"
|
|
19007
|
+
"logical_size_bytes": {
|
|
19008
|
+
"type": "integer",
|
|
19009
|
+
"format": "int64",
|
|
19010
|
+
"description": "The logical size of the branch in bytes"
|
|
19011
|
+
},
|
|
19012
|
+
"created_at": {
|
|
19013
|
+
"type": "string",
|
|
19014
|
+
"format": "dateTime",
|
|
19015
|
+
"description": "When the branch was created"
|
|
19016
|
+
},
|
|
19017
|
+
"updated_at": {
|
|
19018
|
+
"type": "string",
|
|
19019
|
+
"format": "dateTime",
|
|
19020
|
+
"description": "When the branch was last updated"
|
|
19021
|
+
},
|
|
19022
|
+
"last_active_at": {
|
|
17953
19023
|
"type": "string",
|
|
17954
|
-
"
|
|
19024
|
+
"format": "dateTime",
|
|
19025
|
+
"description": "When the branch was last active"
|
|
19026
|
+
},
|
|
19027
|
+
"compute": {
|
|
19028
|
+
"type": "object",
|
|
19029
|
+
"description": "Compute endpoint status for a branch",
|
|
19030
|
+
"properties": {
|
|
19031
|
+
"current_state": {
|
|
19032
|
+
"type": "string",
|
|
19033
|
+
"description": "The current state of the compute endpoint",
|
|
19034
|
+
"enum": [
|
|
19035
|
+
"active",
|
|
19036
|
+
"idle"
|
|
19037
|
+
]
|
|
19038
|
+
},
|
|
19039
|
+
"autoscaling_limit_min_cu": {
|
|
19040
|
+
"type": "number",
|
|
19041
|
+
"format": "double",
|
|
19042
|
+
"description": "Minimum compute units for autoscaling"
|
|
19043
|
+
},
|
|
19044
|
+
"autoscaling_limit_max_cu": {
|
|
19045
|
+
"type": "number",
|
|
19046
|
+
"format": "double",
|
|
19047
|
+
"description": "Maximum compute units for autoscaling"
|
|
19048
|
+
},
|
|
19049
|
+
"suspend_timeout_seconds": {
|
|
19050
|
+
"type": "integer",
|
|
19051
|
+
"format": "int64",
|
|
19052
|
+
"description": "Seconds of inactivity before the compute endpoint is suspended"
|
|
19053
|
+
},
|
|
19054
|
+
"last_active": {
|
|
19055
|
+
"type": "string",
|
|
19056
|
+
"format": "dateTime",
|
|
19057
|
+
"description": "When the compute endpoint was last active"
|
|
19058
|
+
}
|
|
19059
|
+
}
|
|
19060
|
+
},
|
|
19061
|
+
"metadata": {
|
|
19062
|
+
"type": "object",
|
|
19063
|
+
"description": "Metadata associated with the branch",
|
|
19064
|
+
"additionalProperties": true
|
|
17955
19065
|
}
|
|
17956
19066
|
}
|
|
17957
19067
|
},
|
|
17958
|
-
"
|
|
19068
|
+
"databaseBranchCompute": {
|
|
17959
19069
|
"type": "object",
|
|
17960
|
-
"description": "
|
|
19070
|
+
"description": "Compute endpoint status for a branch",
|
|
17961
19071
|
"properties": {
|
|
17962
|
-
"
|
|
19072
|
+
"current_state": {
|
|
17963
19073
|
"type": "string",
|
|
17964
|
-
"description": "The
|
|
19074
|
+
"description": "The current state of the compute endpoint",
|
|
19075
|
+
"enum": [
|
|
19076
|
+
"active",
|
|
19077
|
+
"idle"
|
|
19078
|
+
]
|
|
19079
|
+
},
|
|
19080
|
+
"autoscaling_limit_min_cu": {
|
|
19081
|
+
"type": "number",
|
|
19082
|
+
"format": "double",
|
|
19083
|
+
"description": "Minimum compute units for autoscaling"
|
|
19084
|
+
},
|
|
19085
|
+
"autoscaling_limit_max_cu": {
|
|
19086
|
+
"type": "number",
|
|
19087
|
+
"format": "double",
|
|
19088
|
+
"description": "Maximum compute units for autoscaling"
|
|
19089
|
+
},
|
|
19090
|
+
"suspend_timeout_seconds": {
|
|
19091
|
+
"type": "integer",
|
|
19092
|
+
"format": "int64",
|
|
19093
|
+
"description": "Seconds of inactivity before the compute endpoint is suspended"
|
|
19094
|
+
},
|
|
19095
|
+
"last_active": {
|
|
19096
|
+
"type": "string",
|
|
19097
|
+
"format": "dateTime",
|
|
19098
|
+
"description": "When the compute endpoint was last active"
|
|
17965
19099
|
}
|
|
17966
19100
|
}
|
|
17967
19101
|
},
|
|
@@ -17969,13 +19103,28 @@
|
|
|
17969
19103
|
"type": "object",
|
|
17970
19104
|
"description": "Request body for creating a database snapshot",
|
|
17971
19105
|
"properties": {
|
|
17972
|
-
"
|
|
19106
|
+
"branch_id": {
|
|
17973
19107
|
"type": "string",
|
|
17974
|
-
"description": "The
|
|
19108
|
+
"description": "The ID of the branch to snapshot. Defaults to \"production\" if not specified."
|
|
17975
19109
|
},
|
|
17976
19110
|
"name": {
|
|
17977
19111
|
"type": "string",
|
|
17978
|
-
"description": "
|
|
19112
|
+
"description": "A name for the snapshot"
|
|
19113
|
+
},
|
|
19114
|
+
"metadata": {
|
|
19115
|
+
"type": "object",
|
|
19116
|
+
"description": "Metadata associated with a snapshot",
|
|
19117
|
+
"properties": {
|
|
19118
|
+
"deploy": {
|
|
19119
|
+
"type": "object",
|
|
19120
|
+
"description": "Deploy information associated with the snapshot",
|
|
19121
|
+
"additionalProperties": true
|
|
19122
|
+
},
|
|
19123
|
+
"source": {
|
|
19124
|
+
"type": "string",
|
|
19125
|
+
"description": "The source that created the snapshot"
|
|
19126
|
+
}
|
|
19127
|
+
}
|
|
17979
19128
|
}
|
|
17980
19129
|
}
|
|
17981
19130
|
},
|
|
@@ -17987,14 +19136,58 @@
|
|
|
17987
19136
|
"type": "string",
|
|
17988
19137
|
"description": "The unique identifier of the snapshot"
|
|
17989
19138
|
},
|
|
19139
|
+
"source_branch_id": {
|
|
19140
|
+
"type": "string",
|
|
19141
|
+
"description": "The ID of the branch that was snapshotted"
|
|
19142
|
+
},
|
|
19143
|
+
"manual": {
|
|
19144
|
+
"type": "boolean",
|
|
19145
|
+
"description": "Whether this snapshot was manually created"
|
|
19146
|
+
},
|
|
19147
|
+
"created_at": {
|
|
19148
|
+
"type": "string",
|
|
19149
|
+
"format": "dateTime",
|
|
19150
|
+
"description": "When the snapshot was created"
|
|
19151
|
+
},
|
|
19152
|
+
"expires_at": {
|
|
19153
|
+
"type": "string",
|
|
19154
|
+
"format": "dateTime",
|
|
19155
|
+
"description": "When the snapshot expires"
|
|
19156
|
+
},
|
|
17990
19157
|
"timestamp": {
|
|
17991
19158
|
"type": "string",
|
|
17992
19159
|
"format": "dateTime",
|
|
17993
|
-
"description": "The timestamp
|
|
19160
|
+
"description": "The point-in-time timestamp of the snapshot"
|
|
17994
19161
|
},
|
|
17995
|
-
"
|
|
19162
|
+
"metadata": {
|
|
19163
|
+
"type": "object",
|
|
19164
|
+
"description": "Metadata associated with a snapshot",
|
|
19165
|
+
"properties": {
|
|
19166
|
+
"deploy": {
|
|
19167
|
+
"type": "object",
|
|
19168
|
+
"description": "Deploy information associated with the snapshot",
|
|
19169
|
+
"additionalProperties": true
|
|
19170
|
+
},
|
|
19171
|
+
"source": {
|
|
19172
|
+
"type": "string",
|
|
19173
|
+
"description": "The source that created the snapshot"
|
|
19174
|
+
}
|
|
19175
|
+
}
|
|
19176
|
+
}
|
|
19177
|
+
}
|
|
19178
|
+
},
|
|
19179
|
+
"databaseSnapshotMetadata": {
|
|
19180
|
+
"type": "object",
|
|
19181
|
+
"description": "Metadata associated with a snapshot",
|
|
19182
|
+
"properties": {
|
|
19183
|
+
"deploy": {
|
|
19184
|
+
"type": "object",
|
|
19185
|
+
"description": "Deploy information associated with the snapshot",
|
|
19186
|
+
"additionalProperties": true
|
|
19187
|
+
},
|
|
19188
|
+
"source": {
|
|
17996
19189
|
"type": "string",
|
|
17997
|
-
"description": "The
|
|
19190
|
+
"description": "The source that created the snapshot"
|
|
17998
19191
|
}
|
|
17999
19192
|
}
|
|
18000
19193
|
},
|
|
@@ -18012,14 +19205,43 @@
|
|
|
18012
19205
|
"type": "string",
|
|
18013
19206
|
"description": "The unique identifier of the snapshot"
|
|
18014
19207
|
},
|
|
18015
|
-
"
|
|
19208
|
+
"source_branch_id": {
|
|
19209
|
+
"type": "string",
|
|
19210
|
+
"description": "The ID of the branch that was snapshotted"
|
|
19211
|
+
},
|
|
19212
|
+
"manual": {
|
|
19213
|
+
"type": "boolean",
|
|
19214
|
+
"description": "Whether this snapshot was manually created"
|
|
19215
|
+
},
|
|
19216
|
+
"created_at": {
|
|
18016
19217
|
"type": "string",
|
|
18017
19218
|
"format": "dateTime",
|
|
18018
|
-
"description": "
|
|
19219
|
+
"description": "When the snapshot was created"
|
|
18019
19220
|
},
|
|
18020
|
-
"
|
|
19221
|
+
"expires_at": {
|
|
18021
19222
|
"type": "string",
|
|
18022
|
-
"
|
|
19223
|
+
"format": "dateTime",
|
|
19224
|
+
"description": "When the snapshot expires"
|
|
19225
|
+
},
|
|
19226
|
+
"timestamp": {
|
|
19227
|
+
"type": "string",
|
|
19228
|
+
"format": "dateTime",
|
|
19229
|
+
"description": "The point-in-time timestamp of the snapshot"
|
|
19230
|
+
},
|
|
19231
|
+
"metadata": {
|
|
19232
|
+
"type": "object",
|
|
19233
|
+
"description": "Metadata associated with a snapshot",
|
|
19234
|
+
"properties": {
|
|
19235
|
+
"deploy": {
|
|
19236
|
+
"type": "object",
|
|
19237
|
+
"description": "Deploy information associated with the snapshot",
|
|
19238
|
+
"additionalProperties": true
|
|
19239
|
+
},
|
|
19240
|
+
"source": {
|
|
19241
|
+
"type": "string",
|
|
19242
|
+
"description": "The source that created the snapshot"
|
|
19243
|
+
}
|
|
19244
|
+
}
|
|
18023
19245
|
}
|
|
18024
19246
|
}
|
|
18025
19247
|
},
|
|
@@ -18031,9 +19253,177 @@
|
|
|
18031
19253
|
"type": "object",
|
|
18032
19254
|
"description": "Request body for restoring a database snapshot",
|
|
18033
19255
|
"properties": {
|
|
18034
|
-
"
|
|
19256
|
+
"branch_id": {
|
|
19257
|
+
"type": "string",
|
|
19258
|
+
"description": "The ID of the branch to restore the snapshot to. Defaults to \"production\" if not specified."
|
|
19259
|
+
}
|
|
19260
|
+
}
|
|
19261
|
+
},
|
|
19262
|
+
"databaseComputeSettingsRequest": {
|
|
19263
|
+
"type": "object",
|
|
19264
|
+
"description": "Request body for setting compute settings. All fields are optional; only provided fields are updated.",
|
|
19265
|
+
"properties": {
|
|
19266
|
+
"min_cu": {
|
|
19267
|
+
"type": "number",
|
|
19268
|
+
"format": "double",
|
|
19269
|
+
"minimum": 0.25,
|
|
19270
|
+
"maximum": 16,
|
|
19271
|
+
"x-nullable": true,
|
|
19272
|
+
"description": "Minimum compute units (0.25 to 16.0). Must be less than or equal to max_cu."
|
|
19273
|
+
},
|
|
19274
|
+
"max_cu": {
|
|
19275
|
+
"type": "number",
|
|
19276
|
+
"format": "double",
|
|
19277
|
+
"minimum": 0.25,
|
|
19278
|
+
"maximum": 16,
|
|
19279
|
+
"x-nullable": true,
|
|
19280
|
+
"description": "Maximum compute units (0.25 to 16.0). Must be greater than or equal to min_cu. max_cu - min_cu must not exceed 8.0."
|
|
19281
|
+
},
|
|
19282
|
+
"sleep_timeout_seconds": {
|
|
19283
|
+
"type": "integer",
|
|
19284
|
+
"format": "int64",
|
|
19285
|
+
"minimum": -1,
|
|
19286
|
+
"x-nullable": true,
|
|
19287
|
+
"description": "Seconds of inactivity before the compute endpoint is suspended. Use -1 for always on, or a non-negative value."
|
|
19288
|
+
}
|
|
19289
|
+
}
|
|
19290
|
+
},
|
|
19291
|
+
"databaseComputeSettings": {
|
|
19292
|
+
"type": "object",
|
|
19293
|
+
"description": "Compute settings for a database or branch",
|
|
19294
|
+
"properties": {
|
|
19295
|
+
"min_cu": {
|
|
19296
|
+
"type": "number",
|
|
19297
|
+
"format": "double",
|
|
19298
|
+
"description": "Minimum compute units"
|
|
19299
|
+
},
|
|
19300
|
+
"max_cu": {
|
|
19301
|
+
"type": "number",
|
|
19302
|
+
"format": "double",
|
|
19303
|
+
"description": "Maximum compute units"
|
|
19304
|
+
},
|
|
19305
|
+
"sleep_timeout_seconds": {
|
|
19306
|
+
"type": "integer",
|
|
19307
|
+
"format": "int64",
|
|
19308
|
+
"description": "Seconds of inactivity before suspension"
|
|
19309
|
+
}
|
|
19310
|
+
}
|
|
19311
|
+
},
|
|
19312
|
+
"runDatabaseMigrationsRequest": {
|
|
19313
|
+
"type": "object",
|
|
19314
|
+
"description": "Request body for running database migrations",
|
|
19315
|
+
"properties": {
|
|
19316
|
+
"dry_run": {
|
|
19317
|
+
"type": "boolean",
|
|
19318
|
+
"description": "If true, validates migrations without applying them."
|
|
19319
|
+
}
|
|
19320
|
+
}
|
|
19321
|
+
},
|
|
19322
|
+
"resetDatabaseBranchRequest": {
|
|
19323
|
+
"type": "object",
|
|
19324
|
+
"description": "Request body for resetting a database branch",
|
|
19325
|
+
"properties": {
|
|
19326
|
+
"source_branch_id": {
|
|
19327
|
+
"type": "string",
|
|
19328
|
+
"description": "The ID of the branch to re-fork the target branch from. Defaults to \"production\" if not specified."
|
|
19329
|
+
}
|
|
19330
|
+
}
|
|
19331
|
+
},
|
|
19332
|
+
"resetDatabaseBranchResponse": {
|
|
19333
|
+
"type": "object",
|
|
19334
|
+
"description": "Response for a database branch reset",
|
|
19335
|
+
"properties": {
|
|
19336
|
+
"reset": {
|
|
19337
|
+
"type": "boolean",
|
|
19338
|
+
"description": "Whether the branch was actually re-forked. False when the target was already in sync with the source and `force=true` was not set."
|
|
19339
|
+
},
|
|
19340
|
+
"connection_string": {
|
|
19341
|
+
"type": "string",
|
|
19342
|
+
"description": "The connection string for the reset (or unchanged) branch"
|
|
19343
|
+
},
|
|
19344
|
+
"metadata": {
|
|
19345
|
+
"type": "object",
|
|
19346
|
+
"description": "Metadata associated with the branch",
|
|
19347
|
+
"additionalProperties": true
|
|
19348
|
+
}
|
|
19349
|
+
}
|
|
19350
|
+
},
|
|
19351
|
+
"listDatabaseMigrationsResponse": {
|
|
19352
|
+
"type": "object",
|
|
19353
|
+
"description": "Response containing the list of migrations for a branch",
|
|
19354
|
+
"properties": {
|
|
19355
|
+
"migrations": {
|
|
19356
|
+
"type": "array",
|
|
19357
|
+
"items": {
|
|
19358
|
+
"type": "object",
|
|
19359
|
+
"description": "A migration available to a database branch",
|
|
19360
|
+
"properties": {
|
|
19361
|
+
"version": {
|
|
19362
|
+
"type": "integer",
|
|
19363
|
+
"format": "int64",
|
|
19364
|
+
"description": "The migration version number"
|
|
19365
|
+
},
|
|
19366
|
+
"name": {
|
|
19367
|
+
"type": "string",
|
|
19368
|
+
"description": "The migration name"
|
|
19369
|
+
},
|
|
19370
|
+
"path": {
|
|
19371
|
+
"type": "string",
|
|
19372
|
+
"description": "The path to the migration file in the deploy bundle"
|
|
19373
|
+
},
|
|
19374
|
+
"applied": {
|
|
19375
|
+
"type": "boolean",
|
|
19376
|
+
"description": "Whether this migration has been applied to the branch"
|
|
19377
|
+
}
|
|
19378
|
+
}
|
|
19379
|
+
},
|
|
19380
|
+
"description": "List of migrations"
|
|
19381
|
+
}
|
|
19382
|
+
}
|
|
19383
|
+
},
|
|
19384
|
+
"databaseMigration": {
|
|
19385
|
+
"type": "object",
|
|
19386
|
+
"description": "A migration available to a database branch",
|
|
19387
|
+
"properties": {
|
|
19388
|
+
"version": {
|
|
19389
|
+
"type": "integer",
|
|
19390
|
+
"format": "int64",
|
|
19391
|
+
"description": "The migration version number"
|
|
19392
|
+
},
|
|
19393
|
+
"name": {
|
|
19394
|
+
"type": "string",
|
|
19395
|
+
"description": "The migration name"
|
|
19396
|
+
},
|
|
19397
|
+
"path": {
|
|
19398
|
+
"type": "string",
|
|
19399
|
+
"description": "The path to the migration file in the deploy bundle"
|
|
19400
|
+
},
|
|
19401
|
+
"applied": {
|
|
19402
|
+
"type": "boolean",
|
|
19403
|
+
"description": "Whether this migration has been applied to the branch"
|
|
19404
|
+
}
|
|
19405
|
+
}
|
|
19406
|
+
},
|
|
19407
|
+
"databaseMigrationDetail": {
|
|
19408
|
+
"type": "object",
|
|
19409
|
+
"description": "A migration with its file contents",
|
|
19410
|
+
"properties": {
|
|
19411
|
+
"version": {
|
|
19412
|
+
"type": "integer",
|
|
19413
|
+
"format": "int64",
|
|
19414
|
+
"description": "The migration version number"
|
|
19415
|
+
},
|
|
19416
|
+
"name": {
|
|
19417
|
+
"type": "string",
|
|
19418
|
+
"description": "The migration name"
|
|
19419
|
+
},
|
|
19420
|
+
"path": {
|
|
19421
|
+
"type": "string",
|
|
19422
|
+
"description": "The path to the migration file in the deploy bundle"
|
|
19423
|
+
},
|
|
19424
|
+
"content": {
|
|
18035
19425
|
"type": "string",
|
|
18036
|
-
"description": "The
|
|
19426
|
+
"description": "The raw contents of the migration file"
|
|
18037
19427
|
}
|
|
18038
19428
|
}
|
|
18039
19429
|
},
|