pulumi-logtail 0.6.3

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.
Files changed (45) hide show
  1. package/README.md +334 -0
  2. package/bin/config/index.d.ts +1 -0
  3. package/bin/config/index.js +21 -0
  4. package/bin/config/index.js.map +1 -0
  5. package/bin/config/vars.d.ts +6 -0
  6. package/bin/config/vars.js +13 -0
  7. package/bin/config/vars.js.map +1 -0
  8. package/bin/getMetric.d.ts +29 -0
  9. package/bin/getMetric.js +23 -0
  10. package/bin/getMetric.js.map +1 -0
  11. package/bin/getSource.d.ts +45 -0
  12. package/bin/getSource.js +21 -0
  13. package/bin/getSource.js.map +1 -0
  14. package/bin/getSourceGroup.d.ts +26 -0
  15. package/bin/getSourceGroup.js +21 -0
  16. package/bin/getSourceGroup.js.map +1 -0
  17. package/bin/index.d.ts +24 -0
  18. package/bin/index.js +57 -0
  19. package/bin/index.js.map +1 -0
  20. package/bin/metric.d.ts +108 -0
  21. package/bin/metric.js +71 -0
  22. package/bin/metric.js.map +1 -0
  23. package/bin/package.json +60 -0
  24. package/bin/provider.d.ts +39 -0
  25. package/bin/provider.js +50 -0
  26. package/bin/provider.js.map +1 -0
  27. package/bin/source.d.ts +311 -0
  28. package/bin/source.js +94 -0
  29. package/bin/source.js.map +1 -0
  30. package/bin/sourceGroup.d.ts +88 -0
  31. package/bin/sourceGroup.js +57 -0
  32. package/bin/sourceGroup.js.map +1 -0
  33. package/bin/types/index.d.ts +3 -0
  34. package/bin/types/index.js +11 -0
  35. package/bin/types/index.js.map +1 -0
  36. package/bin/types/input.d.ts +23 -0
  37. package/bin/types/input.js +5 -0
  38. package/bin/types/input.js.map +1 -0
  39. package/bin/types/output.d.ts +29 -0
  40. package/bin/types/output.js +5 -0
  41. package/bin/types/output.js.map +1 -0
  42. package/bin/utilities.d.ts +5 -0
  43. package/bin/utilities.js +141 -0
  44. package/bin/utilities.js.map +1 -0
  45. package/package.json +60 -0
