@pulumi/ns1 3.6.0 → 3.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10,41 +10,47 @@ import * as outputs from "./types/output";
10
10
  * import * as ns1 from "@pulumi/ns1";
11
11
  *
12
12
  * // Get query usage data for the given timeframe
13
- * const queries = new ns1.index.BillingUsage("queries", {
13
+ * const queries = ns1.getBillingUsage({
14
14
  * metricType: "queries",
15
- * from: 1731605824,
16
- * to: 1734197824,
15
+ * from: 1738368000,
16
+ * to: 1740787199,
17
17
  * });
18
18
  * // Get account limits data for the given timeframe
19
- * const limits = new ns1.index.BillingUsage("limits", {
19
+ * const limits = ns1.getBillingUsage({
20
20
  * metricType: "limits",
21
- * from: 1731605824,
22
- * to: 1734197824,
21
+ * from: 1738368000,
22
+ * to: 1740787199,
23
23
  * });
24
24
  * // Get RUM decisions usage data for the given timeframe
25
- * const decisions = new ns1.index.BillingUsage("decisions", {
25
+ * const decisions = ns1.getBillingUsage({
26
26
  * metricType: "decisions",
27
- * from: 1731605824,
28
- * to: 1734197824,
27
+ * from: 1738368000,
28
+ * to: 1740787199,
29
29
  * });
30
30
  * // Get filter chains usage data
31
- * const filterChains = new ns1.index.BillingUsage("filter_chains", {metricType: "filter-chains"});
31
+ * const filterChains = ns1.getBillingUsage({
32
+ * metricType: "filter-chains",
33
+ * });
32
34
  * // Get monitoring jobs usage data
33
- * const monitors = new ns1.index.BillingUsage("monitors", {metricType: "monitors"});
35
+ * const monitors = ns1.getBillingUsage({
36
+ * metricType: "monitors",
37
+ * });
34
38
  * // Get records usage data
35
- * const records = new ns1.index.BillingUsage("records", {metricType: "records"});
36
- * export const totalQueries = queries.cleanQueries;
37
- * export const totalDdosQueries = queries.ddosQueries;
38
- * export const totalNxdResponses = queries.nxdResponses;
39
- * export const queriesLimit = limits.queriesLimit;
40
- * export const totalDecisions = decisions.totalUsage;
41
- * export const decisionsLimit = limits.decisionsLimit;
42
- * export const totalFilterChains = filterChains.totalUsage;
43
- * export const filterChainsLimit = limits.filterChainsLimit;
44
- * export const totalMonitors = monitors.totalUsage;
45
- * export const monitorsLimit = limits.monitorsLimit;
46
- * export const totalRecords = records.totalUsage;
47
- * export const recordsLimit = limits.recordsLimit;
39
+ * const records = ns1.getBillingUsage({
40
+ * metricType: "records",
41
+ * });
42
+ * export const totalQueries = queries.then(queries => queries.cleanQueries);
43
+ * export const totalDdosQueries = queries.then(queries => queries.ddosQueries);
44
+ * export const totalNxdResponses = queries.then(queries => queries.nxdResponses);
45
+ * export const queriesLimit = limits.then(limits => limits.queriesLimit);
46
+ * export const totalDecisions = decisions.then(decisions => decisions.totalUsage);
47
+ * export const decisionsLimit = limits.then(limits => limits.decisionsLimit);
48
+ * export const totalFilterChains = filterChains.then(filterChains => filterChains.totalUsage);
49
+ * export const filterChainsLimit = limits.then(limits => limits.filterChainsLimit);
50
+ * export const totalMonitors = monitors.then(monitors => monitors.totalUsage);
51
+ * export const monitorsLimit = limits.then(limits => limits.monitorsLimit);
52
+ * export const totalRecords = records.then(records => records.totalUsage);
53
+ * export const recordsLimit = limits.then(limits => limits.recordsLimit);
48
54
  * ```
49
55
  */
50
56
  export declare function getBillingUsage(args: GetBillingUsageArgs, opts?: pulumi.InvokeOptions): Promise<GetBillingUsageResult>;
@@ -55,7 +61,7 @@ export interface GetBillingUsageArgs {
55
61
  /**
56
62
  * The start timestamp for the data range in Unix epoch format.
57
63
  */
58
- from: number;
64
+ from?: number;
59
65
  /**
60
66
  * The type of billing metric to retrieve. Must be one of: `queries`, `limits`, `decisions`, `filter-chains`, `monitors`, `records`.
61
67
  */
@@ -63,7 +69,7 @@ export interface GetBillingUsageArgs {
63
69
  /**
64
70
  * The end timestamp for the data range in Unix epoch format.
65
71
  */
66
- to: number;
72
+ to?: number;
67
73
  }
68
74
  /**
69
75
  * A collection of values returned by getBillingUsage.
@@ -97,7 +103,7 @@ export interface GetBillingUsageResult {
97
103
  * (Computed) The filter chains limit for this billing cycle.
98
104
  */
99
105
  readonly filterChainsLimit: number;
100
- readonly from: number;
106
+ readonly from?: number;
101
107
  /**
102
108
  * The provider-assigned unique ID for this managed resource.
103
109
  */
@@ -127,7 +133,7 @@ export interface GetBillingUsageResult {
127
133
  * (Computed) The records limit for this billing cycle.
128
134
  */
129
135
  readonly recordsLimit: number;
130
- readonly to: number;
136
+ readonly to?: number;
131
137
  /**
132
138
  * (Computed) The total usage count for the metric. Available for `decisions`, `filter-chains`, `monitors`, and `records` metrics.
133
139
  */
@@ -143,41 +149,47 @@ export interface GetBillingUsageResult {
143
149
  * import * as ns1 from "@pulumi/ns1";
144
150
  *
145
151
  * // Get query usage data for the given timeframe
146
- * const queries = new ns1.index.BillingUsage("queries", {
152
+ * const queries = ns1.getBillingUsage({
147
153
  * metricType: "queries",
148
- * from: 1731605824,
149
- * to: 1734197824,
154
+ * from: 1738368000,
155
+ * to: 1740787199,
150
156
  * });
151
157
  * // Get account limits data for the given timeframe
152
- * const limits = new ns1.index.BillingUsage("limits", {
158
+ * const limits = ns1.getBillingUsage({
153
159
  * metricType: "limits",
154
- * from: 1731605824,
155
- * to: 1734197824,
160
+ * from: 1738368000,
161
+ * to: 1740787199,
156
162
  * });
157
163
  * // Get RUM decisions usage data for the given timeframe
158
- * const decisions = new ns1.index.BillingUsage("decisions", {
164
+ * const decisions = ns1.getBillingUsage({
159
165
  * metricType: "decisions",
160
- * from: 1731605824,
161
- * to: 1734197824,
166
+ * from: 1738368000,
167
+ * to: 1740787199,
162
168
  * });
163
169
  * // Get filter chains usage data
164
- * const filterChains = new ns1.index.BillingUsage("filter_chains", {metricType: "filter-chains"});
170
+ * const filterChains = ns1.getBillingUsage({
171
+ * metricType: "filter-chains",
172
+ * });
165
173
  * // Get monitoring jobs usage data
166
- * const monitors = new ns1.index.BillingUsage("monitors", {metricType: "monitors"});
174
+ * const monitors = ns1.getBillingUsage({
175
+ * metricType: "monitors",
176
+ * });
167
177
  * // Get records usage data
168
- * const records = new ns1.index.BillingUsage("records", {metricType: "records"});
169
- * export const totalQueries = queries.cleanQueries;
170
- * export const totalDdosQueries = queries.ddosQueries;
171
- * export const totalNxdResponses = queries.nxdResponses;
172
- * export const queriesLimit = limits.queriesLimit;
173
- * export const totalDecisions = decisions.totalUsage;
174
- * export const decisionsLimit = limits.decisionsLimit;
175
- * export const totalFilterChains = filterChains.totalUsage;
176
- * export const filterChainsLimit = limits.filterChainsLimit;
177
- * export const totalMonitors = monitors.totalUsage;
178
- * export const monitorsLimit = limits.monitorsLimit;
179
- * export const totalRecords = records.totalUsage;
180
- * export const recordsLimit = limits.recordsLimit;
178
+ * const records = ns1.getBillingUsage({
179
+ * metricType: "records",
180
+ * });
181
+ * export const totalQueries = queries.then(queries => queries.cleanQueries);
182
+ * export const totalDdosQueries = queries.then(queries => queries.ddosQueries);
183
+ * export const totalNxdResponses = queries.then(queries => queries.nxdResponses);
184
+ * export const queriesLimit = limits.then(limits => limits.queriesLimit);
185
+ * export const totalDecisions = decisions.then(decisions => decisions.totalUsage);
186
+ * export const decisionsLimit = limits.then(limits => limits.decisionsLimit);
187
+ * export const totalFilterChains = filterChains.then(filterChains => filterChains.totalUsage);
188
+ * export const filterChainsLimit = limits.then(limits => limits.filterChainsLimit);
189
+ * export const totalMonitors = monitors.then(monitors => monitors.totalUsage);
190
+ * export const monitorsLimit = limits.then(limits => limits.monitorsLimit);
191
+ * export const totalRecords = records.then(records => records.totalUsage);
192
+ * export const recordsLimit = limits.then(limits => limits.recordsLimit);
181
193
  * ```
182
194
  */
183
195
  export declare function getBillingUsageOutput(args: GetBillingUsageOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetBillingUsageResult>;
@@ -188,7 +200,7 @@ export interface GetBillingUsageOutputArgs {
188
200
  /**
189
201
  * The start timestamp for the data range in Unix epoch format.
190
202
  */
191
- from: pulumi.Input<number>;
203
+ from?: pulumi.Input<number>;
192
204
  /**
193
205
  * The type of billing metric to retrieve. Must be one of: `queries`, `limits`, `decisions`, `filter-chains`, `monitors`, `records`.
194
206
  */
@@ -196,5 +208,5 @@ export interface GetBillingUsageOutputArgs {
196
208
  /**
197
209
  * The end timestamp for the data range in Unix epoch format.
198
210
  */
199
- to: pulumi.Input<number>;
211
+ to?: pulumi.Input<number>;
200
212
  }
@@ -15,41 +15,47 @@ const utilities = require("./utilities");
15
15
  * import * as ns1 from "@pulumi/ns1";
16
16
  *
17
17
  * // Get query usage data for the given timeframe
18
- * const queries = new ns1.index.BillingUsage("queries", {
18
+ * const queries = ns1.getBillingUsage({
19
19
  * metricType: "queries",
20
- * from: 1731605824,
21
- * to: 1734197824,
20
+ * from: 1738368000,
21
+ * to: 1740787199,
22
22
  * });
23
23
  * // Get account limits data for the given timeframe
24
- * const limits = new ns1.index.BillingUsage("limits", {
24
+ * const limits = ns1.getBillingUsage({
25
25
  * metricType: "limits",
26
- * from: 1731605824,
27
- * to: 1734197824,
26
+ * from: 1738368000,
27
+ * to: 1740787199,
28
28
  * });
29
29
  * // Get RUM decisions usage data for the given timeframe
30
- * const decisions = new ns1.index.BillingUsage("decisions", {
30
+ * const decisions = ns1.getBillingUsage({
31
31
  * metricType: "decisions",
32
- * from: 1731605824,
33
- * to: 1734197824,
32
+ * from: 1738368000,
33
+ * to: 1740787199,
34
34
  * });
35
35
  * // Get filter chains usage data
36
- * const filterChains = new ns1.index.BillingUsage("filter_chains", {metricType: "filter-chains"});
36
+ * const filterChains = ns1.getBillingUsage({
37
+ * metricType: "filter-chains",
38
+ * });
37
39
  * // Get monitoring jobs usage data
38
- * const monitors = new ns1.index.BillingUsage("monitors", {metricType: "monitors"});
40
+ * const monitors = ns1.getBillingUsage({
41
+ * metricType: "monitors",
42
+ * });
39
43
  * // Get records usage data
40
- * const records = new ns1.index.BillingUsage("records", {metricType: "records"});
41
- * export const totalQueries = queries.cleanQueries;
42
- * export const totalDdosQueries = queries.ddosQueries;
43
- * export const totalNxdResponses = queries.nxdResponses;
44
- * export const queriesLimit = limits.queriesLimit;
45
- * export const totalDecisions = decisions.totalUsage;
46
- * export const decisionsLimit = limits.decisionsLimit;
47
- * export const totalFilterChains = filterChains.totalUsage;
48
- * export const filterChainsLimit = limits.filterChainsLimit;
49
- * export const totalMonitors = monitors.totalUsage;
50
- * export const monitorsLimit = limits.monitorsLimit;
51
- * export const totalRecords = records.totalUsage;
52
- * export const recordsLimit = limits.recordsLimit;
44
+ * const records = ns1.getBillingUsage({
45
+ * metricType: "records",
46
+ * });
47
+ * export const totalQueries = queries.then(queries => queries.cleanQueries);
48
+ * export const totalDdosQueries = queries.then(queries => queries.ddosQueries);
49
+ * export const totalNxdResponses = queries.then(queries => queries.nxdResponses);
50
+ * export const queriesLimit = limits.then(limits => limits.queriesLimit);
51
+ * export const totalDecisions = decisions.then(decisions => decisions.totalUsage);
52
+ * export const decisionsLimit = limits.then(limits => limits.decisionsLimit);
53
+ * export const totalFilterChains = filterChains.then(filterChains => filterChains.totalUsage);
54
+ * export const filterChainsLimit = limits.then(limits => limits.filterChainsLimit);
55
+ * export const totalMonitors = monitors.then(monitors => monitors.totalUsage);
56
+ * export const monitorsLimit = limits.then(limits => limits.monitorsLimit);
57
+ * export const totalRecords = records.then(records => records.totalUsage);
58
+ * export const recordsLimit = limits.then(limits => limits.recordsLimit);
53
59
  * ```
54
60
  */
55
61
  function getBillingUsage(args, opts) {
@@ -71,41 +77,47 @@ exports.getBillingUsage = getBillingUsage;
71
77
  * import * as ns1 from "@pulumi/ns1";
72
78
  *
73
79
  * // Get query usage data for the given timeframe
74
- * const queries = new ns1.index.BillingUsage("queries", {
80
+ * const queries = ns1.getBillingUsage({
75
81
  * metricType: "queries",
76
- * from: 1731605824,
77
- * to: 1734197824,
82
+ * from: 1738368000,
83
+ * to: 1740787199,
78
84
  * });
79
85
  * // Get account limits data for the given timeframe
80
- * const limits = new ns1.index.BillingUsage("limits", {
86
+ * const limits = ns1.getBillingUsage({
81
87
  * metricType: "limits",
82
- * from: 1731605824,
83
- * to: 1734197824,
88
+ * from: 1738368000,
89
+ * to: 1740787199,
84
90
  * });
85
91
  * // Get RUM decisions usage data for the given timeframe
86
- * const decisions = new ns1.index.BillingUsage("decisions", {
92
+ * const decisions = ns1.getBillingUsage({
87
93
  * metricType: "decisions",
88
- * from: 1731605824,
89
- * to: 1734197824,
94
+ * from: 1738368000,
95
+ * to: 1740787199,
90
96
  * });
91
97
  * // Get filter chains usage data
92
- * const filterChains = new ns1.index.BillingUsage("filter_chains", {metricType: "filter-chains"});
98
+ * const filterChains = ns1.getBillingUsage({
99
+ * metricType: "filter-chains",
100
+ * });
93
101
  * // Get monitoring jobs usage data
94
- * const monitors = new ns1.index.BillingUsage("monitors", {metricType: "monitors"});
102
+ * const monitors = ns1.getBillingUsage({
103
+ * metricType: "monitors",
104
+ * });
95
105
  * // Get records usage data
96
- * const records = new ns1.index.BillingUsage("records", {metricType: "records"});
97
- * export const totalQueries = queries.cleanQueries;
98
- * export const totalDdosQueries = queries.ddosQueries;
99
- * export const totalNxdResponses = queries.nxdResponses;
100
- * export const queriesLimit = limits.queriesLimit;
101
- * export const totalDecisions = decisions.totalUsage;
102
- * export const decisionsLimit = limits.decisionsLimit;
103
- * export const totalFilterChains = filterChains.totalUsage;
104
- * export const filterChainsLimit = limits.filterChainsLimit;
105
- * export const totalMonitors = monitors.totalUsage;
106
- * export const monitorsLimit = limits.monitorsLimit;
107
- * export const totalRecords = records.totalUsage;
108
- * export const recordsLimit = limits.recordsLimit;
106
+ * const records = ns1.getBillingUsage({
107
+ * metricType: "records",
108
+ * });
109
+ * export const totalQueries = queries.then(queries => queries.cleanQueries);
110
+ * export const totalDdosQueries = queries.then(queries => queries.ddosQueries);
111
+ * export const totalNxdResponses = queries.then(queries => queries.nxdResponses);
112
+ * export const queriesLimit = limits.then(limits => limits.queriesLimit);
113
+ * export const totalDecisions = decisions.then(decisions => decisions.totalUsage);
114
+ * export const decisionsLimit = limits.then(limits => limits.decisionsLimit);
115
+ * export const totalFilterChains = filterChains.then(filterChains => filterChains.totalUsage);
116
+ * export const filterChainsLimit = limits.then(limits => limits.filterChainsLimit);
117
+ * export const totalMonitors = monitors.then(monitors => monitors.totalUsage);
118
+ * export const monitorsLimit = limits.then(limits => limits.monitorsLimit);
119
+ * export const totalRecords = records.then(records => records.totalUsage);
120
+ * export const recordsLimit = limits.then(limits => limits.recordsLimit);
109
121
  * ```
110
122
  */
111
123
  function getBillingUsageOutput(args, opts) {
@@ -1 +1 @@
1
- {"version":3,"file":"getBillingUsage.js","sourceRoot":"","sources":["../getBillingUsage.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AAGzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH,SAAgB,eAAe,CAAC,IAAyB,EAAE,IAA2B;IAClF,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,2CAA2C,EAAE;QACtE,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,IAAI,EAAE,IAAI,CAAC,EAAE;KAChB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAPD,0CAOC;AAwFD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH,SAAgB,qBAAqB,CAAC,IAA+B,EAAE,IAAiC;IACpG,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,YAAY,CAAC,2CAA2C,EAAE;QAC5E,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,IAAI,EAAE,IAAI,CAAC,EAAE;KAChB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAPD,sDAOC"}
1
+ {"version":3,"file":"getBillingUsage.js","sourceRoot":"","sources":["../getBillingUsage.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;;AAEjF,yCAAyC;AAGzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AACH,SAAgB,eAAe,CAAC,IAAyB,EAAE,IAA2B;IAClF,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,2CAA2C,EAAE;QACtE,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,IAAI,EAAE,IAAI,CAAC,EAAE;KAChB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAPD,0CAOC;AAwFD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AACH,SAAgB,qBAAqB,CAAC,IAA+B,EAAE,IAAiC;IACpG,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,YAAY,CAAC,2CAA2C,EAAE;QAC5E,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,IAAI,EAAE,IAAI,CAAC,EAAE;KAChB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAPD,sDAOC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pulumi/ns1",
3
- "version": "3.6.0",
3
+ "version": "3.6.1",
4
4
  "description": "A Pulumi package for creating and managing ns1 cloud resources.",
5
5
  "keywords": [
6
6
  "pulumi",
@@ -23,6 +23,6 @@
23
23
  "pulumi": {
24
24
  "resource": true,
25
25
  "name": "ns1",
26
- "version": "3.6.0"
26
+ "version": "3.6.1"
27
27
  }
28
28
  }