@amerged/ohmyhost-cli 0.1.54 → 0.1.56
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/README.md +1 -1
- package/dist/bin.js +1 -1
- package/dist/{chunk-ZEKUTE7M.js → chunk-HNFWXGDN.js} +511 -60
- package/dist/index.js +3 -1
- package/package.json +1 -1
- package/src/apps/product-cli/package.json +1 -1
- package/src/apps/product-cli/src/cli.ts +128 -25
- package/src/apps/product-cli/src/command.ts +143 -20
- package/src/apps/product-cli/src/index.ts +1 -0
- package/src/apps/product-cli/src/product-api.ts +75 -2
- package/src/apps/product-cli/src/repository-init.ts +46 -9
- package/src/apps/product-cli/src/runtime-contract.ts +52 -4
- package/src/packages/contracts/package.json +10 -0
- package/src/packages/contracts/src/database-events.ts +1 -0
- package/src/packages/contracts/src/database-migration-admission.ts +33 -3
- package/src/packages/contracts/src/database-migration-errors.ts +10 -2
- package/src/packages/contracts/src/feedback.ts +9 -0
- package/src/packages/contracts/src/framework-admission.ts +4 -0
- package/src/packages/contracts/src/framework-source-rules.ts +55 -0
- package/src/packages/contracts/src/operation-failure.ts +8 -0
- package/src/packages/contracts/src/organization-mcp-connections.ts +7 -0
- package/src/packages/contracts/src/problem-policy.ts +74 -2
- package/src/packages/contracts/src/project-exports.ts +30 -0
- package/src/packages/contracts/src/secret-names.ts +9 -2
- package/src/packages/contracts/src/wfp-dispatch.ts +43 -0
- package/src/packages/sdk-ts/package.json +1 -1
- package/src/packages/sdk-ts/src/generated/index.ts +39 -0
- package/src/packages/sdk-ts/src/generated/sdk.gen.ts +303 -13
- package/src/packages/sdk-ts/src/generated/types.gen.ts +460 -12
- package/src/packages/sdk-ts/src/managed-mail-response.ts +12 -0
- package/src/packages/sdk-ts/src/managed-mail.ts +10 -1
- package/src/packages/workos-auth-contracts/src/webhooks.ts +7 -0
|
@@ -493,10 +493,16 @@ export type CloudflareDnsAuthorization = {
|
|
|
493
493
|
};
|
|
494
494
|
|
|
495
495
|
/**
|
|
496
|
-
* Credential-free project authorization state. Without an authorization, status is not_authorized, zone and expires_at are null, and scopes is empty. All other states name the actual customer zone; no platform or customer zone is inferred.
|
|
496
|
+
* Credential-free project authorization state. Without an authorization, status is not_authorized, zone and expires_at are null, and scopes is empty. When the consenting user no longer holds project write authority, status is reauthorization_required, which names the zone while scopes is empty and expires_at is null until the owner authorizes the zone again. All other states name the actual customer zone; no platform or customer zone is inferred.
|
|
497
497
|
*/
|
|
498
498
|
export type CloudflareDnsAuthorizationStatus = {
|
|
499
|
-
status:
|
|
499
|
+
status:
|
|
500
|
+
| "not_authorized"
|
|
501
|
+
| "pending"
|
|
502
|
+
| "authorized"
|
|
503
|
+
| "reauthorization_required"
|
|
504
|
+
| "expired"
|
|
505
|
+
| "revoked";
|
|
500
506
|
zone: string | null;
|
|
501
507
|
scopes: Array<"dns.write" | "zone.read">;
|
|
502
508
|
expires_at: string | null;
|
|
@@ -516,7 +522,7 @@ export type PaidDomainPlan = {
|
|
|
516
522
|
};
|
|
517
523
|
|
|
518
524
|
/**
|
|
519
|
-
* awaiting_deployment means the requested hostname is declared but not provisioned. Its hostname is present, suspension_reason, custom_hostname_status, ssl_status and url are null, and
|
|
525
|
+
* awaiting_deployment means the requested hostname is declared but not provisioned. Its hostname is present, suspension_reason, custom_hostname_status, ssl_status and url are null. validation_records holds only the _omh-project TXT ownership record while the hostname is not yet proven, and is empty once it is proven. Publish that record, authorize Cloudflare, deploy to Prod, then repeat the same apply.
|
|
520
526
|
*/
|
|
521
527
|
export type PaidDomain = {
|
|
522
528
|
status:
|
|
@@ -643,6 +649,21 @@ export type GithubOrganizationConnectionStatus = {
|
|
|
643
649
|
connection: GithubOrganizationConnection | null;
|
|
644
650
|
};
|
|
645
651
|
|
|
652
|
+
export type OrganizationMcpConnection = {
|
|
653
|
+
connection_id: string;
|
|
654
|
+
client_id: string;
|
|
655
|
+
user_id: string;
|
|
656
|
+
connected_at: string;
|
|
657
|
+
};
|
|
658
|
+
|
|
659
|
+
export type OrganizationMcpConnectionList = {
|
|
660
|
+
connections: Array<OrganizationMcpConnection>;
|
|
661
|
+
};
|
|
662
|
+
|
|
663
|
+
export type OrganizationMcpConnectionRevocation = {
|
|
664
|
+
state: "pending" | "revoked";
|
|
665
|
+
};
|
|
666
|
+
|
|
646
667
|
export type GithubConnectionAuthorization = {
|
|
647
668
|
authorization_id: string | null;
|
|
648
669
|
status: "pending" | "authorizing" | "connected" | "failed" | "expired";
|
|
@@ -878,7 +899,7 @@ export type FunctionRun = {
|
|
|
878
899
|
deployment_id: Ulid;
|
|
879
900
|
cron: string;
|
|
880
901
|
scheduled_at: string;
|
|
881
|
-
state: "due" | "running" | "retry" | "succeeded" | "failed";
|
|
902
|
+
state: "due" | "running" | "retry" | "succeeded" | "failed" | "skipped";
|
|
882
903
|
attempt: number;
|
|
883
904
|
status_code: number | null;
|
|
884
905
|
started_at: string | null;
|
|
@@ -1180,6 +1201,9 @@ export type DatabaseWebhookCreateRequest = {
|
|
|
1180
1201
|
export type DatabaseWebhook = {
|
|
1181
1202
|
id: string;
|
|
1182
1203
|
environment: "dev" | "prod";
|
|
1204
|
+
/**
|
|
1205
|
+
* The receiver URL. Callers without projects:write receive only its origin, because the path or query may carry the receiver's credential.
|
|
1206
|
+
*/
|
|
1183
1207
|
url: string;
|
|
1184
1208
|
event_types: Array<DatabaseWebhookEventPattern>;
|
|
1185
1209
|
/**
|
|
@@ -1782,6 +1806,7 @@ export type ProblemDetails = {
|
|
|
1782
1806
|
| "promotion_target_stale"
|
|
1783
1807
|
| "promotion_invalid_target"
|
|
1784
1808
|
| "mail_domain_conflict"
|
|
1809
|
+
| "mail_domain_pending_limit"
|
|
1785
1810
|
| "mail_domain_required"
|
|
1786
1811
|
| "mail_capacity_unavailable"
|
|
1787
1812
|
| "storage_jurisdiction_conflict"
|
|
@@ -1796,8 +1821,10 @@ export type ProblemDetails = {
|
|
|
1796
1821
|
| "project_handle_taken"
|
|
1797
1822
|
| "project_handle_unchanged"
|
|
1798
1823
|
| "project_rename_blocked"
|
|
1824
|
+
| "database_limit_reached"
|
|
1799
1825
|
| "payload_too_large"
|
|
1800
1826
|
| "rate_limited"
|
|
1827
|
+
| "build_capacity_reached"
|
|
1801
1828
|
| "insufficient_organization_credits"
|
|
1802
1829
|
| "paid_plan_required"
|
|
1803
1830
|
| "project_budget_exceeded"
|
|
@@ -1834,16 +1861,23 @@ export type ProblemDetails = {
|
|
|
1834
1861
|
| "api_key_creation_uncertain"
|
|
1835
1862
|
| "api_key_permissions_unavailable"
|
|
1836
1863
|
| "reconciliation_exhausted"
|
|
1864
|
+
| "reconciliation_not_pending"
|
|
1837
1865
|
| "service_unavailable"
|
|
1838
1866
|
| "source_commit_not_found"
|
|
1839
1867
|
| "domain_hostname_taken"
|
|
1868
|
+
| "domain_ownership_required"
|
|
1840
1869
|
| "domain_dns_conflict"
|
|
1841
1870
|
| "data_change_blocked"
|
|
1842
1871
|
| "data_change_in_progress"
|
|
1843
1872
|
| "data_change_not_applicable"
|
|
1844
1873
|
| "rollback_target_data_changed"
|
|
1845
1874
|
| "project_domain_delete_required"
|
|
1846
|
-
| "native_domain_sync_pending"
|
|
1875
|
+
| "native_domain_sync_pending"
|
|
1876
|
+
| "native_auth_launch_unavailable"
|
|
1877
|
+
| "native_auth_provider_unavailable"
|
|
1878
|
+
| "native_auth_epoch_exhausted"
|
|
1879
|
+
| "native_user_conflict"
|
|
1880
|
+
| "project_domains_conflict";
|
|
1847
1881
|
request_id: string;
|
|
1848
1882
|
retryable: boolean;
|
|
1849
1883
|
/**
|
|
@@ -2060,7 +2094,9 @@ export type OperationFailure = {
|
|
|
2060
2094
|
| "provider_state_absent"
|
|
2061
2095
|
| "auto_deploy_plan_rejected"
|
|
2062
2096
|
| "promotion_source_stale"
|
|
2063
|
-
| "promotion_target_stale"
|
|
2097
|
+
| "promotion_target_stale"
|
|
2098
|
+
| "project_handle_taken"
|
|
2099
|
+
| "managed_source_dispatch_failed";
|
|
2064
2100
|
message: string;
|
|
2065
2101
|
/**
|
|
2066
2102
|
* A terminal operation cannot be retried in place; follow suggested_action.
|
|
@@ -4482,6 +4518,61 @@ export type ConnectGithubOrganizationResponses = {
|
|
|
4482
4518
|
export type ConnectGithubOrganizationResponse =
|
|
4483
4519
|
ConnectGithubOrganizationResponses[keyof ConnectGithubOrganizationResponses];
|
|
4484
4520
|
|
|
4521
|
+
export type DisconnectGithubOrganizationData = {
|
|
4522
|
+
body?: never;
|
|
4523
|
+
headers?: {
|
|
4524
|
+
/**
|
|
4525
|
+
* Optional caller-provided correlation identifier.
|
|
4526
|
+
*/
|
|
4527
|
+
"X-Request-Id"?: string;
|
|
4528
|
+
};
|
|
4529
|
+
path: {
|
|
4530
|
+
organization_id: Ulid;
|
|
4531
|
+
};
|
|
4532
|
+
query?: never;
|
|
4533
|
+
url: "/v1/organizations/{organization_id}/github";
|
|
4534
|
+
};
|
|
4535
|
+
|
|
4536
|
+
export type DisconnectGithubOrganizationErrors = {
|
|
4537
|
+
/**
|
|
4538
|
+
* The request failed.
|
|
4539
|
+
*/
|
|
4540
|
+
400: ProblemDetails;
|
|
4541
|
+
/**
|
|
4542
|
+
* The request failed.
|
|
4543
|
+
*/
|
|
4544
|
+
401: ProblemDetails;
|
|
4545
|
+
/**
|
|
4546
|
+
* The request failed.
|
|
4547
|
+
*/
|
|
4548
|
+
403: ProblemDetails;
|
|
4549
|
+
/**
|
|
4550
|
+
* The resource does not exist or is not visible to the authenticated principal.
|
|
4551
|
+
*/
|
|
4552
|
+
404: ProblemDetails;
|
|
4553
|
+
/**
|
|
4554
|
+
* The request failed.
|
|
4555
|
+
*/
|
|
4556
|
+
429: ProblemDetails;
|
|
4557
|
+
/**
|
|
4558
|
+
* The request failed.
|
|
4559
|
+
*/
|
|
4560
|
+
503: ProblemDetails;
|
|
4561
|
+
};
|
|
4562
|
+
|
|
4563
|
+
export type DisconnectGithubOrganizationError =
|
|
4564
|
+
DisconnectGithubOrganizationErrors[keyof DisconnectGithubOrganizationErrors];
|
|
4565
|
+
|
|
4566
|
+
export type DisconnectGithubOrganizationResponses = {
|
|
4567
|
+
/**
|
|
4568
|
+
* The connection after disconnect, revoked or not connected.
|
|
4569
|
+
*/
|
|
4570
|
+
200: GithubOrganizationConnectionStatus;
|
|
4571
|
+
};
|
|
4572
|
+
|
|
4573
|
+
export type DisconnectGithubOrganizationResponse =
|
|
4574
|
+
DisconnectGithubOrganizationResponses[keyof DisconnectGithubOrganizationResponses];
|
|
4575
|
+
|
|
4485
4576
|
export type GetGithubOrganizationConnectionData = {
|
|
4486
4577
|
body?: never;
|
|
4487
4578
|
headers?: {
|
|
@@ -4537,6 +4628,117 @@ export type GetGithubOrganizationConnectionResponses = {
|
|
|
4537
4628
|
export type GetGithubOrganizationConnectionResponse =
|
|
4538
4629
|
GetGithubOrganizationConnectionResponses[keyof GetGithubOrganizationConnectionResponses];
|
|
4539
4630
|
|
|
4631
|
+
export type ListOrganizationMcpConnectionsData = {
|
|
4632
|
+
body?: never;
|
|
4633
|
+
headers?: {
|
|
4634
|
+
/**
|
|
4635
|
+
* Optional caller-provided correlation identifier.
|
|
4636
|
+
*/
|
|
4637
|
+
"X-Request-Id"?: string;
|
|
4638
|
+
};
|
|
4639
|
+
path: {
|
|
4640
|
+
organization_id: Ulid;
|
|
4641
|
+
};
|
|
4642
|
+
query?: never;
|
|
4643
|
+
url: "/v1/organizations/{organization_id}/mcp-connections";
|
|
4644
|
+
};
|
|
4645
|
+
|
|
4646
|
+
export type ListOrganizationMcpConnectionsErrors = {
|
|
4647
|
+
/**
|
|
4648
|
+
* The request failed.
|
|
4649
|
+
*/
|
|
4650
|
+
400: ProblemDetails;
|
|
4651
|
+
/**
|
|
4652
|
+
* The request failed.
|
|
4653
|
+
*/
|
|
4654
|
+
401: ProblemDetails;
|
|
4655
|
+
/**
|
|
4656
|
+
* The request failed.
|
|
4657
|
+
*/
|
|
4658
|
+
403: ProblemDetails;
|
|
4659
|
+
/**
|
|
4660
|
+
* The resource does not exist or is not visible to the authenticated principal.
|
|
4661
|
+
*/
|
|
4662
|
+
404: ProblemDetails;
|
|
4663
|
+
/**
|
|
4664
|
+
* The request failed.
|
|
4665
|
+
*/
|
|
4666
|
+
429: ProblemDetails;
|
|
4667
|
+
/**
|
|
4668
|
+
* The request failed.
|
|
4669
|
+
*/
|
|
4670
|
+
503: ProblemDetails;
|
|
4671
|
+
};
|
|
4672
|
+
|
|
4673
|
+
export type ListOrganizationMcpConnectionsError =
|
|
4674
|
+
ListOrganizationMcpConnectionsErrors[keyof ListOrganizationMcpConnectionsErrors];
|
|
4675
|
+
|
|
4676
|
+
export type ListOrganizationMcpConnectionsResponses = {
|
|
4677
|
+
/**
|
|
4678
|
+
* The live MCP connections of the workspace.
|
|
4679
|
+
*/
|
|
4680
|
+
200: OrganizationMcpConnectionList;
|
|
4681
|
+
};
|
|
4682
|
+
|
|
4683
|
+
export type ListOrganizationMcpConnectionsResponse =
|
|
4684
|
+
ListOrganizationMcpConnectionsResponses[keyof ListOrganizationMcpConnectionsResponses];
|
|
4685
|
+
|
|
4686
|
+
export type RevokeOrganizationMcpConnectionData = {
|
|
4687
|
+
body?: never;
|
|
4688
|
+
headers?: {
|
|
4689
|
+
/**
|
|
4690
|
+
* Optional caller-provided correlation identifier.
|
|
4691
|
+
*/
|
|
4692
|
+
"X-Request-Id"?: string;
|
|
4693
|
+
};
|
|
4694
|
+
path: {
|
|
4695
|
+
organization_id: Ulid;
|
|
4696
|
+
connection_id: string;
|
|
4697
|
+
};
|
|
4698
|
+
query?: never;
|
|
4699
|
+
url: "/v1/organizations/{organization_id}/mcp-connections/{connection_id}";
|
|
4700
|
+
};
|
|
4701
|
+
|
|
4702
|
+
export type RevokeOrganizationMcpConnectionErrors = {
|
|
4703
|
+
/**
|
|
4704
|
+
* The request failed.
|
|
4705
|
+
*/
|
|
4706
|
+
400: ProblemDetails;
|
|
4707
|
+
/**
|
|
4708
|
+
* The request failed.
|
|
4709
|
+
*/
|
|
4710
|
+
401: ProblemDetails;
|
|
4711
|
+
/**
|
|
4712
|
+
* The request failed.
|
|
4713
|
+
*/
|
|
4714
|
+
403: ProblemDetails;
|
|
4715
|
+
/**
|
|
4716
|
+
* The resource does not exist or is not visible to the authenticated principal.
|
|
4717
|
+
*/
|
|
4718
|
+
404: ProblemDetails;
|
|
4719
|
+
/**
|
|
4720
|
+
* The request failed.
|
|
4721
|
+
*/
|
|
4722
|
+
429: ProblemDetails;
|
|
4723
|
+
/**
|
|
4724
|
+
* The request failed.
|
|
4725
|
+
*/
|
|
4726
|
+
503: ProblemDetails;
|
|
4727
|
+
};
|
|
4728
|
+
|
|
4729
|
+
export type RevokeOrganizationMcpConnectionError =
|
|
4730
|
+
RevokeOrganizationMcpConnectionErrors[keyof RevokeOrganizationMcpConnectionErrors];
|
|
4731
|
+
|
|
4732
|
+
export type RevokeOrganizationMcpConnectionResponses = {
|
|
4733
|
+
/**
|
|
4734
|
+
* The disconnect state.
|
|
4735
|
+
*/
|
|
4736
|
+
200: OrganizationMcpConnectionRevocation;
|
|
4737
|
+
};
|
|
4738
|
+
|
|
4739
|
+
export type RevokeOrganizationMcpConnectionResponse =
|
|
4740
|
+
RevokeOrganizationMcpConnectionResponses[keyof RevokeOrganizationMcpConnectionResponses];
|
|
4741
|
+
|
|
4540
4742
|
export type GetOrganizationReferralData = {
|
|
4541
4743
|
body?: never;
|
|
4542
4744
|
headers?: {
|
|
@@ -5149,9 +5351,13 @@ export type CompleteGithubSourceAuthorizationErrors = {
|
|
|
5149
5351
|
*/
|
|
5150
5352
|
400: ProblemDetails;
|
|
5151
5353
|
/**
|
|
5152
|
-
* The authorizing GitHub account lacks the required installation access or account authority.
|
|
5354
|
+
* The authorizing GitHub account lacks the required installation access or account authority. It is also the answer, for a machine client, to an unknown state, to another user's portal session and to a missing portal session; a browser is sent to the unknown-state page instead.
|
|
5153
5355
|
*/
|
|
5154
5356
|
403: ProblemDetails;
|
|
5357
|
+
/**
|
|
5358
|
+
* The request failed.
|
|
5359
|
+
*/
|
|
5360
|
+
409: ProblemDetails;
|
|
5155
5361
|
/**
|
|
5156
5362
|
* The request failed.
|
|
5157
5363
|
*/
|
|
@@ -5183,6 +5389,10 @@ export type CompleteCloudflareDnsAuthorizationErrors = {
|
|
|
5183
5389
|
* The request failed.
|
|
5184
5390
|
*/
|
|
5185
5391
|
400: ProblemDetails;
|
|
5392
|
+
/**
|
|
5393
|
+
* The request failed.
|
|
5394
|
+
*/
|
|
5395
|
+
409: ProblemDetails;
|
|
5186
5396
|
/**
|
|
5187
5397
|
* The request failed.
|
|
5188
5398
|
*/
|
|
@@ -5786,7 +5996,7 @@ export type GetOrganizationCreditUsageResponse =
|
|
|
5786
5996
|
export type CreateProjectExportData = {
|
|
5787
5997
|
body: {
|
|
5788
5998
|
/**
|
|
5789
|
-
*
|
|
5999
|
+
* User-controlled ZIP password of at least 12 characters and at most 1024 UTF-8 bytes, not blank. Never include it in logs or command-line arguments.
|
|
5790
6000
|
*/
|
|
5791
6001
|
password: string;
|
|
5792
6002
|
};
|
|
@@ -5902,6 +6112,70 @@ export type GetProjectExportResponses = {
|
|
|
5902
6112
|
|
|
5903
6113
|
export type GetProjectExportResponse = GetProjectExportResponses[keyof GetProjectExportResponses];
|
|
5904
6114
|
|
|
6115
|
+
export type CreateProjectExportDownloadLinkData = {
|
|
6116
|
+
body?: never;
|
|
6117
|
+
headers?: {
|
|
6118
|
+
/**
|
|
6119
|
+
* Optional caller-provided correlation identifier.
|
|
6120
|
+
*/
|
|
6121
|
+
"X-Request-Id"?: string;
|
|
6122
|
+
};
|
|
6123
|
+
path: {
|
|
6124
|
+
/**
|
|
6125
|
+
* Project identifier.
|
|
6126
|
+
*/
|
|
6127
|
+
project_id: Ulid;
|
|
6128
|
+
export_id: Ulid;
|
|
6129
|
+
};
|
|
6130
|
+
query?: never;
|
|
6131
|
+
url: "/v1/projects/{project_id}/exports/{export_id}/download-links";
|
|
6132
|
+
};
|
|
6133
|
+
|
|
6134
|
+
export type CreateProjectExportDownloadLinkErrors = {
|
|
6135
|
+
/**
|
|
6136
|
+
* The request failed.
|
|
6137
|
+
*/
|
|
6138
|
+
400: ProblemDetails;
|
|
6139
|
+
/**
|
|
6140
|
+
* The request failed.
|
|
6141
|
+
*/
|
|
6142
|
+
401: ProblemDetails;
|
|
6143
|
+
/**
|
|
6144
|
+
* The resource does not exist or is not visible to the authenticated principal.
|
|
6145
|
+
*/
|
|
6146
|
+
404: ProblemDetails;
|
|
6147
|
+
/**
|
|
6148
|
+
* The request failed.
|
|
6149
|
+
*/
|
|
6150
|
+
409: ProblemDetails;
|
|
6151
|
+
/**
|
|
6152
|
+
* The request failed.
|
|
6153
|
+
*/
|
|
6154
|
+
429: ProblemDetails;
|
|
6155
|
+
/**
|
|
6156
|
+
* The request failed.
|
|
6157
|
+
*/
|
|
6158
|
+
503: ProblemDetails;
|
|
6159
|
+
};
|
|
6160
|
+
|
|
6161
|
+
export type CreateProjectExportDownloadLinkError =
|
|
6162
|
+
CreateProjectExportDownloadLinkErrors[keyof CreateProjectExportDownloadLinkErrors];
|
|
6163
|
+
|
|
6164
|
+
export type CreateProjectExportDownloadLinkResponses = {
|
|
6165
|
+
/**
|
|
6166
|
+
* The signed download URL and its expiry.
|
|
6167
|
+
*/
|
|
6168
|
+
200: {
|
|
6169
|
+
id: Ulid;
|
|
6170
|
+
project_id: Ulid;
|
|
6171
|
+
download_url: string;
|
|
6172
|
+
download_expires_at: string;
|
|
6173
|
+
};
|
|
6174
|
+
};
|
|
6175
|
+
|
|
6176
|
+
export type CreateProjectExportDownloadLinkResponse =
|
|
6177
|
+
CreateProjectExportDownloadLinkResponses[keyof CreateProjectExportDownloadLinkResponses];
|
|
6178
|
+
|
|
5905
6179
|
export type GetProjectCreditBudgetData = {
|
|
5906
6180
|
body?: never;
|
|
5907
6181
|
headers?: {
|
|
@@ -6830,6 +7104,10 @@ export type CreateProjectDevAccessTicketData = {
|
|
|
6830
7104
|
* Optional caller-provided correlation identifier.
|
|
6831
7105
|
*/
|
|
6832
7106
|
"X-Request-Id"?: string;
|
|
7107
|
+
/**
|
|
7108
|
+
* Optional and ignored. This route does not replay a stored answer, so a repeated request issues another ticket and revokes the unused one.
|
|
7109
|
+
*/
|
|
7110
|
+
"Idempotency-Key"?: string;
|
|
6833
7111
|
};
|
|
6834
7112
|
path: {
|
|
6835
7113
|
/**
|
|
@@ -9131,6 +9409,10 @@ export type CreateProjectDatabaseAccessData = {
|
|
|
9131
9409
|
* Optional caller-provided correlation identifier.
|
|
9132
9410
|
*/
|
|
9133
9411
|
"X-Request-Id"?: string;
|
|
9412
|
+
/**
|
|
9413
|
+
* Optional and ignored. This route does not replay a stored answer, so a repeated request issues another credential.
|
|
9414
|
+
*/
|
|
9415
|
+
"Idempotency-Key"?: string;
|
|
9134
9416
|
};
|
|
9135
9417
|
path: {
|
|
9136
9418
|
/**
|
|
@@ -9346,6 +9628,10 @@ export type ListProjectDatabaseWatchesErrors = {
|
|
|
9346
9628
|
* The request failed.
|
|
9347
9629
|
*/
|
|
9348
9630
|
401: ProblemDetails;
|
|
9631
|
+
/**
|
|
9632
|
+
* The request failed.
|
|
9633
|
+
*/
|
|
9634
|
+
402: ProblemDetails;
|
|
9349
9635
|
/**
|
|
9350
9636
|
* The resource does not exist or is not visible to the authenticated principal.
|
|
9351
9637
|
*/
|
|
@@ -9638,11 +9924,15 @@ export type CreateProjectDatabaseWebhookResponse =
|
|
|
9638
9924
|
|
|
9639
9925
|
export type DeleteProjectDatabaseWebhookData = {
|
|
9640
9926
|
body?: never;
|
|
9641
|
-
headers
|
|
9927
|
+
headers: {
|
|
9642
9928
|
/**
|
|
9643
9929
|
* Optional caller-provided correlation identifier.
|
|
9644
9930
|
*/
|
|
9645
9931
|
"X-Request-Id"?: string;
|
|
9932
|
+
/**
|
|
9933
|
+
* Identifies one mutation and its canonical request payload.
|
|
9934
|
+
*/
|
|
9935
|
+
"Idempotency-Key": string;
|
|
9646
9936
|
};
|
|
9647
9937
|
path: {
|
|
9648
9938
|
/**
|
|
@@ -9676,6 +9966,10 @@ export type DeleteProjectDatabaseWebhookErrors = {
|
|
|
9676
9966
|
* The resource does not exist or is not visible to the authenticated principal.
|
|
9677
9967
|
*/
|
|
9678
9968
|
404: ProblemDetails;
|
|
9969
|
+
/**
|
|
9970
|
+
* The request failed.
|
|
9971
|
+
*/
|
|
9972
|
+
409: ProblemDetails;
|
|
9679
9973
|
/**
|
|
9680
9974
|
* The request failed.
|
|
9681
9975
|
*/
|
|
@@ -9764,11 +10058,15 @@ export type GetProjectDatabaseWebhookResponse =
|
|
|
9764
10058
|
|
|
9765
10059
|
export type TestProjectDatabaseWebhookData = {
|
|
9766
10060
|
body?: never;
|
|
9767
|
-
headers
|
|
10061
|
+
headers: {
|
|
9768
10062
|
/**
|
|
9769
10063
|
* Optional caller-provided correlation identifier.
|
|
9770
10064
|
*/
|
|
9771
10065
|
"X-Request-Id"?: string;
|
|
10066
|
+
/**
|
|
10067
|
+
* Identifies one mutation and its canonical request payload.
|
|
10068
|
+
*/
|
|
10069
|
+
"Idempotency-Key": string;
|
|
9772
10070
|
};
|
|
9773
10071
|
path: {
|
|
9774
10072
|
/**
|
|
@@ -9802,6 +10100,10 @@ export type TestProjectDatabaseWebhookErrors = {
|
|
|
9802
10100
|
* The resource does not exist or is not visible to the authenticated principal.
|
|
9803
10101
|
*/
|
|
9804
10102
|
404: ProblemDetails;
|
|
10103
|
+
/**
|
|
10104
|
+
* The request failed.
|
|
10105
|
+
*/
|
|
10106
|
+
409: ProblemDetails;
|
|
9805
10107
|
/**
|
|
9806
10108
|
* The request failed.
|
|
9807
10109
|
*/
|
|
@@ -9898,11 +10200,15 @@ export type ListProjectDatabaseWebhookDeliveriesResponse =
|
|
|
9898
10200
|
|
|
9899
10201
|
export type ReplayProjectDatabaseWebhookDeliveryData = {
|
|
9900
10202
|
body?: never;
|
|
9901
|
-
headers
|
|
10203
|
+
headers: {
|
|
9902
10204
|
/**
|
|
9903
10205
|
* Optional caller-provided correlation identifier.
|
|
9904
10206
|
*/
|
|
9905
10207
|
"X-Request-Id"?: string;
|
|
10208
|
+
/**
|
|
10209
|
+
* Identifies one mutation and its canonical request payload.
|
|
10210
|
+
*/
|
|
10211
|
+
"Idempotency-Key": string;
|
|
9906
10212
|
};
|
|
9907
10213
|
path: {
|
|
9908
10214
|
/**
|
|
@@ -10288,11 +10594,15 @@ export type ListProjectDatabaseScheduleRunsResponse =
|
|
|
10288
10594
|
|
|
10289
10595
|
export type RunProjectDatabaseScheduleData = {
|
|
10290
10596
|
body?: never;
|
|
10291
|
-
headers
|
|
10597
|
+
headers: {
|
|
10292
10598
|
/**
|
|
10293
10599
|
* Optional caller-provided correlation identifier.
|
|
10294
10600
|
*/
|
|
10295
10601
|
"X-Request-Id"?: string;
|
|
10602
|
+
/**
|
|
10603
|
+
* Identifies one mutation and its canonical request payload.
|
|
10604
|
+
*/
|
|
10605
|
+
"Idempotency-Key": string;
|
|
10296
10606
|
};
|
|
10297
10607
|
path: {
|
|
10298
10608
|
/**
|
|
@@ -10990,6 +11300,80 @@ export type PutEnvironmentSecretResponses = {
|
|
|
10990
11300
|
export type PutEnvironmentSecretResponse =
|
|
10991
11301
|
PutEnvironmentSecretResponses[keyof PutEnvironmentSecretResponses];
|
|
10992
11302
|
|
|
11303
|
+
export type RotateEnvironmentSecretData = {
|
|
11304
|
+
body?: never;
|
|
11305
|
+
headers: {
|
|
11306
|
+
/**
|
|
11307
|
+
* Optional caller-provided correlation identifier.
|
|
11308
|
+
*/
|
|
11309
|
+
"X-Request-Id"?: string;
|
|
11310
|
+
/**
|
|
11311
|
+
* Identifies one mutation and its canonical request payload.
|
|
11312
|
+
*/
|
|
11313
|
+
"Idempotency-Key": string;
|
|
11314
|
+
};
|
|
11315
|
+
path: {
|
|
11316
|
+
/**
|
|
11317
|
+
* Project identifier.
|
|
11318
|
+
*/
|
|
11319
|
+
project_id: Ulid;
|
|
11320
|
+
/**
|
|
11321
|
+
* Environment identifier.
|
|
11322
|
+
*/
|
|
11323
|
+
environment_id: Ulid;
|
|
11324
|
+
/**
|
|
11325
|
+
* Uppercase environment-variable name.
|
|
11326
|
+
*/
|
|
11327
|
+
secret_name: string;
|
|
11328
|
+
};
|
|
11329
|
+
query?: never;
|
|
11330
|
+
url: "/v1/projects/{project_id}/environments/{environment_id}/secrets/{secret_name}/rotate";
|
|
11331
|
+
};
|
|
11332
|
+
|
|
11333
|
+
export type RotateEnvironmentSecretErrors = {
|
|
11334
|
+
/**
|
|
11335
|
+
* The request failed.
|
|
11336
|
+
*/
|
|
11337
|
+
400: ProblemDetails;
|
|
11338
|
+
/**
|
|
11339
|
+
* The request failed.
|
|
11340
|
+
*/
|
|
11341
|
+
401: ProblemDetails;
|
|
11342
|
+
/**
|
|
11343
|
+
* The request failed.
|
|
11344
|
+
*/
|
|
11345
|
+
403: ProblemDetails;
|
|
11346
|
+
/**
|
|
11347
|
+
* The resource does not exist or is not visible to the authenticated principal.
|
|
11348
|
+
*/
|
|
11349
|
+
404: ProblemDetails;
|
|
11350
|
+
/**
|
|
11351
|
+
* The idempotency key was already used with a different canonical request.
|
|
11352
|
+
*/
|
|
11353
|
+
409: IdempotencyConflictProblem;
|
|
11354
|
+
/**
|
|
11355
|
+
* The request failed.
|
|
11356
|
+
*/
|
|
11357
|
+
429: ProblemDetails;
|
|
11358
|
+
/**
|
|
11359
|
+
* The request failed.
|
|
11360
|
+
*/
|
|
11361
|
+
503: ProblemDetails;
|
|
11362
|
+
};
|
|
11363
|
+
|
|
11364
|
+
export type RotateEnvironmentSecretError =
|
|
11365
|
+
RotateEnvironmentSecretErrors[keyof RotateEnvironmentSecretErrors];
|
|
11366
|
+
|
|
11367
|
+
export type RotateEnvironmentSecretResponses = {
|
|
11368
|
+
/**
|
|
11369
|
+
* Rotated secret metadata. The value is never returned.
|
|
11370
|
+
*/
|
|
11371
|
+
200: EnvironmentSecret;
|
|
11372
|
+
};
|
|
11373
|
+
|
|
11374
|
+
export type RotateEnvironmentSecretResponse =
|
|
11375
|
+
RotateEnvironmentSecretResponses[keyof RotateEnvironmentSecretResponses];
|
|
11376
|
+
|
|
10993
11377
|
export type GetOperationData = {
|
|
10994
11378
|
body?: never;
|
|
10995
11379
|
headers?: {
|
|
@@ -11557,6 +11941,70 @@ export type PrepareManagedMailWebhookResponses = {
|
|
|
11557
11941
|
export type PrepareManagedMailWebhookResponse =
|
|
11558
11942
|
PrepareManagedMailWebhookResponses[keyof PrepareManagedMailWebhookResponses];
|
|
11559
11943
|
|
|
11944
|
+
export type RotateManagedMailWebhookSecretData = {
|
|
11945
|
+
body?: never;
|
|
11946
|
+
headers: {
|
|
11947
|
+
/**
|
|
11948
|
+
* Optional caller-provided correlation identifier.
|
|
11949
|
+
*/
|
|
11950
|
+
"X-Request-Id"?: string;
|
|
11951
|
+
/**
|
|
11952
|
+
* Identifies one mutation and its canonical request payload.
|
|
11953
|
+
*/
|
|
11954
|
+
"Idempotency-Key": string;
|
|
11955
|
+
};
|
|
11956
|
+
path: {
|
|
11957
|
+
project_id: Ulid;
|
|
11958
|
+
environment_id: Ulid;
|
|
11959
|
+
};
|
|
11960
|
+
query?: never;
|
|
11961
|
+
url: "/v1/projects/{project_id}/environments/{environment_id}/mail-webhook:rotate";
|
|
11962
|
+
};
|
|
11963
|
+
|
|
11964
|
+
export type RotateManagedMailWebhookSecretErrors = {
|
|
11965
|
+
/**
|
|
11966
|
+
* The request failed.
|
|
11967
|
+
*/
|
|
11968
|
+
400: ProblemDetails;
|
|
11969
|
+
/**
|
|
11970
|
+
* The request failed.
|
|
11971
|
+
*/
|
|
11972
|
+
401: ProblemDetails;
|
|
11973
|
+
/**
|
|
11974
|
+
* The request failed.
|
|
11975
|
+
*/
|
|
11976
|
+
403: ProblemDetails;
|
|
11977
|
+
/**
|
|
11978
|
+
* The request failed.
|
|
11979
|
+
*/
|
|
11980
|
+
404: ProblemDetails;
|
|
11981
|
+
/**
|
|
11982
|
+
* The request failed.
|
|
11983
|
+
*/
|
|
11984
|
+
409: ProblemDetails;
|
|
11985
|
+
/**
|
|
11986
|
+
* The request failed.
|
|
11987
|
+
*/
|
|
11988
|
+
429: ProblemDetails;
|
|
11989
|
+
/**
|
|
11990
|
+
* The request failed.
|
|
11991
|
+
*/
|
|
11992
|
+
503: ProblemDetails;
|
|
11993
|
+
};
|
|
11994
|
+
|
|
11995
|
+
export type RotateManagedMailWebhookSecretError =
|
|
11996
|
+
RotateManagedMailWebhookSecretErrors[keyof RotateManagedMailWebhookSecretErrors];
|
|
11997
|
+
|
|
11998
|
+
export type RotateManagedMailWebhookSecretResponses = {
|
|
11999
|
+
/**
|
|
12000
|
+
* Authorized mail result with the new signing secret.
|
|
12001
|
+
*/
|
|
12002
|
+
200: ManagedMailWebhook;
|
|
12003
|
+
};
|
|
12004
|
+
|
|
12005
|
+
export type RotateManagedMailWebhookSecretResponse =
|
|
12006
|
+
RotateManagedMailWebhookSecretResponses[keyof RotateManagedMailWebhookSecretResponses];
|
|
12007
|
+
|
|
11560
12008
|
export type VerifyManagedMailWebhookData = {
|
|
11561
12009
|
body?: never;
|
|
11562
12010
|
headers: {
|
|
@@ -49,6 +49,18 @@ export function assertManagedMailResponse(value: unknown, input: ManagedMailComm
|
|
|
49
49
|
}
|
|
50
50
|
return;
|
|
51
51
|
}
|
|
52
|
+
if (input.action === "webhook_rotate") {
|
|
53
|
+
// The rotated secret is the only answer that carries it; the endpoint is the one already set.
|
|
54
|
+
exact(r, ["url", "signing_secret", "status"]);
|
|
55
|
+
https(r["url"]);
|
|
56
|
+
if (
|
|
57
|
+
r["status"] !== "verification_required" ||
|
|
58
|
+
typeof r["signing_secret"] !== "string" ||
|
|
59
|
+
!/^whsec_[A-Za-z0-9+/]{43}=$/u.test(r["signing_secret"])
|
|
60
|
+
)
|
|
61
|
+
invalid();
|
|
62
|
+
return;
|
|
63
|
+
}
|
|
52
64
|
if (input.action === "webhook_set") {
|
|
53
65
|
exact(r, ["url", "signing_secret", "status"]);
|
|
54
66
|
if (
|