package/README.md ADDED
@@ -0,0 +1,334 @@
1
+ # Pulumi Logtail Provider
2
+
3
+ A Pulumi provider for managing Logtail log management and analytics resources, dynamically bridged from the [Terraform Logtail Provider](https://github.com/betterstackhq/terraform-provider-logtail).
4
+
5
+ ## Introduction
6
+
7
+ This package provides a Pulumi provider that enables you to manage your Logtail logging infrastructure using TypeScript, JavaScript, Python, Go, or C#. The provider is automatically generated from the Terraform Logtail provider, giving you access to all its functionality within the Pulumi ecosystem.
8
+
9
+ ### Features
10
+
11
+ - **Log Sources**: Create and manage log sources for collecting logs from various platforms and services
12
+ - **Source Groups**: Organize log sources into logical groups for better management
13
+ - **Metrics**: Define and configure custom metrics based on log data
14
+ - **Log Aggregation**: Centralized log collection and processing
15
+ - **Log Analytics**: Query and analyze log data with powerful search capabilities
16
+ - **TypeScript Support**: Full type safety with comprehensive TypeScript definitions
17
+
18
+ ## Installation
19
+
20
+ ### npm
21
+
22
+ ```bash
23
+ npm install pulumi-logtail
24
+ ```
25
+
26
+ ### yarn
27
+
28
+ ```bash
29
+ yarn add pulumi-logtail
30
+ ```
31
+
32
+ ### pnpm
33
+
34
+ ```bash
35
+ pnpm add pulumi-logtail
36
+ ```
37
+
38
+ ## Configuration
39
+
40
+ Before using the Logtail provider, you need to configure your API token. You can obtain an API token from your [Logtail dashboard](https://logtail.com/api-tokens).
41
+
42
+ ### Environment Variables
43
+
44
+ ```bash
45
+ export LOGTAIL_API_TOKEN="your-api-token-here"
46
+ ```
47
+
48
+ ### Pulumi Configuration
49
+
50
+ ```bash
51
+ pulumi config set logtail:apiToken "your-api-token-here" --secret
52
+ ```
53
+
54
+ ## Usage
55
+
56
+ ### Log Source Management
57
+
58
+ ```typescript
59
+ import * as logtail from 'pulumi-logtail'
60
+
61
+ // Create a log source for application logs
62
+ const appSource = new logtail.Source('app-logs', {
63
+ name: 'Application Logs',
64
+ platform: 'javascript',
65
+ retentionDays: 30,
66
+ })
67
+
68
+ // Create a source for system logs
69
+ const systemSource = new logtail.Source('system-logs', {
70
+ name: 'System Logs',
71
+ platform: 'syslog',
72
+ retentionDays: 90,
73
+ })
74
+
75
+ // Create a source for Docker container logs
76
+ const dockerSource = new logtail.Source('docker-logs', {
77
+ name: 'Docker Container Logs',
78
+ platform: 'docker',
79
+ retentionDays: 14,
80
+ })
81
+ ```
82
+
83
+ ### Source Group Organization
84
+
85
+ ```typescript
86
+ import * as logtail from 'pulumi-logtail'
87
+
88
+ // Create a source group for production environment
89
+ const productionGroup = new logtail.SourceGroup('production', {
90
+ name: 'Production Environment',
91
+ description: 'All log sources from production infrastructure',
92
+ })
93
+
94
+ // Create a source group for development environment
95
+ const developmentGroup = new logtail.SourceGroup('development', {
96
+ name: 'Development Environment',
97
+ description: 'Log sources for development and testing',
98
+ })
99
+
100
+ // Create sources within groups
101
+ const prodAppSource = new logtail.Source('prod-app', {
102
+ name: 'Production Application',
103
+ platform: 'javascript',
104
+ retentionDays: 90,
105
+ sourceGroupId: productionGroup.id,
106
+ })
107
+
108
+ const devAppSource = new logtail.Source('dev-app', {
109
+ name: 'Development Application',
110
+ platform: 'javascript',
111
+ retentionDays: 7,
112
+ sourceGroupId: developmentGroup.id,
113
+ })
114
+ ```
115
+
116
+ ### Custom Metrics Creation
117
+
118
+ ```typescript
119
+ import * as logtail from 'pulumi-logtail'
120
+
121
+ // Create a metric to count error occurrences
122
+ const errorMetric = new logtail.Metric('error-count', {
123
+ name: 'Error Count',
124
+ description: 'Count of application errors',
125
+ sourceId: appSource.id,
126
+ query: 'level:error',
127
+ aggregation: 'count',
128
+ tags: ['environment:production', 'team:backend'],
129
+ })
130
+
131
+ // Create a metric for response time monitoring
132
+ const responseTimeMetric = new logtail.Metric('response-time', {
133
+ name: 'Average Response Time',
134
+ description: 'Average HTTP response time',
135
+ sourceId: appSource.id,
136
+ query: 'http.response_time > 0',
137
+ aggregation: 'avg',
138
+ field: 'http.response_time',
139
+ tags: ['environment:production', 'team:backend'],
140
+ })
141
+
142
+ // Create a metric for tracking specific events
143
+ const userSignupMetric = new logtail.Metric('user-signups', {
144
+ name: 'User Signups',
145
+ description: 'Count of user registration events',
146
+ sourceId: appSource.id,
147
+ query: 'event:user_signup',
148
+ aggregation: 'count',
149
+ tags: ['environment:production', 'team:growth'],
150
+ })
151
+ ```
152
+
153
+ ### Advanced Log Source Configurations
154
+
155
+ ```typescript
156
+ import * as logtail from 'pulumi-logtail'
157
+
158
+ // Create a source for AWS CloudWatch logs
159
+ const cloudwatchSource = new logtail.Source('cloudwatch-logs', {
160
+ name: 'AWS CloudWatch Logs',
161
+ platform: 'cloudwatch',
162
+ retentionDays: 60,
163
+ configuration: {
164
+ region: 'us-east-1',
165
+ logGroups: ['/aws/lambda/my-function', '/aws/apigateway/my-api'],
166
+ },
167
+ })
168
+
169
+ // Create a source for Kubernetes logs
170
+ const k8sSource = new logtail.Source('kubernetes-logs', {
171
+ name: 'Kubernetes Cluster Logs',
172
+ platform: 'kubernetes',
173
+ retentionDays: 30,
174
+ configuration: {
175
+ namespace: 'production',
176
+ labelSelectors: ['app=web', 'tier=frontend'],
177
+ },
178
+ })
179
+
180
+ // Create a source for database logs
181
+ const dbSource = new logtail.Source('database-logs', {
182
+ name: 'PostgreSQL Logs',
183
+ platform: 'postgresql',
184
+ retentionDays: 45,
185
+ configuration: {
186
+ logLevel: 'info',
187
+ includeStatements: true,
188
+ },
189
+ })
190
+ ```
191
+
192
+ ### Log Analytics and Querying
193
+
194
+ ```typescript
195
+ import * as logtail from 'pulumi-logtail'
196
+
197
+ // Create metrics for monitoring application health
198
+ const healthMetrics = [
199
+ new logtail.Metric('4xx-errors', {
200
+ name: '4XX HTTP Errors',
201
+ description: 'Count of 4XX HTTP status codes',
202
+ sourceId: appSource.id,
203
+ query: 'http.status_code >= 400 AND http.status_code < 500',
204
+ aggregation: 'count',
205
+ alertThreshold: 100,
206
+ }),
207
+
208
+ new logtail.Metric('5xx-errors', {
209
+ name: '5XX HTTP Errors',
210
+ description: 'Count of 5XX HTTP status codes',
211
+ sourceId: appSource.id,
212
+ query: 'http.status_code >= 500',
213
+ aggregation: 'count',
214
+ alertThreshold: 10,
215
+ }),
216
+
217
+ new logtail.Metric('slow-queries', {
218
+ name: 'Slow Database Queries',
219
+ description: 'Count of slow database queries',
220
+ sourceId: dbSource.id,
221
+ query: 'duration > 1000',
222
+ aggregation: 'count',
223
+ alertThreshold: 50,
224
+ }),
225
+ ]
226
+ ```
227
+
228
+ ## Resources
229
+
230
+ ### Core Resources
231
+
232
+ - **Source**: Log sources for collecting logs from various platforms and services
233
+ - **SourceGroup**: Logical groups for organizing related log sources
234
+ - **Metric**: Custom metrics based on log data for monitoring and alerting
235
+
236
+ ### Data Sources
237
+
238
+ - **getSource**: Retrieve information about existing log sources
239
+ - **getSourceGroup**: Retrieve information about existing source groups
240
+ - **getMetric**: Retrieve information about existing metrics
241
+
242
+ ## API Reference
243
+
244
+ For detailed API documentation, type definitions, and examples, please refer to the [API Reference documentation](https://www.pulumi.com/registry/packages/logtail/api-docs/).
245
+
246
+ ## Authentication Setup
247
+
248
+ ### Obtaining an API Token
249
+
250
+ 1. Log in to your [Logtail account](https://logtail.com)
251
+ 2. Navigate to **Settings** → **API Tokens**
252
+ 3. Click **Create API Token**
253
+ 4. Provide a name for your token and select appropriate permissions
254
+ 5. Copy the generated token (it will only be shown once)
255
+
256
+ ### Configuring the Provider
257
+
258
+ Set your API token using one of these methods:
259
+
260
+ #### Environment Variable (Recommended)
261
+ ```bash
262
+ export LOGTAIL_API_TOKEN="lt_abcd1234efgh5678ijkl9012mnop3456"
263
+ ```
264
+
265
+ #### Pulumi Configuration
266
+ ```bash
267
+ pulumi config set logtail:apiToken "lt_abcd1234efgh5678ijkl9012mnop3456" --secret
268
+ ```
269
+
270
+ #### Provider Configuration in Code
271
+ ```typescript
272
+ import * as logtail from 'pulumi-logtail'
273
+
274
+ const provider = new logtail.Provider('logtail', {
275
+ apiToken: 'lt_abcd1234efgh5678ijkl9012mnop3456',
276
+ })
277
+
278
+ // Use the provider with resources
279
+ const source = new logtail.Source('my-source', {
280
+ // ... configuration
281
+ }, { provider })
282
+ ```
283
+
284
+ ## Platform Support
285
+
286
+ Logtail supports log collection from various platforms and services:
287
+
288
+ ### Application Platforms
289
+ - **JavaScript/Node.js**: Browser and server-side JavaScript applications
290
+ - **Python**: Python applications and scripts
291
+ - **Ruby**: Ruby applications and Rails
292
+ - **Go**: Go applications and services
293
+ - **Java**: Java applications and Spring Boot
294
+ - **PHP**: PHP applications and Laravel
295
+ - **.NET**: .NET Core and Framework applications
296
+
297
+ ### Infrastructure Platforms
298
+ - **Docker**: Container logs from Docker environments
299
+ - **Kubernetes**: Pod and container logs from Kubernetes clusters
300
+ - **AWS CloudWatch**: Logs from AWS services and Lambda functions
301
+ - **Syslog**: System logs from servers and network devices
302
+ - **PostgreSQL**: Database logs and query logs
303
+ - **MySQL**: Database logs and slow query logs
304
+ - **Redis**: Redis server logs
305
+ - **Nginx**: Web server access and error logs
306
+ - **Apache**: Apache web server logs
307
+
308
+ ### Cloud Services
309
+ - **AWS**: CloudWatch Logs, ELB, CloudFront, and other AWS services
310
+ - **Google Cloud**: Cloud Logging and other GCP services
311
+ - **Azure**: Azure Monitor and other Azure services
312
+ - **Heroku**: Application and system logs from Heroku dynos
313
+
314
+ ## Examples
315
+
316
+ You can find more examples in common use cases:
317
+
318
+ - **Basic Log Collection**: Setting up log sources for web applications
319
+ - **Multi-Environment Setup**: Organizing logs across development, staging, and production
320
+ - **Metrics and Alerting**: Creating custom metrics for monitoring application health
321
+ - **Log Aggregation**: Centralized logging for microservices architecture
322
+ - **Platform Integration**: Connecting various platforms and services to Logtail
323
+
324
+ ## Support
325
+
326
+ This provider is a derived work of the [Terraform Provider](https://github.com/betterstackhq/terraform-provider-logtail) distributed under [MPL 2.0](https://www.mozilla.org/en-US/MPL/2.0/).
327
+
328
+ If you encounter a bug or missing feature, please consult the source [`terraform-provider-logtail` repo](https://github.com/betterstackhq/terraform-provider-logtail/issues).
329
+
330
+ For Pulumi-specific issues, please open an issue in the [pulumi-any-terraform repository](https://github.com/hckhanh/pulumi-any-terraform).
331
+
332
+ ## License
333
+
334
+ This package is distributed under the MIT License. The underlying Terraform provider is distributed under MPL 2.0.
@@ -0,0 +1 @@
1
+ export * from "./vars";
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ // *** WARNING: this file was generated by pulumi-language-nodejs. ***
3
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
5
+ if (k2 === undefined) k2 = k;
6
+ var desc = Object.getOwnPropertyDescriptor(m, k);
7
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
8
+ desc = { enumerable: true, get: function() { return m[k]; } };
9
+ }
10
+ Object.defineProperty(o, k2, desc);
11
+ }) : (function(o, m, k, k2) {
12
+ if (k2 === undefined) k2 = k;
13
+ o[k2] = m[k];
14
+ }));
15
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
16
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
17
+ };
18
+ Object.defineProperty(exports, "__esModule", { value: true });
19
+ // Export members:
20
+ __exportStar(require("./vars"), exports);
21
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../config/index.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;;;;;;;;;;;;;;AAEjF,kBAAkB;AAClB,yCAAuB"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Better Stack Telemetry API token. The value can be omitted if `LOGTAIL_API_TOKEN` environment variable is set. See
3
+ * https://betterstack.com/docs/logs/api/getting-started/#get-an-logs-api-token on how to obtain the API token for your
4
+ * team.
5
+ */
6
+ export declare const apiToken: string | undefined;
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ // *** WARNING: this file was generated by pulumi-language-nodejs. ***
3
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ const pulumi = require("@pulumi/pulumi");
6
+ const __config = new pulumi.Config("logtail");
7
+ Object.defineProperty(exports, "apiToken", {
8
+ get() {
9
+ return __config.get("apiToken");
10
+ },
11
+ enumerable: true,
12
+ });
13
+ //# sourceMappingURL=vars.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vars.js","sourceRoot":"","sources":["../../config/vars.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;AAEjF,yCAAyC;AAIzC,MAAM,QAAQ,GAAG,IAAI,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;AAQ9C,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,UAAU,EAAE;IACvC,GAAG;QACC,OAAO,QAAQ,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;IACpC,CAAC;IACD,UAAU,EAAE,IAAI;CACnB,CAAC,CAAC"}
@@ -0,0 +1,29 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ export declare function getMetric(args: GetMetricArgs, opts?: pulumi.InvokeOptions): Promise<GetMetricResult>;
3
+ /**
4
+ * A collection of arguments for invoking getMetric.
5
+ */
6
+ export interface GetMetricArgs {
7
+ name: string;
8
+ sourceId: string;
9
+ }
10
+ /**
11
+ * A collection of values returned by getMetric.
12
+ */
13
+ export interface GetMetricResult {
14
+ readonly aggregations: string[];
15
+ readonly id: string;
16
+ readonly name: string;
17
+ readonly sourceId: string;
18
+ readonly sqlExpression: string;
19
+ readonly teamName: string;
20
+ readonly type: string;
21
+ }
22
+ export declare function getMetricOutput(args: GetMetricOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetMetricResult>;
23
+ /**
24
+ * A collection of arguments for invoking getMetric.
25
+ */
26
+ export interface GetMetricOutputArgs {
27
+ name: pulumi.Input<string>;
28
+ sourceId: pulumi.Input<string>;
29
+ }
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ // *** WARNING: this file was generated by pulumi-language-nodejs. ***
3
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.getMetric = getMetric;
6
+ exports.getMetricOutput = getMetricOutput;
7
+ const pulumi = require("@pulumi/pulumi");
8
+ const utilities = require("./utilities");
9
+ function getMetric(args, opts) {
10
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
11
+ return pulumi.runtime.invoke("logtail:index/getMetric:getMetric", {
12
+ "name": args.name,
13
+ "sourceId": args.sourceId,
14
+ }, opts, utilities.getPackage());
15
+ }
16
+ function getMetricOutput(args, opts) {
17
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
18
+ return pulumi.runtime.invokeOutput("logtail:index/getMetric:getMetric", {
19
+ "name": args.name,
20
+ "sourceId": args.sourceId,
21
+ }, opts, utilities.getPackage());
22
+ }
23
+ //# sourceMappingURL=getMetric.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getMetric.js","sourceRoot":"","sources":["../getMetric.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;AAKjF,8BAMC;AAsBD,0CAMC;AArCD,yCAAyC;AACzC,yCAAyC;AAEzC,SAAgB,SAAS,CAAC,IAAmB,EAAE,IAA2B;IACtE,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,mCAAmC,EAAE;QAC9D,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,UAAU,EAAE,IAAI,CAAC,QAAQ;KAC5B,EAAE,IAAI,EAAE,SAAS,CAAC,UAAU,EAAE,CAAC,CAAC;AACrC,CAAC;AAsBD,SAAgB,eAAe,CAAC,IAAyB,EAAE,IAAiC;IACxF,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,YAAY,CAAC,mCAAmC,EAAE;QACpE,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,UAAU,EAAE,IAAI,CAAC,QAAQ;KAC5B,EAAE,IAAI,EAAE,SAAS,CAAC,UAAU,EAAE,CAAC,CAAC;AACrC,CAAC"}
@@ -0,0 +1,45 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ import * as outputs from "./types/output";
3
+ export declare function getSource(args: GetSourceArgs, opts?: pulumi.InvokeOptions): Promise<GetSourceResult>;
4
+ /**
5
+ * A collection of arguments for invoking getSource.
6
+ */
7
+ export interface GetSourceArgs {
8
+ tableName: string;
9
+ }
10
+ /**
11
+ * A collection of values returned by getSource.
12
+ */
13
+ export interface GetSourceResult {
14
+ readonly createdAt: string;
15
+ readonly customBuckets: outputs.GetSourceCustomBucket[];
16
+ readonly dataRegion: string;
17
+ readonly id: string;
18
+ readonly ingestingHost: string;
19
+ readonly ingestingPaused: boolean;
20
+ readonly liveTailPattern: string;
21
+ readonly logsRetention: number;
22
+ readonly metricsRetention: number;
23
+ readonly name: string;
24
+ readonly platform: string;
25
+ readonly scrapeFrequencySecs: number;
26
+ readonly scrapeRequestBasicAuthPassword: string;
27
+ readonly scrapeRequestBasicAuthUser: string;
28
+ readonly scrapeRequestHeaders: {
29
+ [key: string]: string;
30
+ }[];
31
+ readonly scrapeUrls: string[];
32
+ readonly sourceGroupId: number;
33
+ readonly tableName: string;
34
+ readonly teamName: string;
35
+ readonly token: string;
36
+ readonly updatedAt: string;
37
+ readonly vrlTransformation: string;
38
+ }
39
+ export declare function getSourceOutput(args: GetSourceOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetSourceResult>;
40
+ /**
41
+ * A collection of arguments for invoking getSource.
42
+ */
43
+ export interface GetSourceOutputArgs {
44
+ tableName: pulumi.Input<string>;
45
+ }
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ // *** WARNING: this file was generated by pulumi-language-nodejs. ***
3
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.getSource = getSource;
6
+ exports.getSourceOutput = getSourceOutput;
7
+ const pulumi = require("@pulumi/pulumi");
8
+ const utilities = require("./utilities");
9
+ function getSource(args, opts) {
10
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
11
+ return pulumi.runtime.invoke("logtail:index/getSource:getSource", {
12
+ "tableName": args.tableName,
13
+ }, opts, utilities.getPackage());
14
+ }
15
+ function getSourceOutput(args, opts) {
16
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
17
+ return pulumi.runtime.invokeOutput("logtail:index/getSource:getSource", {
18
+ "tableName": args.tableName,
19
+ }, opts, utilities.getPackage());
20
+ }
21
+ //# sourceMappingURL=getSource.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getSource.js","sourceRoot":"","sources":["../getSource.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;AAOjF,8BAKC;AAoCD,0CAKC;AAnDD,yCAAyC;AAGzC,yCAAyC;AAEzC,SAAgB,SAAS,CAAC,IAAmB,EAAE,IAA2B;IACtE,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,mCAAmC,EAAE;QAC9D,WAAW,EAAE,IAAI,CAAC,SAAS;KAC9B,EAAE,IAAI,EAAE,SAAS,CAAC,UAAU,EAAE,CAAC,CAAC;AACrC,CAAC;AAoCD,SAAgB,eAAe,CAAC,IAAyB,EAAE,IAAiC;IACxF,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,YAAY,CAAC,mCAAmC,EAAE;QACpE,WAAW,EAAE,IAAI,CAAC,SAAS;KAC9B,EAAE,IAAI,EAAE,SAAS,CAAC,UAAU,EAAE,CAAC,CAAC;AACrC,CAAC"}
@@ -0,0 +1,26 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ export declare function getSourceGroup(args: GetSourceGroupArgs, opts?: pulumi.InvokeOptions): Promise<GetSourceGroupResult>;
3
+ /**
4
+ * A collection of arguments for invoking getSourceGroup.
5
+ */
6
+ export interface GetSourceGroupArgs {
7
+ name: string;
8
+ }
9
+ /**
10
+ * A collection of values returned by getSourceGroup.
11
+ */
12
+ export interface GetSourceGroupResult {
13
+ readonly createdAt: string;
14
+ readonly id: string;
15
+ readonly name: string;
16
+ readonly sortIndex: number;
17
+ readonly teamName: string;
18
+ readonly updatedAt: string;
19
+ }
20
+ export declare function getSourceGroupOutput(args: GetSourceGroupOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetSourceGroupResult>;
21
+ /**
22
+ * A collection of arguments for invoking getSourceGroup.
23
+ */
24
+ export interface GetSourceGroupOutputArgs {
25
+ name: pulumi.Input<string>;
26
+ }
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ // *** WARNING: this file was generated by pulumi-language-nodejs. ***
3
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.getSourceGroup = getSourceGroup;
6
+ exports.getSourceGroupOutput = getSourceGroupOutput;
7
+ const pulumi = require("@pulumi/pulumi");
8
+ const utilities = require("./utilities");
9
+ function getSourceGroup(args, opts) {
10
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
11
+ return pulumi.runtime.invoke("logtail:index/getSourceGroup:getSourceGroup", {
12
+ "name": args.name,
13
+ }, opts, utilities.getPackage());
14
+ }
15
+ function getSourceGroupOutput(args, opts) {
16
+ opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
17
+ return pulumi.runtime.invokeOutput("logtail:index/getSourceGroup:getSourceGroup", {
18
+ "name": args.name,
19
+ }, opts, utilities.getPackage());
20
+ }
21
+ //# sourceMappingURL=getSourceGroup.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getSourceGroup.js","sourceRoot":"","sources":["../getSourceGroup.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;AAKjF,wCAKC;AAoBD,oDAKC;AAjCD,yCAAyC;AACzC,yCAAyC;AAEzC,SAAgB,cAAc,CAAC,IAAwB,EAAE,IAA2B;IAChF,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,6CAA6C,EAAE;QACxE,MAAM,EAAE,IAAI,CAAC,IAAI;KACpB,EAAE,IAAI,EAAE,SAAS,CAAC,UAAU,EAAE,CAAC,CAAC;AACrC,CAAC;AAoBD,SAAgB,oBAAoB,CAAC,IAA8B,EAAE,IAAiC;IAClG,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC,CAAC;IACzE,OAAO,MAAM,CAAC,OAAO,CAAC,YAAY,CAAC,6CAA6C,EAAE;QAC9E,MAAM,EAAE,IAAI,CAAC,IAAI;KACpB,EAAE,IAAI,EAAE,SAAS,CAAC,UAAU,EAAE,CAAC,CAAC;AACrC,CAAC"}
package/bin/index.d.ts ADDED
@@ -0,0 +1,24 @@
1
+ export { GetMetricArgs, GetMetricResult, GetMetricOutputArgs } from "./getMetric";
2
+ export declare const getMetric: typeof import("./getMetric").getMetric;
3
+ export declare const getMetricOutput: typeof import("./getMetric").getMetricOutput;
4
+ export { GetSourceArgs, GetSourceResult, GetSourceOutputArgs } from "./getSource";
5
+ export declare const getSource: typeof import("./getSource").getSource;
6
+ export declare const getSourceOutput: typeof import("./getSource").getSourceOutput;
7
+ export { GetSourceGroupArgs, GetSourceGroupResult, GetSourceGroupOutputArgs } from "./getSourceGroup";
8
+ export declare const getSourceGroup: typeof import("./getSourceGroup").getSourceGroup;
9
+ export declare const getSourceGroupOutput: typeof import("./getSourceGroup").getSourceGroupOutput;
10
+ export { MetricArgs, MetricState } from "./metric";
11
+ export type Metric = import("./metric").Metric;
12
+ export declare const Metric: typeof import("./metric").Metric;
13
+ export { ProviderArgs } from "./provider";
14
+ export type Provider = import("./provider").Provider;
15
+ export declare const Provider: typeof import("./provider").Provider;
16
+ export { SourceArgs, SourceState } from "./source";
17
+ export type Source = import("./source").Source;
18
+ export declare const Source: typeof import("./source").Source;
19
+ export { SourceGroupArgs, SourceGroupState } from "./sourceGroup";
20
+ export type SourceGroup = import("./sourceGroup").SourceGroup;
21
+ export declare const SourceGroup: typeof import("./sourceGroup").SourceGroup;
22
+ import * as config from "./config";
23
+ import * as types from "./types";
24
+ export { config, types, };
package/bin/index.js ADDED
@@ -0,0 +1,57 @@
1
+ "use strict";
2
+ // *** WARNING: this file was generated by pulumi-language-nodejs. ***
3
+ // *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.types = exports.config = exports.SourceGroup = exports.Source = exports.Provider = exports.Metric = exports.getSourceGroupOutput = exports.getSourceGroup = exports.getSourceOutput = exports.getSource = exports.getMetricOutput = exports.getMetric = void 0;
6
+ const pulumi = require("@pulumi/pulumi");
7
+ const utilities = require("./utilities");
8
+ exports.getMetric = null;
9
+ exports.getMetricOutput = null;
10
+ utilities.lazyLoad(exports, ["getMetric", "getMetricOutput"], () => require("./getMetric"));
11
+ exports.getSource = null;
12
+ exports.getSourceOutput = null;
13
+ utilities.lazyLoad(exports, ["getSource", "getSourceOutput"], () => require("./getSource"));
14
+ exports.getSourceGroup = null;
15
+ exports.getSourceGroupOutput = null;
16
+ utilities.lazyLoad(exports, ["getSourceGroup", "getSourceGroupOutput"], () => require("./getSourceGroup"));
17
+ exports.Metric = null;
18
+ utilities.lazyLoad(exports, ["Metric"], () => require("./metric"));
19
+ exports.Provider = null;
20
+ utilities.lazyLoad(exports, ["Provider"], () => require("./provider"));
21
+ exports.Source = null;
22
+ utilities.lazyLoad(exports, ["Source"], () => require("./source"));
23
+ exports.SourceGroup = null;
24
+ utilities.lazyLoad(exports, ["SourceGroup"], () => require("./sourceGroup"));
25
+ // Export sub-modules:
26
+ const config = require("./config");
27
+ exports.config = config;
28
+ const types = require("./types");
29
+ exports.types = types;
30
+ const _module = {
31
+ version: utilities.getVersion(),
32
+ construct: (name, type, urn) => {
33
+ switch (type) {
34
+ case "logtail:index/metric:Metric":
35
+ return new exports.Metric(name, undefined, { urn });
36
+ case "logtail:index/source:Source":
37
+ return new exports.Source(name, undefined, { urn });
38
+ case "logtail:index/sourceGroup:SourceGroup":
39
+ return new exports.SourceGroup(name, undefined, { urn });
40
+ default:
41
+ throw new Error(`unknown resource type ${type}`);
42
+ }
43
+ },
44
+ };
45
+ pulumi.runtime.registerResourceModule("logtail", "index/metric", _module);
46
+ pulumi.runtime.registerResourceModule("logtail", "index/source", _module);
47
+ pulumi.runtime.registerResourceModule("logtail", "index/sourceGroup", _module);
48
+ pulumi.runtime.registerResourcePackage("logtail", {
49
+ version: utilities.getVersion(),
50
+ constructProvider: (name, type, urn) => {
51
+ if (type !== "pulumi:providers:logtail") {
52
+ throw new Error(`unknown provider type ${type}`);
53
+ }
54
+ return new exports.Provider(name, undefined, { urn });
55
+ },
56
+ });
57
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AACzC,yCAAyC;AAI5B,QAAA,SAAS,GAA2C,IAAW,CAAC;AAChE,QAAA,eAAe,GAAiD,IAAW,CAAC;AACzF,SAAS,CAAC,Q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