@maxim_mazurok/gapi.client.cloudbilling-v1beta 0.0.20250613 → 0.0.20250721
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 +1 -461
- package/package.json +1 -1
- package/readme.md +0 -12
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=v1beta
|
|
12
|
-
// Revision:
|
|
12
|
+
// Revision: 20250721
|
|
13
13
|
|
|
14
14
|
/// <reference types="gapi.client" />
|
|
15
15
|
|
|
@@ -28,170 +28,10 @@ declare namespace gapi.client {
|
|
|
28
28
|
): void;
|
|
29
29
|
|
|
30
30
|
namespace cloudbilling {
|
|
31
|
-
interface CacheFillRegions {
|
|
32
|
-
/** The destination region for cache fill. */
|
|
33
|
-
destinationRegion?: string;
|
|
34
|
-
/** The source region for cache fill. */
|
|
35
|
-
sourceRegion?: string;
|
|
36
|
-
}
|
|
37
|
-
interface CloudCdnEgressWorkload {
|
|
38
|
-
/** The destination for the cache data transfer. */
|
|
39
|
-
cacheEgressDestination?: string;
|
|
40
|
-
/** Cache data transfer usage. The rate of data cache transferred to the destination. Use units such as GiBy/s or TiBy/mo, based on [The Unified Code for Units of Measure](https://ucum.org/ucum.html) standard. */
|
|
41
|
-
cacheEgressRate?: Usage;
|
|
42
|
-
}
|
|
43
|
-
interface CloudCdnWorkload {
|
|
44
|
-
/** The source service for the cache fill. */
|
|
45
|
-
cacheFillOriginService?: string;
|
|
46
|
-
/** Cache fill usage. The rate of data transferred between cache fill regions. For example: units such as "GiBy/s" or "TBy/mo". */
|
|
47
|
-
cacheFillRate?: Usage;
|
|
48
|
-
/** The regions where data is transferred from Google data locations into Google global cache servers. The SKU prices for cache fill across services are the same. */
|
|
49
|
-
cacheFillRegions?: CacheFillRegions;
|
|
50
|
-
/** Cache look up requests. This is specified to indicate the number of requests. For example: units such as "1/s". */
|
|
51
|
-
cacheLookUpRate?: Usage;
|
|
52
|
-
}
|
|
53
|
-
interface CloudInterconnectEgressWorkload {
|
|
54
|
-
/** Outbound data transfer usage. This usage applies when you move or copy data from one Google Cloud service to another service. The units are GiBy/s, By/s, and so on, based on [The Unified Code for Units of Measure](https://ucum.org/ucum.html) standard. */
|
|
55
|
-
egressRate?: Usage;
|
|
56
|
-
/** Locations in the [Interconnect connection location table](https://cloud.google.com/vpc/network-pricing#interconnect-pricing). These are the Interconnect Data Transfer charges. */
|
|
57
|
-
interconnectConnectionLocation?: string;
|
|
58
|
-
}
|
|
59
|
-
interface CloudInterconnectWorkload {
|
|
60
|
-
/** VLAN attachment used for interconnect. */
|
|
61
|
-
interconnectAttachments?: VlanAttachment[];
|
|
62
|
-
/** VLAN attachment type */
|
|
63
|
-
interconnectType?: string;
|
|
64
|
-
/** Interconnect circuit link type. */
|
|
65
|
-
linkType?: string;
|
|
66
|
-
/** Interconnect usage. This is specified as a unitless quantity which indicates the number of circuit provisioned in interconnect. */
|
|
67
|
-
provisionedLinkCount?: Usage;
|
|
68
|
-
}
|
|
69
|
-
interface CloudStorageEgressWorkload {
|
|
70
|
-
/** Where the data is sent to. */
|
|
71
|
-
destinationContinent?: string;
|
|
72
|
-
/** Data transfer usage rate. This usage applies when you move or copy data from one Cloud Storage bucket to another or when another Google Cloud service accesses data in your Cloud Storage bucket. The expected units are GiBy/s, By/s, and so on, based on [The Unified Code for Units of Measure](https://ucum.org/ucum.html) standard. */
|
|
73
|
-
egressRate?: Usage;
|
|
74
|
-
/** Where the data comes from. */
|
|
75
|
-
sourceContinent?: string;
|
|
76
|
-
}
|
|
77
|
-
interface CloudStorageWorkload {
|
|
78
|
-
/** Data retrieval usage. A retrieval cost applies when data or metadata is read, copied, or rewritten . For example: units such as "GiB/s" or "B/s". */
|
|
79
|
-
dataRetrieval?: Usage;
|
|
80
|
-
/** Data storage usage. The amount of data stored in buckets. For example: units such as GiBy/s or TiBy/mo, based on [The Unified Code for Units of Measure](https://ucum.org/ucum.html) standard. */
|
|
81
|
-
dataStored?: Usage;
|
|
82
|
-
/** Specify dual regions. */
|
|
83
|
-
dualRegion?: DualRegional;
|
|
84
|
-
/** Specify multi regions. */
|
|
85
|
-
multiRegion?: MultiRegional;
|
|
86
|
-
/** Class A operation usage in Cloud Storage, such as listing the objects in buckets. See the [operations pricing](https://cloud.google.com/storage/pricing#operations-pricing) tables for a list of which operations fall into each class. For example: units such as "1/s". */
|
|
87
|
-
operationA?: Usage;
|
|
88
|
-
/** Class B operation usage in Cloud Storage, such as `getIamPolicy`. See the [operations pricing](https://cloud.google.com/storage/pricing#operations-pricing) tables for a list of which operations fall into each class. For example: units such as "1/s". */
|
|
89
|
-
operationB?: Usage;
|
|
90
|
-
/** Specify a single region. */
|
|
91
|
-
region?: Regional;
|
|
92
|
-
/** The [storage class](https://cloud.google.com/storage/docs/storage-classes#classes) of the data and operation. For example: "standard" and "nearline". */
|
|
93
|
-
storageClass?: string;
|
|
94
|
-
}
|
|
95
|
-
interface Commitment {
|
|
96
|
-
/** Required. A name for this commitment. All commitments in a CostScenario must have unique names. Each name may be at most 128 characters long. */
|
|
97
|
-
name?: string;
|
|
98
|
-
/** A resource-based committed use discount (CUD). */
|
|
99
|
-
vmResourceBasedCud?: VmResourceBasedCud;
|
|
100
|
-
}
|
|
101
|
-
interface CommitmentCostEstimate {
|
|
102
|
-
/** Total estimated costs for the commitment. */
|
|
103
|
-
commitmentTotalCostEstimate?: CostEstimate;
|
|
104
|
-
/** The name of the commitment, as specified in the `CostScenario`. */
|
|
105
|
-
name?: string;
|
|
106
|
-
/** Estimated costs for each SKU in the commitment. */
|
|
107
|
-
skuCostEstimates?: SkuCostEstimate[];
|
|
108
|
-
}
|
|
109
|
-
interface ComputeVmWorkload {
|
|
110
|
-
/** Defines whether each instance has confidential compute enabled. */
|
|
111
|
-
enableConfidentialCompute?: boolean;
|
|
112
|
-
/** Guest accelerators attached to each machine. */
|
|
113
|
-
guestAccelerator?: GuestAccelerator;
|
|
114
|
-
/** VM usage. This is specified as a unitless quantity which indicates the number of instances running. */
|
|
115
|
-
instancesRunning?: Usage;
|
|
116
|
-
/** Premium image licenses used by each instance. */
|
|
117
|
-
licenses?: string[];
|
|
118
|
-
/** The machine type. */
|
|
119
|
-
machineType?: MachineType;
|
|
120
|
-
/** Persistent disks attached to each instance. Must include a boot disk. */
|
|
121
|
-
persistentDisks?: PersistentDisk[];
|
|
122
|
-
/** Defines whether each instance is preemptible. */
|
|
123
|
-
preemptible?: boolean;
|
|
124
|
-
/** The [region](https://cloud.google.com/compute/docs/regions-zones) where the VMs run. For example: "us-central1". */
|
|
125
|
-
region?: string;
|
|
126
|
-
}
|
|
127
|
-
interface CostEstimate {
|
|
128
|
-
/** The estimated credits applied. */
|
|
129
|
-
creditEstimates?: CreditEstimate[];
|
|
130
|
-
/** The estimated net cost after applying credits. */
|
|
131
|
-
netCostEstimate?: Money;
|
|
132
|
-
/** The estimated cost prior to applying credits. */
|
|
133
|
-
preCreditCostEstimate?: Money;
|
|
134
|
-
}
|
|
135
|
-
interface CostEstimationResult {
|
|
136
|
-
/** Required. The ISO 4217 currency code for the cost estimate. */
|
|
137
|
-
currencyCode?: string;
|
|
138
|
-
/** Required. Estimated costs for each idealized month of a `CostScenario`. */
|
|
139
|
-
segmentCostEstimates?: SegmentCostEstimate[];
|
|
140
|
-
/** Required. Information about SKUs used in the estimate. */
|
|
141
|
-
skus?: Sku[];
|
|
142
|
-
}
|
|
143
|
-
interface CostScenario {
|
|
144
|
-
/** New commitments to estimate the costs for. The cost of the commitments will be included in the estimate result and discounts the commitment entitles will be included in the workload cost estimates. A maximum of 100 workloads can be provided. */
|
|
145
|
-
commitments?: Commitment[];
|
|
146
|
-
/** Configuration for the scenario. */
|
|
147
|
-
scenarioConfig?: ScenarioConfig;
|
|
148
|
-
/** The Google Cloud usage whose costs are estimated. A maximum of 100 workloads can be provided. */
|
|
149
|
-
workloads?: Workload[];
|
|
150
|
-
}
|
|
151
|
-
interface CreditEstimate {
|
|
152
|
-
/** The estimated credit amount. */
|
|
153
|
-
creditAmount?: Money;
|
|
154
|
-
/** The credit description. */
|
|
155
|
-
creditDescription?: string;
|
|
156
|
-
/** The credit type. */
|
|
157
|
-
creditType?: string;
|
|
158
|
-
}
|
|
159
|
-
interface CustomMachineType {
|
|
160
|
-
/** Required. The machine series. Only certain [machine series](https://cloud.google.com/compute/docs/general-purpose-machines#custom_machine_types) support custom configurations. For example: "n1". */
|
|
161
|
-
machineSeries?: string;
|
|
162
|
-
/** Required. Memory size of the VM in GB (2^30 bytes). Must be an increment of 0.25 (256 MB). Each [machine series](https://cloud.google.com/compute/docs/machine-types#machine_type_comparison) has limitations on allowed values for the ratio of memory-to-vCPU count. */
|
|
163
|
-
memorySizeGb?: number;
|
|
164
|
-
/** Required. The number of vCPUs. The allowed values depend on the [machine series](https://cloud.google.com/compute/docs/machine-types#machine_type_comparison). */
|
|
165
|
-
virtualCpuCount?: string;
|
|
166
|
-
}
|
|
167
31
|
interface Decimal {
|
|
168
32
|
/** The decimal value, as a string. The string representation consists of an optional sign, `+` (`U+002B`) or `-` (`U+002D`), followed by a sequence of zero or more decimal digits ("the integer"), optionally followed by a fraction, optionally followed by an exponent. An empty string **should** be interpreted as `0`. The fraction consists of a decimal point followed by zero or more decimal digits. The string must contain at least one digit in either the integer or the fraction. The number formed by the sign, the integer and the fraction is referred to as the significand. The exponent consists of the character `e` (`U+0065`) or `E` (`U+0045`) followed by one or more decimal digits. Services **should** normalize decimal values before storing them by: - Removing an explicitly-provided `+` sign (`+2.5` -> `2.5`). - Replacing a zero-length integer value with `0` (`.5` -> `0.5`). - Coercing the exponent character to upper-case, with explicit sign (`2.5e8` -> `2.5E+8`). - Removing an explicitly-provided zero exponent (`2.5E0` -> `2.5`). Services **may** perform additional normalization based on its own needs and the internal decimal implementation selected, such as shifting the decimal point and exponent value together (example: `2.5E-1` <-> `0.25`). Additionally, services **may** preserve trailing zeroes in the fraction to indicate increased precision, but are not required to do so. Note that only the `.` character is supported to divide the integer and the fraction; `,` **should not** be supported regardless of locale. Additionally, thousand separators **should not** be supported. If a service does support them, values **must** be normalized. The ENBF grammar is: DecimalString = '' | [Sign] Significand [Exponent]; Sign = '+' | '-'; Significand = Digits '.' | [Digits] '.' Digits; Exponent = ('e' | 'E') [Sign] Digits; Digits = { '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' }; Services **should** clearly document the range of supported values, the maximum supported precision (total number of digits), and, if applicable, the scale (number of digits after the decimal point), as well as how it behaves when receiving out-of-bounds values. Services **may** choose to accept values passed as input even when the value has a higher precision or scale than the service supports, and **should** round the value to fit the supported scale. Alternatively, the service **may** error with `400 Bad Request` (`INVALID_ARGUMENT` in gRPC) if precision would be lost. Services **should** error with `400 Bad Request` (`INVALID_ARGUMENT` in gRPC) if the service receives a value outside of the supported range. */
|
|
169
33
|
value?: string;
|
|
170
34
|
}
|
|
171
|
-
interface DualRegional {
|
|
172
|
-
/** The [location name](https://cloud.google.com/storage/docs/locations#available-locations) where the data is stored. For example: "asia1" for dual region. */
|
|
173
|
-
name?: string;
|
|
174
|
-
}
|
|
175
|
-
interface EstimateCostScenarioForBillingAccountRequest {
|
|
176
|
-
/** The scenario to estimate costs for. */
|
|
177
|
-
costScenario?: CostScenario;
|
|
178
|
-
}
|
|
179
|
-
interface EstimateCostScenarioForBillingAccountResponse {
|
|
180
|
-
/** The result of the cost estimation. */
|
|
181
|
-
costEstimationResult?: CostEstimationResult;
|
|
182
|
-
}
|
|
183
|
-
interface EstimateCostScenarioWithListPriceRequest {
|
|
184
|
-
/** The scenario to estimate costs for. */
|
|
185
|
-
costScenario?: CostScenario;
|
|
186
|
-
}
|
|
187
|
-
interface EstimateCostScenarioWithListPriceResponse {
|
|
188
|
-
/** The result of the cost estimation. */
|
|
189
|
-
costEstimationResult?: CostEstimationResult;
|
|
190
|
-
}
|
|
191
|
-
interface EstimationTimePoint {
|
|
192
|
-
/** The point in time, relative to the start of the time frame covered by the cost estimate. */
|
|
193
|
-
estimationTimeFrameOffset?: string;
|
|
194
|
-
}
|
|
195
35
|
interface GoogleCloudBillingBillingaccountpricesV1betaAggregationInfo {
|
|
196
36
|
/** Interval at which usage is aggregated to compute cost. Example: "MONTHLY" interval indicates that usage is aggregated every month. */
|
|
197
37
|
interval?: string;
|
|
@@ -521,28 +361,6 @@ declare namespace gapi.client {
|
|
|
521
361
|
/** Resource name for the SKU group. Example: "skuGroups/0e6403d1-4694-44d2-a696-7a78b1a69301". */
|
|
522
362
|
name?: string;
|
|
523
363
|
}
|
|
524
|
-
interface GuestAccelerator {
|
|
525
|
-
/** The number of the guest accelerator cards exposed to each instance. */
|
|
526
|
-
acceleratorCount?: string;
|
|
527
|
-
/** The type of the guest accelerator cards. For example: "nvidia-tesla-t4". */
|
|
528
|
-
acceleratorType?: string;
|
|
529
|
-
}
|
|
530
|
-
interface InterRegionEgress {
|
|
531
|
-
/** Which [region](https://cloud.google.com/compute/docs/regions-zones) the data is transferred to. */
|
|
532
|
-
destinationRegion?: string;
|
|
533
|
-
/** VM to VM data transfer usage. The expected units such are GiBy/s, By/s, and so on. */
|
|
534
|
-
egressRate?: Usage;
|
|
535
|
-
/** Which [region](https://cloud.google.com/compute/docs/regions-zones) the data is transferred from. */
|
|
536
|
-
sourceRegion?: string;
|
|
537
|
-
}
|
|
538
|
-
interface IntraRegionEgress {
|
|
539
|
-
/** VM to VM data transfer usage. The expected are GiBy/s, By/s, and so on. */
|
|
540
|
-
egressRate?: Usage;
|
|
541
|
-
}
|
|
542
|
-
interface MachineType {
|
|
543
|
-
customMachineType?: CustomMachineType;
|
|
544
|
-
predefinedMachineType?: PredefinedMachineType;
|
|
545
|
-
}
|
|
546
364
|
interface Money {
|
|
547
365
|
/** The three-letter currency code defined in ISO 4217. */
|
|
548
366
|
currencyCode?: string;
|
|
@@ -551,168 +369,6 @@ declare namespace gapi.client {
|
|
|
551
369
|
/** The whole units of the amount. For example if `currencyCode` is `"USD"`, then 1 unit is one US dollar. */
|
|
552
370
|
units?: string;
|
|
553
371
|
}
|
|
554
|
-
interface MultiRegional {
|
|
555
|
-
/** The [location name](https://cloud.google.com/storage/docs/locations#available-locations) where the data is stored. For example: "us" for multi-region. */
|
|
556
|
-
name?: string;
|
|
557
|
-
}
|
|
558
|
-
interface PersistentDisk {
|
|
559
|
-
/** Specifies the size of disk. Must be at least 10 GB. */
|
|
560
|
-
diskSize?: Usage;
|
|
561
|
-
/** The [disk type](https://cloud.google.com/compute/docs/disks#disk-types). For example: "pd-standard". */
|
|
562
|
-
diskType?: string;
|
|
563
|
-
/** Indicates how many IOPS to provision for the disk for extreme persistent disks. This sets the number of I/O operations per second that the disk can handle. Values must be between 10,000 and 120,000. */
|
|
564
|
-
provisionedIops?: Usage;
|
|
565
|
-
/** The geographic scope of the disk. Defaults to `SCOPE_ZONAL` if not specified. */
|
|
566
|
-
scope?: string;
|
|
567
|
-
}
|
|
568
|
-
interface PredefinedMachineType {
|
|
569
|
-
/** The [machine type](https://cloud.google.com/compute/docs/machine-types). For example: "n1-standard1". */
|
|
570
|
-
machineType?: string;
|
|
571
|
-
}
|
|
572
|
-
interface PremiumTierEgressWorkload {
|
|
573
|
-
/** Where the data is sent to. */
|
|
574
|
-
destinationContinent?: string;
|
|
575
|
-
/** Premium Tier Data Transfer usage. The expected units are GiBy/s, By/s, and so on, based on [The Unified Code for Units of Measure](https://ucum.org/ucum.html) standard. */
|
|
576
|
-
egressRate?: Usage;
|
|
577
|
-
/** Which [region](https://cloud.google.com/compute/docs/regions-zones) the data comes from. */
|
|
578
|
-
sourceRegion?: string;
|
|
579
|
-
}
|
|
580
|
-
interface Price {
|
|
581
|
-
/** The timestamp within the estimation time frame when the price was set. */
|
|
582
|
-
effectiveTime?: EstimationTimePoint;
|
|
583
|
-
/** The type of price. Possible values: "RATE" */
|
|
584
|
-
priceType?: string;
|
|
585
|
-
/** A set of tiered rates. */
|
|
586
|
-
rate?: Rate;
|
|
587
|
-
}
|
|
588
|
-
interface Rate {
|
|
589
|
-
/** The service tiers. */
|
|
590
|
-
tiers?: RateTier[];
|
|
591
|
-
/** The SKU's pricing unit. For example, if the tier price is $1 per 1000000 Bytes, then this field will show 'By'. The `start_amount` field in each tier will be in this unit. */
|
|
592
|
-
unit?: string;
|
|
593
|
-
/** The SKU's count for the pricing unit. For example, if the tier price is $1 per 1000000 Bytes, then this column will show 1000000. */
|
|
594
|
-
unitCount?: number;
|
|
595
|
-
}
|
|
596
|
-
interface RateTier {
|
|
597
|
-
/** The price for this tier. */
|
|
598
|
-
price?: Money;
|
|
599
|
-
/** The magnitude of usage in which the tier interval begins. Example: "From 100 GiBi the price is $1 per byte" implies `start_amount` = 100 */
|
|
600
|
-
startAmount?: number;
|
|
601
|
-
}
|
|
602
|
-
interface Regional {
|
|
603
|
-
/** The [location name](https://cloud.google.com/storage/docs/locations#available-locations). For example: "us-central1" for region. */
|
|
604
|
-
name?: string;
|
|
605
|
-
}
|
|
606
|
-
interface ScenarioConfig {
|
|
607
|
-
/** Time frame for the estimate. Workloads must specify usage for this duration. Duration must be at least 1 hour (3,600 seconds) and at most 10 years (315,360,000 seconds). The calculations for years and months are based on a 730-hour (2,628,000-second) month. For durations longer than one month (2,628,000 seconds), the duration is rounded up to the next month, so the estimate shows you the costs for full months. For example, a duration of 3,232,800 seconds (roughly 5 weeks) is rounded up to 2 months. */
|
|
608
|
-
estimateDuration?: string;
|
|
609
|
-
}
|
|
610
|
-
interface SegmentCostEstimate {
|
|
611
|
-
/** Estimated costs for each commitment. */
|
|
612
|
-
commitmentCostEstimates?: CommitmentCostEstimate[];
|
|
613
|
-
/** Timestamp for the start of the segment. */
|
|
614
|
-
segmentStartTime?: EstimationTimePoint;
|
|
615
|
-
/** Total estimated costs for the time segment. */
|
|
616
|
-
segmentTotalCostEstimate?: CostEstimate;
|
|
617
|
-
/** Estimated costs for each workload. */
|
|
618
|
-
workloadCostEstimates?: WorkloadCostEstimate[];
|
|
619
|
-
}
|
|
620
|
-
interface Sku {
|
|
621
|
-
/** The display name for the SKU. Example: A2 Instance Core running in Americas */
|
|
622
|
-
displayName?: string;
|
|
623
|
-
/** A timeline of prices for a SKU in chronological order. Note: The API currently only supports using a constant price for the entire estimation time frame so this list will contain a single value. */
|
|
624
|
-
prices?: Price[];
|
|
625
|
-
/** The resource name for the SKU. Example: "services/DA34-426B-A397/skus/AA95-CD31-42FE" */
|
|
626
|
-
sku?: string;
|
|
627
|
-
}
|
|
628
|
-
interface SkuCostEstimate {
|
|
629
|
-
/** The estimated cost for the usage on this SKU. */
|
|
630
|
-
costEstimate?: CostEstimate;
|
|
631
|
-
/** The resource name for the SKU. Example: "services/DA34-426B-A397/skus/AA95-CD31-42FE" More information about the SKU can be found in the `skus` field of the `CostEstimationResult`. */
|
|
632
|
-
sku?: string;
|
|
633
|
-
/** The amount of usage on this SKU. */
|
|
634
|
-
usageAmount?: number;
|
|
635
|
-
/** The unit for the usage on this SKU. */
|
|
636
|
-
usageUnit?: string;
|
|
637
|
-
}
|
|
638
|
-
interface StandardTierEgressWorkload {
|
|
639
|
-
/** Standard Tier Data Transfer usage. The expected units are GiBy/s, By/s, and so on, based on the [The Unified Code for Units of Measure](https://ucum.org/ucum.html) standard. */
|
|
640
|
-
egressRate?: Usage;
|
|
641
|
-
/** Which [region](https://cloud.google.com/compute/docs/regions-zones) the data is transferred from. */
|
|
642
|
-
sourceRegion?: string;
|
|
643
|
-
}
|
|
644
|
-
interface Usage {
|
|
645
|
-
/** A timeline of usage rates over the estimate interval. */
|
|
646
|
-
usageRateTimeline?: UsageRateTimeline;
|
|
647
|
-
}
|
|
648
|
-
interface UsageRateTimeline {
|
|
649
|
-
/** The unit for the usage rate in each timeline entry. If you provide an incorrect unit for an instance, the correct unit is provided in the error message. The supported units are a subset of [The Unified Code for Units of Measure](https://ucum.org/ucum.html) standard: * **Time units (TIME-UNIT)** * `s` second * `min` minute * `h` hour * `d` day * `wk` week * `mo` month * `yr` year * `ms` millisecond * `us` microsecond * `ns` nanosecond * **Basic storage units (BASIC-STORAGE-UNIT)** * `bit` bit * `By` byte * **Count units (COUNT-UNIT)** * `count` count * **Prefixes (PREFIX)** * `k` kilo (10^3) * `M` mega (10^6) * `G` giga (10^9) * `T` tera (10^12) * `P` peta (10^15) * `Ki` kibi (2^10) * `Mi` mebi (2^20) * `Gi` gibi (2^30) * `Ti` tebi (2^40) * `Pi` pebi (2^50) **Grammar** The grammar also includes these connectors: * `/` division or ratio (as an infix operator). For example: `kBy/{email}` or `MiBy/10ms`. * `.` multiplication or composition (as an infix operator). For example: `GBy.d` or `k{watt}.h`. The grammar for a unit is as follows: ``` Expression = Component { "." Component } { "/" Component } ; Component = ( [ PREFIX ] UNIT | "%" ) [ Annotation ] | Annotation | "1" ; UNIT = TIME-UNIT | STORAGE-UNIT | DATA-UNIT | COUNT-UNIT Annotation = "{" NAME "}" ; ``` Examples: * Request per second: `1/s` or `{requests}/s` * GibiBytes: `GiBy` * GibiBytes * seconds: `GiBy.s` */
|
|
650
|
-
unit?: string;
|
|
651
|
-
/** The timeline entries. Each entry has a start time and usage rate. The start time specifies the effective time of the usage rate. The entries must be sorted by start time in an increasing order. */
|
|
652
|
-
usageRateTimelineEntries?: UsageRateTimelineEntry[];
|
|
653
|
-
}
|
|
654
|
-
interface UsageRateTimelineEntry {
|
|
655
|
-
/** The effective time for this entry. The usage rate is in effect starting at this time until the effective time of the subsequent entry in the timeline. The last entry defines the usage rate until the end of the `Usage` time frame. Must correspond to an integer number of hours. */
|
|
656
|
-
effectiveTime?: EstimationTimePoint;
|
|
657
|
-
/** The usage rate. */
|
|
658
|
-
usageRate?: number;
|
|
659
|
-
}
|
|
660
|
-
interface VlanAttachment {
|
|
661
|
-
/** Capacities in the [pricing table](https://cloud.google.com/vpc/network-pricing#interconnect-pricing) Examples of capacity are: 50/100/200/300/400/500-Mbps, 1/2/5/10/20/50-Gbps. */
|
|
662
|
-
bandwidth?: string;
|
|
663
|
-
/** VLAN usage. This is specified as a unitless quantity which indicates the number of VLAN attachment used in interconnect. */
|
|
664
|
-
vlanCount?: Usage;
|
|
665
|
-
}
|
|
666
|
-
interface VmResourceBasedCud {
|
|
667
|
-
/** Guest accelerator, known as GPU. */
|
|
668
|
-
guestAccelerator?: GuestAccelerator;
|
|
669
|
-
/** The machine series for CUD. For example: "n1" for general purpose N1 machine type commitments. "n2" for general purpose N2 machine type commitments. "e2" for general purpose E2 machine type commitments. "n2d" for general purpose N2D machine type commitments. "t2d" for general purpose T2D machine type commitments. "c2"/"c2d" for compute-optimized commitments. "m1"/"m2" for the memory-optimized commitments. "a2' for the accelerator-optimized commitments. */
|
|
670
|
-
machineSeries?: string;
|
|
671
|
-
/** Memory size of the VM in GB (2^30 bytes). Must be an increment of 0.25 (256 MB). */
|
|
672
|
-
memorySizeGb?: number;
|
|
673
|
-
/** Commitment usage plan. */
|
|
674
|
-
plan?: string;
|
|
675
|
-
/** The region where the VM runs. For example: "us-central1" */
|
|
676
|
-
region?: string;
|
|
677
|
-
/** The number of vCPUs. The number of vCPUs must be an integer of 0 or more and can be even or odd. */
|
|
678
|
-
virtualCpuCount?: string;
|
|
679
|
-
}
|
|
680
|
-
interface VmToVmEgressWorkload {
|
|
681
|
-
interRegionEgress?: InterRegionEgress;
|
|
682
|
-
intraRegionEgress?: IntraRegionEgress;
|
|
683
|
-
}
|
|
684
|
-
interface Workload {
|
|
685
|
-
/** Usage on Google Cloud CDN Data Transfer. */
|
|
686
|
-
cloudCdnEgressWorkload?: CloudCdnEgressWorkload;
|
|
687
|
-
/** Usage on Google Cloud CDN. */
|
|
688
|
-
cloudCdnWorkload?: CloudCdnWorkload;
|
|
689
|
-
/** Usage on Google Cloud Interconnect Data Transfer. */
|
|
690
|
-
cloudInterconnectEgressWorkload?: CloudInterconnectEgressWorkload;
|
|
691
|
-
/** Usage on Google Cloud Interconnect. */
|
|
692
|
-
cloudInterconnectWorkload?: CloudInterconnectWorkload;
|
|
693
|
-
/** Usage on Cloud Storage Data Transfer. */
|
|
694
|
-
cloudStorageEgressWorkload?: CloudStorageEgressWorkload;
|
|
695
|
-
/** Usage on Google Cloud Storage. */
|
|
696
|
-
cloudStorageWorkload?: CloudStorageWorkload;
|
|
697
|
-
/** Usage of a Google Compute Engine Virtual Machine. */
|
|
698
|
-
computeVmWorkload?: ComputeVmWorkload;
|
|
699
|
-
/** Required. A name for this workload. All workloads in a `CostScenario` must have a unique `name`. Each `name` may be at most 128 characters long. */
|
|
700
|
-
name?: string;
|
|
701
|
-
/** Usage on Premium Tier Internet Data Transfer. */
|
|
702
|
-
premiumTierEgressWorkload?: PremiumTierEgressWorkload;
|
|
703
|
-
/** Usage on Standard Tier Internet Data Transfer. */
|
|
704
|
-
standardTierEgressWorkload?: StandardTierEgressWorkload;
|
|
705
|
-
/** Usage on VM to VM Data Transfer. */
|
|
706
|
-
vmToVmEgressWorkload?: VmToVmEgressWorkload;
|
|
707
|
-
}
|
|
708
|
-
interface WorkloadCostEstimate {
|
|
709
|
-
/** The name of the workload, as specified in the `CostScenario`. */
|
|
710
|
-
name?: string;
|
|
711
|
-
/** Estimated costs for each SKU in the workload. */
|
|
712
|
-
skuCostEstimates?: SkuCostEstimate[];
|
|
713
|
-
/** Total estimated costs for the workload. */
|
|
714
|
-
workloadTotalCostEstimate?: CostEstimate;
|
|
715
|
-
}
|
|
716
372
|
interface ServicesResource {
|
|
717
373
|
/** Gets a Google Cloud service visible to a billing account. */
|
|
718
374
|
get(request?: {
|
|
@@ -1025,64 +681,6 @@ declare namespace gapi.client {
|
|
|
1025
681
|
prices: PricesResource;
|
|
1026
682
|
}
|
|
1027
683
|
interface BillingAccountsResource {
|
|
1028
|
-
/** Use custom pricing in the estimate, using a `CostScenario` with a defined `billingAccount`. */
|
|
1029
|
-
estimateCostScenario(request: {
|
|
1030
|
-
/** V1 error format. */
|
|
1031
|
-
'$.xgafv'?: string;
|
|
1032
|
-
/** OAuth access token. */
|
|
1033
|
-
access_token?: string;
|
|
1034
|
-
/** Data format for response. */
|
|
1035
|
-
alt?: string;
|
|
1036
|
-
/** Resource name of the billing account for the cost estimate. The resource name has the form `billingAccounts/{billing_account_id}`. For example, `billingAccounts/012345-567890-ABCDEF` is the resource name for billing account `012345-567890-ABCDEF`. Must be specified. */
|
|
1037
|
-
billingAccount: string;
|
|
1038
|
-
/** JSONP */
|
|
1039
|
-
callback?: string;
|
|
1040
|
-
/** Selector specifying which fields to include in a partial response. */
|
|
1041
|
-
fields?: string;
|
|
1042
|
-
/** 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. */
|
|
1043
|
-
key?: string;
|
|
1044
|
-
/** OAuth 2.0 token for the current user. */
|
|
1045
|
-
oauth_token?: string;
|
|
1046
|
-
/** Returns response with indentations and line breaks. */
|
|
1047
|
-
prettyPrint?: boolean;
|
|
1048
|
-
/** 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. */
|
|
1049
|
-
quotaUser?: string;
|
|
1050
|
-
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1051
|
-
upload_protocol?: string;
|
|
1052
|
-
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1053
|
-
uploadType?: string;
|
|
1054
|
-
/** Request body */
|
|
1055
|
-
resource: EstimateCostScenarioForBillingAccountRequest;
|
|
1056
|
-
}): Request<EstimateCostScenarioForBillingAccountResponse>;
|
|
1057
|
-
estimateCostScenario(
|
|
1058
|
-
request: {
|
|
1059
|
-
/** V1 error format. */
|
|
1060
|
-
'$.xgafv'?: string;
|
|
1061
|
-
/** OAuth access token. */
|
|
1062
|
-
access_token?: string;
|
|
1063
|
-
/** Data format for response. */
|
|
1064
|
-
alt?: string;
|
|
1065
|
-
/** Resource name of the billing account for the cost estimate. The resource name has the form `billingAccounts/{billing_account_id}`. For example, `billingAccounts/012345-567890-ABCDEF` is the resource name for billing account `012345-567890-ABCDEF`. Must be specified. */
|
|
1066
|
-
billingAccount: string;
|
|
1067
|
-
/** JSONP */
|
|
1068
|
-
callback?: string;
|
|
1069
|
-
/** Selector specifying which fields to include in a partial response. */
|
|
1070
|
-
fields?: string;
|
|
1071
|
-
/** 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. */
|
|
1072
|
-
key?: string;
|
|
1073
|
-
/** OAuth 2.0 token for the current user. */
|
|
1074
|
-
oauth_token?: string;
|
|
1075
|
-
/** Returns response with indentations and line breaks. */
|
|
1076
|
-
prettyPrint?: boolean;
|
|
1077
|
-
/** 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. */
|
|
1078
|
-
quotaUser?: string;
|
|
1079
|
-
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1080
|
-
upload_protocol?: string;
|
|
1081
|
-
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1082
|
-
uploadType?: string;
|
|
1083
|
-
},
|
|
1084
|
-
body: EstimateCostScenarioForBillingAccountRequest,
|
|
1085
|
-
): Request<EstimateCostScenarioForBillingAccountResponse>;
|
|
1086
684
|
services: ServicesResource;
|
|
1087
685
|
skuGroups: SkuGroupsResource;
|
|
1088
686
|
skus: SkusResource;
|
|
@@ -1276,69 +874,11 @@ declare namespace gapi.client {
|
|
|
1276
874
|
price: PriceResource;
|
|
1277
875
|
prices: PricesResource;
|
|
1278
876
|
}
|
|
1279
|
-
interface V1betaResource {
|
|
1280
|
-
/** Estimate list prices using a `CostScenario` without a defined `billingAccount`. */
|
|
1281
|
-
estimateCostScenario(request: {
|
|
1282
|
-
/** V1 error format. */
|
|
1283
|
-
'$.xgafv'?: string;
|
|
1284
|
-
/** OAuth access token. */
|
|
1285
|
-
access_token?: string;
|
|
1286
|
-
/** Data format for response. */
|
|
1287
|
-
alt?: string;
|
|
1288
|
-
/** JSONP */
|
|
1289
|
-
callback?: string;
|
|
1290
|
-
/** Selector specifying which fields to include in a partial response. */
|
|
1291
|
-
fields?: string;
|
|
1292
|
-
/** 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. */
|
|
1293
|
-
key?: string;
|
|
1294
|
-
/** OAuth 2.0 token for the current user. */
|
|
1295
|
-
oauth_token?: string;
|
|
1296
|
-
/** Returns response with indentations and line breaks. */
|
|
1297
|
-
prettyPrint?: boolean;
|
|
1298
|
-
/** 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. */
|
|
1299
|
-
quotaUser?: string;
|
|
1300
|
-
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1301
|
-
upload_protocol?: string;
|
|
1302
|
-
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1303
|
-
uploadType?: string;
|
|
1304
|
-
/** Request body */
|
|
1305
|
-
resource: EstimateCostScenarioWithListPriceRequest;
|
|
1306
|
-
}): Request<EstimateCostScenarioWithListPriceResponse>;
|
|
1307
|
-
estimateCostScenario(
|
|
1308
|
-
request: {
|
|
1309
|
-
/** V1 error format. */
|
|
1310
|
-
'$.xgafv'?: string;
|
|
1311
|
-
/** OAuth access token. */
|
|
1312
|
-
access_token?: string;
|
|
1313
|
-
/** Data format for response. */
|
|
1314
|
-
alt?: string;
|
|
1315
|
-
/** JSONP */
|
|
1316
|
-
callback?: string;
|
|
1317
|
-
/** Selector specifying which fields to include in a partial response. */
|
|
1318
|
-
fields?: string;
|
|
1319
|
-
/** 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. */
|
|
1320
|
-
key?: string;
|
|
1321
|
-
/** OAuth 2.0 token for the current user. */
|
|
1322
|
-
oauth_token?: string;
|
|
1323
|
-
/** Returns response with indentations and line breaks. */
|
|
1324
|
-
prettyPrint?: boolean;
|
|
1325
|
-
/** 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. */
|
|
1326
|
-
quotaUser?: string;
|
|
1327
|
-
/** Upload protocol for media (e.g. "raw", "multipart"). */
|
|
1328
|
-
upload_protocol?: string;
|
|
1329
|
-
/** Legacy upload protocol for media (e.g. "media", "multipart"). */
|
|
1330
|
-
uploadType?: string;
|
|
1331
|
-
},
|
|
1332
|
-
body: EstimateCostScenarioWithListPriceRequest,
|
|
1333
|
-
): Request<EstimateCostScenarioWithListPriceResponse>;
|
|
1334
|
-
}
|
|
1335
877
|
|
|
1336
878
|
const billingAccounts: BillingAccountsResource;
|
|
1337
879
|
|
|
1338
880
|
const skuGroups: SkuGroupsResource;
|
|
1339
881
|
|
|
1340
882
|
const skus: SkusResource;
|
|
1341
|
-
|
|
1342
|
-
const v1beta: V1betaResource;
|
|
1343
883
|
}
|
|
1344
884
|
}
|
package/package.json
CHANGED
package/readme.md
CHANGED
|
@@ -75,13 +75,6 @@ gapi.auth.authorize(
|
|
|
75
75
|
After that you can use Cloud Billing API resources: <!-- TODO: make this work for multiple namespaces -->
|
|
76
76
|
|
|
77
77
|
```typescript
|
|
78
|
-
/*
|
|
79
|
-
Use custom pricing in the estimate, using a `CostScenario` with a defined `billingAccount`.
|
|
80
|
-
*/
|
|
81
|
-
await gapi.client.cloudbilling.billingAccounts.estimateCostScenario({
|
|
82
|
-
billingAccount: 'billingAccount',
|
|
83
|
-
});
|
|
84
|
-
|
|
85
78
|
/*
|
|
86
79
|
Gets a publicly listed SKU group.
|
|
87
80
|
*/
|
|
@@ -91,9 +84,4 @@ await gapi.client.cloudbilling.skuGroups.get({name: 'name'});
|
|
|
91
84
|
Lists all publicly listed SKU groups.
|
|
92
85
|
*/
|
|
93
86
|
await gapi.client.cloudbilling.skuGroups.list({});
|
|
94
|
-
|
|
95
|
-
/*
|
|
96
|
-
Estimate list prices using a `CostScenario` without a defined `billingAccount`.
|
|
97
|
-
*/
|
|
98
|
-
await gapi.client.cloudbilling.estimateCostScenario({});
|
|
99
87
|
```
|