@maxim_mazurok/gapi.client.cloudbilling-v1 0.0.20231006 → 0.0.20231025
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/index.d.ts +468 -1
- package/package.json +1 -1
- package/readme.md +5 -0
- package/tests.ts +58 -1
package/index.d.ts
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
// This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
|
|
10
10
|
// In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
|
|
11
11
|
// Generated from: https://cloudbilling.googleapis.com/$discovery/rest?version=v1
|
|
12
|
-
// Revision:
|
|
12
|
+
// Revision: 20231025
|
|
13
13
|
|
|
14
14
|
/// <reference types="gapi.client" />
|
|
15
15
|
|
|
@@ -198,6 +198,11 @@ declare namespace gapi.client {
|
|
|
198
198
|
units?:
|
|
199
199
|
string;
|
|
200
200
|
}
|
|
201
|
+
interface MoveBillingAccountRequest {
|
|
202
|
+
/** Required. The resource name of the Organization to reparent the billing account under. Must be of the form `organizations/{organization_id}`. */
|
|
203
|
+
destinationParent?:
|
|
204
|
+
string;
|
|
205
|
+
}
|
|
201
206
|
interface Policy {
|
|
202
207
|
/** Specifies cloud audit logging configuration for this policy. */
|
|
203
208
|
auditConfigs?:
|
|
@@ -438,6 +443,158 @@ declare namespace gapi.client {
|
|
|
438
443
|
string;
|
|
439
444
|
}): Request<ListProjectBillingInfoResponse>;
|
|
440
445
|
}
|
|
446
|
+
interface SubAccountsResource {
|
|
447
|
+
/**
|
|
448
|
+
* This method creates [billing subaccounts](https://cloud.google.com/billing/docs/concepts#subaccounts). Google Cloud resellers should use the Channel Services APIs,
|
|
449
|
+
* [accounts.customers.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers/create) and
|
|
450
|
+
* [accounts.customers.entitlements.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers.entitlements/create). When creating a subaccount, the current
|
|
451
|
+
* authenticated user must have the `billing.accounts.update` IAM permission on the parent account, which is typically given to billing account
|
|
452
|
+
* [administrators](https://cloud.google.com/billing/docs/how-to/billing-access). This method will return an error if the parent account has not been provisioned for subaccounts.
|
|
453
|
+
*/
|
|
454
|
+
create(request: {
|
|
455
|
+
/** V1 error format. */
|
|
456
|
+
"$.xgafv"?:
|
|
457
|
+
string;
|
|
458
|
+
/** OAuth access token. */
|
|
459
|
+
access_token?:
|
|
460
|
+
string;
|
|
461
|
+
/** Data format for response. */
|
|
462
|
+
alt?:
|
|
463
|
+
string;
|
|
464
|
+
/** JSONP */
|
|
465
|
+
callback?:
|
|
466
|
+
string;
|
|
467
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
468
|
+
fields?:
|
|
469
|
+
string;
|
|
470
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
471
|
+
key?:
|
|
472
|
+
string;
|
|
473
|
+
/** OAuth 2.0 token for the current user. */
|
|
474
|
+
oauth_token?:
|
|
475
|
+
string;
|
|
476
|
+
/**
|
|
477
|
+
* Optional. The parent to create a billing account from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
478
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
479
|
+
*/
|
|
480
|
+
parent:
|
|
481
|
+
string;
|
|
482
|
+
/** Returns response with indentations and line breaks. */
|
|
483
|
+
prettyPrint?:
|
|
484
|
+
boolean;
|
|
485
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
486
|
+
quotaUser?:
|
|
487
|
+
string;
|
|
488
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
489
|
+
upload_protocol?:
|
|
490
|
+
string;
|
|
491
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
492
|
+
uploadType?:
|
|
493
|
+
string;
|
|
494
|
+
/** Request body */
|
|
495
|
+
resource:
|
|
496
|
+
BillingAccount;
|
|
497
|
+
}): Request<BillingAccount>;
|
|
498
|
+
create(request: {
|
|
499
|
+
/** V1 error format. */
|
|
500
|
+
"$.xgafv"?:
|
|
501
|
+
string;
|
|
502
|
+
/** OAuth access token. */
|
|
503
|
+
access_token?:
|
|
504
|
+
string;
|
|
505
|
+
/** Data format for response. */
|
|
506
|
+
alt?:
|
|
507
|
+
string;
|
|
508
|
+
/** JSONP */
|
|
509
|
+
callback?:
|
|
510
|
+
string;
|
|
511
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
512
|
+
fields?:
|
|
513
|
+
string;
|
|
514
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
515
|
+
key?:
|
|
516
|
+
string;
|
|
517
|
+
/** OAuth 2.0 token for the current user. */
|
|
518
|
+
oauth_token?:
|
|
519
|
+
string;
|
|
520
|
+
/**
|
|
521
|
+
* Optional. The parent to create a billing account from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
522
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
523
|
+
*/
|
|
524
|
+
parent:
|
|
525
|
+
string;
|
|
526
|
+
/** Returns response with indentations and line breaks. */
|
|
527
|
+
prettyPrint?:
|
|
528
|
+
boolean;
|
|
529
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
530
|
+
quotaUser?:
|
|
531
|
+
string;
|
|
532
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
533
|
+
upload_protocol?:
|
|
534
|
+
string;
|
|
535
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
536
|
+
uploadType?:
|
|
537
|
+
string;
|
|
538
|
+
},
|
|
539
|
+
body: BillingAccount): Request<BillingAccount>;
|
|
540
|
+
/** Lists the billing accounts that the current authenticated user has permission to [view](https://cloud.google.com/billing/docs/how-to/billing-access). */
|
|
541
|
+
list(request?: {
|
|
542
|
+
/** V1 error format. */
|
|
543
|
+
"$.xgafv"?:
|
|
544
|
+
string;
|
|
545
|
+
/** OAuth access token. */
|
|
546
|
+
access_token?:
|
|
547
|
+
string;
|
|
548
|
+
/** Data format for response. */
|
|
549
|
+
alt?:
|
|
550
|
+
string;
|
|
551
|
+
/** JSONP */
|
|
552
|
+
callback?:
|
|
553
|
+
string;
|
|
554
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
555
|
+
fields?:
|
|
556
|
+
string;
|
|
557
|
+
/**
|
|
558
|
+
* Options for how to filter the returned billing accounts. This only supports filtering for [subaccounts](https://cloud.google.com/billing/docs/concepts) under a single provided
|
|
559
|
+
* parent billing account. (e.g. "master_billing_account=billingAccounts/012345-678901-ABCDEF"). Boolean algebra and other fields are not currently supported.
|
|
560
|
+
*/
|
|
561
|
+
filter?:
|
|
562
|
+
string;
|
|
563
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
564
|
+
key?:
|
|
565
|
+
string;
|
|
566
|
+
/** OAuth 2.0 token for the current user. */
|
|
567
|
+
oauth_token?:
|
|
568
|
+
string;
|
|
569
|
+
/** Requested page size. The maximum page size is 100; this is also the default. */
|
|
570
|
+
pageSize?:
|
|
571
|
+
number;
|
|
572
|
+
/**
|
|
573
|
+
* A token identifying a page of results to return. This should be a `next_page_token` value returned from a previous `ListBillingAccounts` call. If unspecified, the first page of
|
|
574
|
+
* results is returned.
|
|
575
|
+
*/
|
|
576
|
+
pageToken?:
|
|
577
|
+
string;
|
|
578
|
+
/**
|
|
579
|
+
* Optional. The parent resource to list billing accounts from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
580
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
581
|
+
*/
|
|
582
|
+
parent:
|
|
583
|
+
string;
|
|
584
|
+
/** Returns response with indentations and line breaks. */
|
|
585
|
+
prettyPrint?:
|
|
586
|
+
boolean;
|
|
587
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
588
|
+
quotaUser?:
|
|
589
|
+
string;
|
|
590
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
591
|
+
upload_protocol?:
|
|
592
|
+
string;
|
|
593
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
594
|
+
uploadType?:
|
|
595
|
+
string;
|
|
596
|
+
}): Request<ListBillingAccountsResponse>;
|
|
597
|
+
}
|
|
441
598
|
interface BillingAccountsResource {
|
|
442
599
|
/**
|
|
443
600
|
* This method creates [billing subaccounts](https://cloud.google.com/billing/docs/concepts#subaccounts). Google Cloud resellers should use the Channel Services APIs,
|
|
@@ -468,6 +625,12 @@ declare namespace gapi.client {
|
|
|
468
625
|
/** OAuth 2.0 token for the current user. */
|
|
469
626
|
oauth_token?:
|
|
470
627
|
string;
|
|
628
|
+
/**
|
|
629
|
+
* Optional. The parent to create a billing account from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
630
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
631
|
+
*/
|
|
632
|
+
parent?:
|
|
633
|
+
string;
|
|
471
634
|
/** Returns response with indentations and line breaks. */
|
|
472
635
|
prettyPrint?:
|
|
473
636
|
boolean;
|
|
@@ -506,6 +669,12 @@ declare namespace gapi.client {
|
|
|
506
669
|
/** OAuth 2.0 token for the current user. */
|
|
507
670
|
oauth_token?:
|
|
508
671
|
string;
|
|
672
|
+
/**
|
|
673
|
+
* Optional. The parent to create a billing account from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
674
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
675
|
+
*/
|
|
676
|
+
parent?:
|
|
677
|
+
string;
|
|
509
678
|
/** Returns response with indentations and line breaks. */
|
|
510
679
|
prettyPrint?:
|
|
511
680
|
boolean;
|
|
@@ -651,6 +820,12 @@ declare namespace gapi.client {
|
|
|
651
820
|
*/
|
|
652
821
|
pageToken?:
|
|
653
822
|
string;
|
|
823
|
+
/**
|
|
824
|
+
* Optional. The parent resource to list billing accounts from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
825
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
826
|
+
*/
|
|
827
|
+
parent?:
|
|
828
|
+
string;
|
|
654
829
|
/** Returns response with indentations and line breaks. */
|
|
655
830
|
prettyPrint?:
|
|
656
831
|
boolean;
|
|
@@ -664,6 +839,93 @@ declare namespace gapi.client {
|
|
|
664
839
|
uploadType?:
|
|
665
840
|
string;
|
|
666
841
|
}): Request<ListBillingAccountsResponse>;
|
|
842
|
+
/** Changes which parent organization a billing account belongs to. */
|
|
843
|
+
move(request: {
|
|
844
|
+
/** V1 error format. */
|
|
845
|
+
"$.xgafv"?:
|
|
846
|
+
string;
|
|
847
|
+
/** OAuth access token. */
|
|
848
|
+
access_token?:
|
|
849
|
+
string;
|
|
850
|
+
/** Data format for response. */
|
|
851
|
+
alt?:
|
|
852
|
+
string;
|
|
853
|
+
/** JSONP */
|
|
854
|
+
callback?:
|
|
855
|
+
string;
|
|
856
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
857
|
+
fields?:
|
|
858
|
+
string;
|
|
859
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
860
|
+
key?:
|
|
861
|
+
string;
|
|
862
|
+
/**
|
|
863
|
+
* Required. The resource name of the billing account to move. Must be of the form `billingAccounts/{billing_account_id}`. The specified billing account cannot be a subaccount,
|
|
864
|
+
* since a subaccount always belongs to the same organization as its parent account.
|
|
865
|
+
*/
|
|
866
|
+
name:
|
|
867
|
+
string;
|
|
868
|
+
/** OAuth 2.0 token for the current user. */
|
|
869
|
+
oauth_token?:
|
|
870
|
+
string;
|
|
871
|
+
/** Returns response with indentations and line breaks. */
|
|
872
|
+
prettyPrint?:
|
|
873
|
+
boolean;
|
|
874
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
875
|
+
quotaUser?:
|
|
876
|
+
string;
|
|
877
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
878
|
+
upload_protocol?:
|
|
879
|
+
string;
|
|
880
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
881
|
+
uploadType?:
|
|
882
|
+
string;
|
|
883
|
+
/** Request body */
|
|
884
|
+
resource:
|
|
885
|
+
MoveBillingAccountRequest;
|
|
886
|
+
}): Request<BillingAccount>;
|
|
887
|
+
move(request: {
|
|
888
|
+
/** V1 error format. */
|
|
889
|
+
"$.xgafv"?:
|
|
890
|
+
string;
|
|
891
|
+
/** OAuth access token. */
|
|
892
|
+
access_token?:
|
|
893
|
+
string;
|
|
894
|
+
/** Data format for response. */
|
|
895
|
+
alt?:
|
|
896
|
+
string;
|
|
897
|
+
/** JSONP */
|
|
898
|
+
callback?:
|
|
899
|
+
string;
|
|
900
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
901
|
+
fields?:
|
|
902
|
+
string;
|
|
903
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
904
|
+
key?:
|
|
905
|
+
string;
|
|
906
|
+
/**
|
|
907
|
+
* Required. The resource name of the billing account to move. Must be of the form `billingAccounts/{billing_account_id}`. The specified billing account cannot be a subaccount,
|
|
908
|
+
* since a subaccount always belongs to the same organization as its parent account.
|
|
909
|
+
*/
|
|
910
|
+
name:
|
|
911
|
+
string;
|
|
912
|
+
/** OAuth 2.0 token for the current user. */
|
|
913
|
+
oauth_token?:
|
|
914
|
+
string;
|
|
915
|
+
/** Returns response with indentations and line breaks. */
|
|
916
|
+
prettyPrint?:
|
|
917
|
+
boolean;
|
|
918
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
919
|
+
quotaUser?:
|
|
920
|
+
string;
|
|
921
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
922
|
+
upload_protocol?:
|
|
923
|
+
string;
|
|
924
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
925
|
+
uploadType?:
|
|
926
|
+
string;
|
|
927
|
+
},
|
|
928
|
+
body: MoveBillingAccountRequest): Request<BillingAccount>;
|
|
667
929
|
/**
|
|
668
930
|
* Updates a billing account's fields. Currently the only field that can be edited is `display_name`. The current authenticated user must have the `billing.accounts.update` IAM
|
|
669
931
|
* permission, which is typically given to the [administrator](https://cloud.google.com/billing/docs/how-to/billing-access) of the billing account.
|
|
@@ -848,6 +1110,209 @@ declare namespace gapi.client {
|
|
|
848
1110
|
body: TestIamPermissionsRequest): Request<TestIamPermissionsResponse>;
|
|
849
1111
|
projects:
|
|
850
1112
|
ProjectsResource;
|
|
1113
|
+
subAccounts:
|
|
1114
|
+
SubAccountsResource;
|
|
1115
|
+
}
|
|
1116
|
+
interface BillingAccountsResource {
|
|
1117
|
+
/**
|
|
1118
|
+
* This method creates [billing subaccounts](https://cloud.google.com/billing/docs/concepts#subaccounts). Google Cloud resellers should use the Channel Services APIs,
|
|
1119
|
+
* [accounts.customers.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers/create) and
|
|
1120
|
+
* [accounts.customers.entitlements.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers.entitlements/create). When creating a subaccount, the current
|
|
1121
|
+
* authenticated user must have the `billing.accounts.update` IAM permission on the parent account, which is typically given to billing account
|
|
1122
|
+
* [administrators](https://cloud.google.com/billing/docs/how-to/billing-access). This method will return an error if the parent account has not been provisioned for subaccounts.
|
|
1123
|
+
*/
|
|
1124
|
+
create(request: {
|
|
1125
|
+
/** V1 error format. */
|
|
1126
|
+
"$.xgafv"?:
|
|
1127
|
+
string;
|
|
1128
|
+
/** OAuth access token. */
|
|
1129
|
+
access_token?:
|
|
1130
|
+
string;
|
|
1131
|
+
/** Data format for response. */
|
|
1132
|
+
alt?:
|
|
1133
|
+
string;
|
|
1134
|
+
/** JSONP */
|
|
1135
|
+
callback?:
|
|
1136
|
+
string;
|
|
1137
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
1138
|
+
fields?:
|
|
1139
|
+
string;
|
|
1140
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
1141
|
+
key?:
|
|
1142
|
+
string;
|
|
1143
|
+
/** OAuth 2.0 token for the current user. */
|
|
1144
|
+
oauth_token?:
|
|
1145
|
+
string;
|
|
1146
|
+
/**
|
|
1147
|
+
* Optional. The parent to create a billing account from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
1148
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
1149
|
+
*/
|
|
1150
|
+
parent:
|
|
1151
|
+
string;
|
|
1152
|
+
/** Returns response with indentations and line breaks. */
|
|
1153
|
+
prettyPrint?:
|
|
1154
|
+
boolean;
|
|
1155
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
1156
|
+
quotaUser?:
|
|
1157
|
+
string;
|
|
1158
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1159
|
+
upload_protocol?:
|
|
1160
|
+
string;
|
|
1161
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1162
|
+
uploadType?:
|
|
1163
|
+
string;
|
|
1164
|
+
/** Request body */
|
|
1165
|
+
resource:
|
|
1166
|
+
BillingAccount;
|
|
1167
|
+
}): Request<BillingAccount>;
|
|
1168
|
+
create(request: {
|
|
1169
|
+
/** V1 error format. */
|
|
1170
|
+
"$.xgafv"?:
|
|
1171
|
+
string;
|
|
1172
|
+
/** OAuth access token. */
|
|
1173
|
+
access_token?:
|
|
1174
|
+
string;
|
|
1175
|
+
/** Data format for response. */
|
|
1176
|
+
alt?:
|
|
1177
|
+
string;
|
|
1178
|
+
/** JSONP */
|
|
1179
|
+
callback?:
|
|
1180
|
+
string;
|
|
1181
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
1182
|
+
fields?:
|
|
1183
|
+
string;
|
|
1184
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
1185
|
+
key?:
|
|
1186
|
+
string;
|
|
1187
|
+
/** OAuth 2.0 token for the current user. */
|
|
1188
|
+
oauth_token?:
|
|
1189
|
+
string;
|
|
1190
|
+
/**
|
|
1191
|
+
* Optional. The parent to create a billing account from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
1192
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
1193
|
+
*/
|
|
1194
|
+
parent:
|
|
1195
|
+
string;
|
|
1196
|
+
/** Returns response with indentations and line breaks. */
|
|
1197
|
+
prettyPrint?:
|
|
1198
|
+
boolean;
|
|
1199
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
1200
|
+
quotaUser?:
|
|
1201
|
+
string;
|
|
1202
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1203
|
+
upload_protocol?:
|
|
1204
|
+
string;
|
|
1205
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1206
|
+
uploadType?:
|
|
1207
|
+
string;
|
|
1208
|
+
},
|
|
1209
|
+
body: BillingAccount): Request<BillingAccount>;
|
|
1210
|
+
/** Lists the billing accounts that the current authenticated user has permission to [view](https://cloud.google.com/billing/docs/how-to/billing-access). */
|
|
1211
|
+
list(request?: {
|
|
1212
|
+
/** V1 error format. */
|
|
1213
|
+
"$.xgafv"?:
|
|
1214
|
+
string;
|
|
1215
|
+
/** OAuth access token. */
|
|
1216
|
+
access_token?:
|
|
1217
|
+
string;
|
|
1218
|
+
/** Data format for response. */
|
|
1219
|
+
alt?:
|
|
1220
|
+
string;
|
|
1221
|
+
/** JSONP */
|
|
1222
|
+
callback?:
|
|
1223
|
+
string;
|
|
1224
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
1225
|
+
fields?:
|
|
1226
|
+
string;
|
|
1227
|
+
/**
|
|
1228
|
+
* Options for how to filter the returned billing accounts. This only supports filtering for [subaccounts](https://cloud.google.com/billing/docs/concepts) under a single provided
|
|
1229
|
+
* parent billing account. (e.g. "master_billing_account=billingAccounts/012345-678901-ABCDEF"). Boolean algebra and other fields are not currently supported.
|
|
1230
|
+
*/
|
|
1231
|
+
filter?:
|
|
1232
|
+
string;
|
|
1233
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
1234
|
+
key?:
|
|
1235
|
+
string;
|
|
1236
|
+
/** OAuth 2.0 token for the current user. */
|
|
1237
|
+
oauth_token?:
|
|
1238
|
+
string;
|
|
1239
|
+
/** Requested page size. The maximum page size is 100; this is also the default. */
|
|
1240
|
+
pageSize?:
|
|
1241
|
+
number;
|
|
1242
|
+
/**
|
|
1243
|
+
* A token identifying a page of results to return. This should be a `next_page_token` value returned from a previous `ListBillingAccounts` call. If unspecified, the first page of
|
|
1244
|
+
* results is returned.
|
|
1245
|
+
*/
|
|
1246
|
+
pageToken?:
|
|
1247
|
+
string;
|
|
1248
|
+
/**
|
|
1249
|
+
* Optional. The parent resource to list billing accounts from. Format: - organizations/{organization_id} eg organizations/12345678 - billingAccounts/{billing_account_id} eg
|
|
1250
|
+
* `billingAccounts/012345-567890-ABCDEF`
|
|
1251
|
+
*/
|
|
1252
|
+
parent:
|
|
1253
|
+
string;
|
|
1254
|
+
/** Returns response with indentations and line breaks. */
|
|
1255
|
+
prettyPrint?:
|
|
1256
|
+
boolean;
|
|
1257
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
1258
|
+
quotaUser?:
|
|
1259
|
+
string;
|
|
1260
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1261
|
+
upload_protocol?:
|
|
1262
|
+
string;
|
|
1263
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1264
|
+
uploadType?:
|
|
1265
|
+
string;
|
|
1266
|
+
}): Request<ListBillingAccountsResponse>;
|
|
1267
|
+
/** Changes which parent organization a billing account belongs to. */
|
|
1268
|
+
move(request?: {
|
|
1269
|
+
/** V1 error format. */
|
|
1270
|
+
"$.xgafv"?:
|
|
1271
|
+
string;
|
|
1272
|
+
/** OAuth access token. */
|
|
1273
|
+
access_token?:
|
|
1274
|
+
string;
|
|
1275
|
+
/** Data format for response. */
|
|
1276
|
+
alt?:
|
|
1277
|
+
string;
|
|
1278
|
+
/** JSONP */
|
|
1279
|
+
callback?:
|
|
1280
|
+
string;
|
|
1281
|
+
/** Required. The resource name of the Organization to reparent the billing account under. Must be of the form `organizations/{organization_id}`. */
|
|
1282
|
+
destinationParent:
|
|
1283
|
+
string;
|
|
1284
|
+
/** Selector specifying which fields to include in a partial response. */
|
|
1285
|
+
fields?:
|
|
1286
|
+
string;
|
|
1287
|
+
/** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
|
|
1288
|
+
key?:
|
|
1289
|
+
string;
|
|
1290
|
+
/**
|
|
1291
|
+
* Required. The resource name of the billing account to move. Must be of the form `billingAccounts/{billing_account_id}`. The specified billing account cannot be a subaccount,
|
|
1292
|
+
* since a subaccount always belongs to the same organization as its parent account.
|
|
1293
|
+
*/
|
|
1294
|
+
name:
|
|
1295
|
+
string;
|
|
1296
|
+
/** OAuth 2.0 token for the current user. */
|
|
1297
|
+
oauth_token?:
|
|
1298
|
+
string;
|
|
1299
|
+
/** Returns response with indentations and line breaks. */
|
|
1300
|
+
prettyPrint?:
|
|
1301
|
+
boolean;
|
|
1302
|
+
/** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
|
|
1303
|
+
quotaUser?:
|
|
1304
|
+
string;
|
|
1305
|
+
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1306
|
+
upload_protocol?:
|
|
1307
|
+
string;
|
|
1308
|
+
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1309
|
+
uploadType?:
|
|
1310
|
+
string;
|
|
1311
|
+
}): Request<BillingAccount>;
|
|
1312
|
+
}
|
|
1313
|
+
interface OrganizationsResource {
|
|
1314
|
+
billingAccounts:
|
|
1315
|
+
BillingAccountsResource;
|
|
851
1316
|
}
|
|
852
1317
|
interface ProjectsResource {
|
|
853
1318
|
/**
|
|
@@ -1102,6 +1567,8 @@ declare namespace gapi.client {
|
|
|
1102
1567
|
|
|
1103
1568
|
const billingAccounts: BillingAccountsResource;
|
|
1104
1569
|
|
|
1570
|
+
const organizations: OrganizationsResource;
|
|
1571
|
+
|
|
1105
1572
|
const projects: ProjectsResource;
|
|
1106
1573
|
|
|
1107
1574
|
const services: ServicesResource;
|
package/package.json
CHANGED
package/readme.md
CHANGED
|
@@ -92,6 +92,11 @@ Lists the billing accounts that the current authenticated user has permission to
|
|
|
92
92
|
*/
|
|
93
93
|
await gapi.client.cloudbilling.billingAccounts.list({ });
|
|
94
94
|
|
|
95
|
+
/*
|
|
96
|
+
Changes which parent organization a billing account belongs to.
|
|
97
|
+
*/
|
|
98
|
+
await gapi.client.cloudbilling.billingAccounts.move({ name: "name", });
|
|
99
|
+
|
|
95
100
|
/*
|
|
96
101
|
Updates a billing account's fields. Currently the only field that can be edited is `display_name`. The current authenticated user must have the `billing.accounts.update` IAM permission, which is typically given to the [administrator](https://cloud.google.com/billing/docs/how-to/billing-access) of the billing account.
|
|
97
102
|
*/
|
package/tests.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
|
|
4
4
|
// In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
|
|
5
5
|
|
|
6
|
-
// Revision:
|
|
6
|
+
// Revision: 20231025
|
|
7
7
|
|
|
8
8
|
gapi.load('client', async () => {
|
|
9
9
|
/** now we can use gapi.client */
|
|
@@ -41,6 +41,7 @@ gapi.load('client', async () => {
|
|
|
41
41
|
* [administrators](https://cloud.google.com/billing/docs/how-to/billing-access). This method will return an error if the parent account has not been provisioned for subaccounts.
|
|
42
42
|
*/
|
|
43
43
|
await gapi.client.cloudbilling.billingAccounts.create({
|
|
44
|
+
parent: "Test string",
|
|
44
45
|
}, {
|
|
45
46
|
displayName: "Test string",
|
|
46
47
|
masterBillingAccount: "Test string",
|
|
@@ -64,6 +65,13 @@ gapi.load('client', async () => {
|
|
|
64
65
|
filter: "Test string",
|
|
65
66
|
pageSize: 42,
|
|
66
67
|
pageToken: "Test string",
|
|
68
|
+
parent: "Test string",
|
|
69
|
+
});
|
|
70
|
+
/** Changes which parent organization a billing account belongs to. */
|
|
71
|
+
await gapi.client.cloudbilling.billingAccounts.move({
|
|
72
|
+
name: "Test string",
|
|
73
|
+
}, {
|
|
74
|
+
destinationParent: "Test string",
|
|
67
75
|
});
|
|
68
76
|
/**
|
|
69
77
|
* Updates a billing account's fields. Currently the only field that can be edited is `display_name`. The current authenticated user must have the `billing.accounts.update` IAM permission,
|
|
@@ -138,6 +146,55 @@ gapi.load('client', async () => {
|
|
|
138
146
|
pageSize: 42,
|
|
139
147
|
pageToken: "Test string",
|
|
140
148
|
});
|
|
149
|
+
/**
|
|
150
|
+
* This method creates [billing subaccounts](https://cloud.google.com/billing/docs/concepts#subaccounts). Google Cloud resellers should use the Channel Services APIs,
|
|
151
|
+
* [accounts.customers.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers/create) and
|
|
152
|
+
* [accounts.customers.entitlements.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers.entitlements/create). When creating a subaccount, the current
|
|
153
|
+
* authenticated user must have the `billing.accounts.update` IAM permission on the parent account, which is typically given to billing account
|
|
154
|
+
* [administrators](https://cloud.google.com/billing/docs/how-to/billing-access). This method will return an error if the parent account has not been provisioned for subaccounts.
|
|
155
|
+
*/
|
|
156
|
+
await gapi.client.cloudbilling.billingAccounts.subAccounts.create({
|
|
157
|
+
parent: "Test string",
|
|
158
|
+
}, {
|
|
159
|
+
displayName: "Test string",
|
|
160
|
+
masterBillingAccount: "Test string",
|
|
161
|
+
name: "Test string",
|
|
162
|
+
open: true,
|
|
163
|
+
});
|
|
164
|
+
/** Lists the billing accounts that the current authenticated user has permission to [view](https://cloud.google.com/billing/docs/how-to/billing-access). */
|
|
165
|
+
await gapi.client.cloudbilling.billingAccounts.subAccounts.list({
|
|
166
|
+
filter: "Test string",
|
|
167
|
+
pageSize: 42,
|
|
168
|
+
pageToken: "Test string",
|
|
169
|
+
parent: "Test string",
|
|
170
|
+
});
|
|
171
|
+
/**
|
|
172
|
+
* This method creates [billing subaccounts](https://cloud.google.com/billing/docs/concepts#subaccounts). Google Cloud resellers should use the Channel Services APIs,
|
|
173
|
+
* [accounts.customers.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers/create) and
|
|
174
|
+
* [accounts.customers.entitlements.create](https://cloud.google.com/channel/docs/reference/rest/v1/accounts.customers.entitlements/create). When creating a subaccount, the current
|
|
175
|
+
* authenticated user must have the `billing.accounts.update` IAM permission on the parent account, which is typically given to billing account
|
|
176
|
+
* [administrators](https://cloud.google.com/billing/docs/how-to/billing-access). This method will return an error if the parent account has not been provisioned for subaccounts.
|
|
177
|
+
*/
|
|
178
|
+
await gapi.client.cloudbilling.organizations.billingAccounts.create({
|
|
179
|
+
parent: "Test string",
|
|
180
|
+
}, {
|
|
181
|
+
displayName: "Test string",
|
|
182
|
+
masterBillingAccount: "Test string",
|
|
183
|
+
name: "Test string",
|
|
184
|
+
open: true,
|
|
185
|
+
});
|
|
186
|
+
/** Lists the billing accounts that the current authenticated user has permission to [view](https://cloud.google.com/billing/docs/how-to/billing-access). */
|
|
187
|
+
await gapi.client.cloudbilling.organizations.billingAccounts.list({
|
|
188
|
+
filter: "Test string",
|
|
189
|
+
pageSize: 42,
|
|
190
|
+
pageToken: "Test string",
|
|
191
|
+
parent: "Test string",
|
|
192
|
+
});
|
|
193
|
+
/** Changes which parent organization a billing account belongs to. */
|
|
194
|
+
await gapi.client.cloudbilling.organizations.billingAccounts.move({
|
|
195
|
+
destinationParent: "Test string",
|
|
196
|
+
name: "Test string",
|
|
197
|
+
});
|
|
141
198
|
/**
|
|
142
199
|
* Gets the billing information for a project. The current authenticated user must have the `resourcemanager.projects.get` permission for the project, which can be granted by assigning the
|
|
143
200
|
* [Project Viewer](https://cloud.google.com/iam/docs/understanding-roles#predefined_roles) role.
|