@keystrokehq/snowflake 0.0.17 → 0.0.19
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/package.json +4 -4
- package/dist/actions/index.cjs +0 -18
- package/dist/actions/index.d.cts +0 -2
- package/dist/actions/index.d.mts +0 -2
- package/dist/actions/index.mjs +0 -2
- package/dist/actions-BGkaZb6a.cjs +0 -801
- package/dist/actions-BGkaZb6a.cjs.map +0 -1
- package/dist/actions-BR_JWhT_.mjs +0 -700
- package/dist/actions-BR_JWhT_.mjs.map +0 -1
- package/dist/index-DUGCZPGQ.d.cts +0 -443
- package/dist/index-DUGCZPGQ.d.cts.map +0 -1
- package/dist/index-RhOmpRxD.d.mts +0 -445
- package/dist/index-RhOmpRxD.d.mts.map +0 -1
- package/dist/index.cjs +0 -34
- package/dist/index.cjs.map +0 -1
- package/dist/index.d.cts +0 -19
- package/dist/index.d.cts.map +0 -1
- package/dist/index.d.mts +0 -19
- package/dist/index.d.mts.map +0 -1
- package/dist/index.mjs +0 -16
- package/dist/index.mjs.map +0 -1
|
@@ -1,801 +0,0 @@
|
|
|
1
|
-
let _keystrokehq_keystroke_app = require("@keystrokehq/keystroke/app");
|
|
2
|
-
let zod = require("zod");
|
|
3
|
-
let _keystrokehq_keystroke_client = require("@keystrokehq/keystroke/client");
|
|
4
|
-
//#region src/app.ts
|
|
5
|
-
const snowflake = (0, _keystrokehq_keystroke_app.defineApp)({
|
|
6
|
-
slug: "snowflake",
|
|
7
|
-
auth: "keystroke"
|
|
8
|
-
});
|
|
9
|
-
//#endregion
|
|
10
|
-
//#region src/execute.ts
|
|
11
|
-
const APP_SLUG = "snowflake";
|
|
12
|
-
/** Pinned app version — updated on regeneration. */
|
|
13
|
-
const APP_VERSION = "20260615_00";
|
|
14
|
-
async function executeSnowflakeTool(tool, args) {
|
|
15
|
-
const { result } = await (0, _keystrokehq_keystroke_client.createKeystrokeClient)().tools.execute({
|
|
16
|
-
app: APP_SLUG,
|
|
17
|
-
tool,
|
|
18
|
-
arguments: args,
|
|
19
|
-
version: APP_VERSION
|
|
20
|
-
});
|
|
21
|
-
return result;
|
|
22
|
-
}
|
|
23
|
-
//#endregion
|
|
24
|
-
//#region src/actions/cancel-statement-execution.ts
|
|
25
|
-
const SnowflakeCancelStatementExecutionInput = zod.z.object({
|
|
26
|
-
request_id: zod.z.string().describe("Unique ID (a UUID) of the API request. This is an optional parameter that can be used to track the request.").optional(),
|
|
27
|
-
statementHandle: zod.z.string().describe("The handle of the statement to be cancelled. This can be obtained from the response of the execute_statement action.")
|
|
28
|
-
});
|
|
29
|
-
const SnowflakeCancelStatementExecutionOutput = zod.z.object({
|
|
30
|
-
code: zod.z.string().describe("The response code from the Snowflake API."),
|
|
31
|
-
message: zod.z.string().describe("A message indicating the result of the cancellation request."),
|
|
32
|
-
sqlState: zod.z.string().describe("The SQL state of the statement after the cancellation request."),
|
|
33
|
-
statementHandle: zod.z.string().describe("The handle of the statement that was cancelled."),
|
|
34
|
-
statementStatusUrl: zod.z.string().describe("The URL to check the status of the statement.")
|
|
35
|
-
});
|
|
36
|
-
const snowflakeCancelStatementExecution = snowflake.action({
|
|
37
|
-
slug: "snowflake-cancel-statement-execution",
|
|
38
|
-
name: "Cancel Statement Execution",
|
|
39
|
-
description: "Cancels the execution of a running SQL statement. Use this action to stop a long-running query.",
|
|
40
|
-
input: SnowflakeCancelStatementExecutionInput,
|
|
41
|
-
output: SnowflakeCancelStatementExecutionOutput,
|
|
42
|
-
async run(input) {
|
|
43
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_CANCEL_STATEMENT_EXECUTION", input);
|
|
44
|
-
return SnowflakeCancelStatementExecutionOutput.parse(result);
|
|
45
|
-
}
|
|
46
|
-
});
|
|
47
|
-
//#endregion
|
|
48
|
-
//#region src/actions/check-statement-status.ts
|
|
49
|
-
const SnowflakeCheckStatementStatusInput = zod.z.object({
|
|
50
|
-
partition: zod.z.number().int().describe("The partition number to return. The size of each partition is determined by Snowflake.").optional(),
|
|
51
|
-
requestId: zod.z.string().describe("Unique ID (UUID) of the API request for idempotency.").optional(),
|
|
52
|
-
statementHandle: zod.z.string().describe("The handle of the statement to be checked.")
|
|
53
|
-
});
|
|
54
|
-
const SnowflakeCheckStatementStatusRowTypeInfoSchema = zod.z.object({
|
|
55
|
-
name: zod.z.string().describe("Name of the column."),
|
|
56
|
-
type: zod.z.string().describe("Data type of the column (e.g., 'text', 'fixed', 'timestamp_ltz')."),
|
|
57
|
-
scale: zod.z.number().int().describe("Scale for numeric types.").optional(),
|
|
58
|
-
table: zod.z.string().describe("Table name."),
|
|
59
|
-
length: zod.z.number().int().describe("Length for text types.").optional(),
|
|
60
|
-
schema: zod.z.string().describe("Schema name."),
|
|
61
|
-
database: zod.z.string().describe("Database name."),
|
|
62
|
-
nullable: zod.z.boolean().describe("Whether the column is nullable."),
|
|
63
|
-
collation: zod.z.string().describe("Collation for text types.").optional(),
|
|
64
|
-
precision: zod.z.number().int().describe("Precision for numeric types.").optional(),
|
|
65
|
-
byteLength: zod.z.number().int().describe("Byte length for text types.").optional()
|
|
66
|
-
});
|
|
67
|
-
const SnowflakeCheckStatementStatusPartitionInfoSchema = zod.z.object({
|
|
68
|
-
rowCount: zod.z.number().int().describe("Number of rows in this partition."),
|
|
69
|
-
uncompressedSize: zod.z.number().int().describe("Uncompressed size of the partition in bytes.")
|
|
70
|
-
});
|
|
71
|
-
const SnowflakeCheckStatementStatusResultSetMetadataSchema = zod.z.object({
|
|
72
|
-
format: zod.z.string().describe("Format of the result set (e.g., 'jsonv2')."),
|
|
73
|
-
numRows: zod.z.number().int().describe("Total number of rows in the result set."),
|
|
74
|
-
rowType: zod.z.array(SnowflakeCheckStatementStatusRowTypeInfoSchema).describe("Metadata describing each column in the result set."),
|
|
75
|
-
partitionInfo: zod.z.array(SnowflakeCheckStatementStatusPartitionInfoSchema).describe("Information about result set partitions.")
|
|
76
|
-
});
|
|
77
|
-
const SnowflakeCheckStatementStatusOutput = zod.z.object({
|
|
78
|
-
code: zod.z.string().describe("Response code (e.g., '090001' for success).").optional(),
|
|
79
|
-
data: zod.z.array(zod.z.array(zod.z.union([
|
|
80
|
-
zod.z.string(),
|
|
81
|
-
zod.z.number().int(),
|
|
82
|
-
zod.z.number(),
|
|
83
|
-
zod.z.boolean()
|
|
84
|
-
]).nullable())).describe("The result set data as a 2D array, where each inner array represents a row.").optional(),
|
|
85
|
-
message: zod.z.string().describe("Human-readable message describing the statement execution status.").optional(),
|
|
86
|
-
sqlState: zod.z.string().describe("SQL state code (e.g., '00000' for success).").optional(),
|
|
87
|
-
createdOn: zod.z.number().int().describe("Unix timestamp (in milliseconds) when the statement execution started.").optional(),
|
|
88
|
-
requestId: zod.z.string().describe("Unique ID (UUID) of the API request.").optional(),
|
|
89
|
-
statementHandle: zod.z.string().describe("Unique identifier (UUID) for the statement being executed.").optional(),
|
|
90
|
-
resultSetMetaData: SnowflakeCheckStatementStatusResultSetMetadataSchema.nullable().optional(),
|
|
91
|
-
statementStatusUrl: zod.z.string().describe("URL path to retrieve the statement status and result set.").optional()
|
|
92
|
-
});
|
|
93
|
-
const snowflakeCheckStatementStatus = snowflake.action({
|
|
94
|
-
slug: "snowflake-check-statement-status",
|
|
95
|
-
name: "Check Statement Status",
|
|
96
|
-
description: "Retrieves the status and results of a previously submitted SQL statement using its statement handle. Use this to poll async queries submitted via SNOWFLAKE_SUBMIT_SQL_STATEMENT; call repeatedly until status is no longer pending. Use SNOWFLAKE_CANCEL_STATEMENT to abort a hanging query.",
|
|
97
|
-
input: SnowflakeCheckStatementStatusInput,
|
|
98
|
-
output: SnowflakeCheckStatementStatusOutput,
|
|
99
|
-
async run(input) {
|
|
100
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_CHECK_STATEMENT_STATUS", input);
|
|
101
|
-
return SnowflakeCheckStatementStatusOutput.parse(result);
|
|
102
|
-
}
|
|
103
|
-
});
|
|
104
|
-
//#endregion
|
|
105
|
-
//#region src/actions/drop-warehouse.ts
|
|
106
|
-
const SnowflakeDropWarehouseInput = zod.z.object({
|
|
107
|
-
name: zod.z.string().describe("Identifier (i.e. name) for the warehouse to drop. The value is case-sensitive and must match the exact warehouse name in Snowflake."),
|
|
108
|
-
if_exists: zod.z.boolean().default(false).describe("If true, the endpoint does not throw an error if the warehouse does not exist. It returns a 200 success response without taking action. If false, the endpoint throws an error if the warehouse doesn't exist.").optional()
|
|
109
|
-
});
|
|
110
|
-
const SnowflakeDropWarehouseOutput = zod.z.object({
|
|
111
|
-
code: zod.z.string().describe("Message code for asynchronous deletion (202 response).").optional(),
|
|
112
|
-
status: zod.z.string().describe("Status message for successful synchronous deletion (200 response).").optional(),
|
|
113
|
-
message: zod.z.string().describe("Message for asynchronous deletion indicating execution in progress (202 response).").optional(),
|
|
114
|
-
resultHandler: zod.z.string().describe("Opaque result ID used for checking request completion status (202 response).").optional()
|
|
115
|
-
});
|
|
116
|
-
const snowflakeDropWarehouse = snowflake.action({
|
|
117
|
-
slug: "snowflake-drop-warehouse",
|
|
118
|
-
name: "Drop Warehouse",
|
|
119
|
-
description: "Drops (permanently deletes) a warehouse in Snowflake. This operation is irreversible — once a warehouse is dropped, it cannot be recovered. Use this action when you need to permanently remove a warehouse that is no longer needed. Requires OWNERSHIP privilege on the warehouse.",
|
|
120
|
-
input: SnowflakeDropWarehouseInput,
|
|
121
|
-
output: SnowflakeDropWarehouseOutput,
|
|
122
|
-
async run(input) {
|
|
123
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_DROP_WAREHOUSE", input);
|
|
124
|
-
return SnowflakeDropWarehouseOutput.parse(result);
|
|
125
|
-
}
|
|
126
|
-
});
|
|
127
|
-
//#endregion
|
|
128
|
-
//#region src/actions/execute-sql.ts
|
|
129
|
-
const SnowflakeExecuteSqlInput = zod.z.object({
|
|
130
|
-
role: zod.z.string().describe("Role name to use for execution (case-sensitive). If not specified, uses the user's DEFAULT_ROLE setting.").optional(),
|
|
131
|
-
timeout: zod.z.number().int().describe("Execution timeout in seconds. Set to 0 for maximum timeout (604800 seconds). If not specified, uses the default timeout.").optional(),
|
|
132
|
-
bindings: zod.z.record(zod.z.string(), zod.z.unknown()).describe("Values of bind variables in the SQL statement. Use this for parameterized queries to prevent SQL injection.").optional(),
|
|
133
|
-
database: zod.z.string().describe("Database name to use for execution (case-sensitive). If not specified, uses the user's DEFAULT_NAMESPACE setting.").optional(),
|
|
134
|
-
statement: zod.z.string().describe("SQL statement(s) to execute. Supports SELECT queries, DDL (CREATE, ALTER, DROP), and DML (INSERT, UPDATE, DELETE). Multiple statements can be separated by semicolons; they will be executed in sequence automatically. When querying INFORMATION_SCHEMA, always filter on both `table_schema` and `table_catalog` and wrap mixed AND/OR conditions in parentheses. For multi-statement batches, test critical sections in isolation first — a single failing statement obscures root cause."),
|
|
135
|
-
warehouse: zod.z.string().describe("Warehouse name to use for query execution (case-sensitive). Required for queries that need compute resources. If not specified, uses the user's DEFAULT_WAREHOUSE setting. Suspended or undersized warehouses cause high latency or timeouts; verify the warehouse is active and appropriately sized before execution.").optional(),
|
|
136
|
-
parameters: zod.z.record(zod.z.string(), zod.z.unknown()).describe("Session parameters to set for the statement execution. These are Snowflake session-level parameters.").optional(),
|
|
137
|
-
schema_name: zod.z.string().describe("Schema name to use for execution (case-sensitive). If not specified, uses the user's DEFAULT_NAMESPACE setting.").optional()
|
|
138
|
-
});
|
|
139
|
-
const SnowflakeExecuteSqlRowTypeMetadataSchema = zod.z.object({
|
|
140
|
-
name: zod.z.string().describe("Column name"),
|
|
141
|
-
type: zod.z.string().describe("Data type of the column"),
|
|
142
|
-
scale: zod.z.number().int().describe("Scale for numeric types").optional(),
|
|
143
|
-
table: zod.z.string().describe("Table name"),
|
|
144
|
-
length: zod.z.number().int().describe("Length for text types").optional(),
|
|
145
|
-
schema: zod.z.string().describe("Schema name"),
|
|
146
|
-
database: zod.z.string().describe("Database name"),
|
|
147
|
-
nullable: zod.z.boolean().describe("Whether the column is nullable"),
|
|
148
|
-
collation: zod.z.string().describe("Collation for text types").optional(),
|
|
149
|
-
precision: zod.z.number().int().describe("Precision for numeric types").optional(),
|
|
150
|
-
byteLength: zod.z.number().int().describe("Byte length for text types").optional()
|
|
151
|
-
});
|
|
152
|
-
const SnowflakeExecuteSqlPartitionInfoSchema = zod.z.object({
|
|
153
|
-
rowCount: zod.z.number().int().describe("Number of rows in this partition"),
|
|
154
|
-
uncompressedSize: zod.z.number().int().describe("Uncompressed size in bytes")
|
|
155
|
-
});
|
|
156
|
-
const SnowflakeExecuteSqlResultSetMetaDataSchema = zod.z.object({
|
|
157
|
-
format: zod.z.string().describe("Format of the result data (e.g., 'jsonv2')"),
|
|
158
|
-
numRows: zod.z.number().int().describe("Total number of rows in the result set"),
|
|
159
|
-
rowType: zod.z.array(SnowflakeExecuteSqlRowTypeMetadataSchema).describe("Metadata for each column in the result set"),
|
|
160
|
-
partitionInfo: zod.z.array(SnowflakeExecuteSqlPartitionInfoSchema).describe("Information about data partitions")
|
|
161
|
-
});
|
|
162
|
-
const SnowflakeExecuteSqlOutput = zod.z.object({
|
|
163
|
-
code: zod.z.string().describe("Status code from Snowflake (e.g., '090001' for success)").optional(),
|
|
164
|
-
data: zod.z.array(zod.z.array(zod.z.union([
|
|
165
|
-
zod.z.string(),
|
|
166
|
-
zod.z.number().int(),
|
|
167
|
-
zod.z.number(),
|
|
168
|
-
zod.z.boolean()
|
|
169
|
-
]).nullable())).describe("The result set rows (single statement only). For multi-statement execution, use statementHandles to retrieve results individually.").optional(),
|
|
170
|
-
message: zod.z.string().describe("Execution status message").optional(),
|
|
171
|
-
sqlState: zod.z.string().describe("SQL state code (e.g., '00000' for success)").optional(),
|
|
172
|
-
createdOn: zod.z.number().int().describe("Timestamp in milliseconds since epoch when the statement was created").optional(),
|
|
173
|
-
statementHandle: zod.z.string().describe("Unique identifier for the executed statement (single statement only)").optional(),
|
|
174
|
-
statementHandles: zod.z.array(zod.z.string()).describe("Array of statement handles for multi-statement execution. Use these handles with CHECK_STATEMENT_STATUS to retrieve results for each statement.").optional(),
|
|
175
|
-
resultSetMetaData: SnowflakeExecuteSqlResultSetMetaDataSchema.nullable().optional(),
|
|
176
|
-
statementStatusUrl: zod.z.string().describe("URL to check the execution status").optional(),
|
|
177
|
-
composio_execution_message: zod.z.string().describe("Additional execution information from Composio").optional()
|
|
178
|
-
});
|
|
179
|
-
const snowflakeExecuteSql = snowflake.action({
|
|
180
|
-
slug: "snowflake-execute-sql",
|
|
181
|
-
name: "Execute SQL",
|
|
182
|
-
description: "Execute SQL statements in Snowflake and retrieve results. Supports SELECT queries for data retrieval, DDL statements (CREATE, ALTER, DROP) for schema management, and DML statements (INSERT, UPDATE, DELETE) for data modification. Returns comprehensive result metadata including column types, row counts, and execution status. Unquoted SQL identifiers are auto-uppercased by Snowflake — use matching case in \\`database\\`, \\`schema_name\\`, \\`warehouse\\`, and \\`role\\` parameters to avoid 'object not found' errors. Always apply explicit time-range filters and a LIMIT clause to unbounded SELECT queries to prevent large, slow result sets.",
|
|
183
|
-
input: SnowflakeExecuteSqlInput,
|
|
184
|
-
output: SnowflakeExecuteSqlOutput,
|
|
185
|
-
async run(input) {
|
|
186
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_EXECUTE_SQL", input);
|
|
187
|
-
return SnowflakeExecuteSqlOutput.parse(result);
|
|
188
|
-
}
|
|
189
|
-
});
|
|
190
|
-
//#endregion
|
|
191
|
-
//#region src/actions/fetch-catalog-integration.ts
|
|
192
|
-
const SnowflakeFetchCatalogIntegrationInput = zod.z.object({ name: zod.z.string().describe("The name (identifier) of the catalog integration to fetch details for. This is case-sensitive.") });
|
|
193
|
-
const SnowflakeFetchCatalogIntegrationCatalogSchema = zod.z.object({ catalog_source: zod.z.string().describe("The catalog source type. Common values include 'GLUE' (AWS Glue), 'POLARIS' (Snowflake Open Catalog), or 'ICEBERG_REST' (Apache Iceberg REST catalog).").optional() });
|
|
194
|
-
const SnowflakeFetchCatalogIntegrationOutput = zod.z.object({
|
|
195
|
-
name: zod.z.string().describe("The name (identifier) of the catalog integration.").optional(),
|
|
196
|
-
type: zod.z.string().describe("The type classification of the integration object.").optional(),
|
|
197
|
-
catalog: SnowflakeFetchCatalogIntegrationCatalogSchema.nullable().optional(),
|
|
198
|
-
comment: zod.z.string().describe("User-provided comment or description for the catalog integration.").optional(),
|
|
199
|
-
enabled: zod.z.boolean().describe("Whether the catalog integration is currently enabled (TRUE) or disabled (FALSE).").optional(),
|
|
200
|
-
category: zod.z.string().describe("The category classification of the catalog integration.").optional(),
|
|
201
|
-
created_on: zod.z.string().describe("ISO 8601 timestamp indicating when the catalog integration was created.").optional(),
|
|
202
|
-
table_format: zod.z.string().describe("The table format supported by this catalog integration. Typically 'ICEBERG' for Apache Iceberg tables.").optional()
|
|
203
|
-
});
|
|
204
|
-
const snowflakeFetchCatalogIntegration = snowflake.action({
|
|
205
|
-
slug: "snowflake-fetch-catalog-integration",
|
|
206
|
-
name: "Fetch Catalog Integration",
|
|
207
|
-
description: "Retrieves detailed configuration and metadata for a specific catalog integration. Catalog integrations allow Snowflake to connect to external Apache Iceberg catalogs (AWS Glue, Snowflake Open Catalog/Polaris, or Apache Iceberg REST catalogs) to query Iceberg tables managed by those external systems.",
|
|
208
|
-
input: SnowflakeFetchCatalogIntegrationInput,
|
|
209
|
-
output: SnowflakeFetchCatalogIntegrationOutput,
|
|
210
|
-
async run(input) {
|
|
211
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_FETCH_CATALOG_INTEGRATION", input);
|
|
212
|
-
return SnowflakeFetchCatalogIntegrationOutput.parse(result);
|
|
213
|
-
}
|
|
214
|
-
});
|
|
215
|
-
//#endregion
|
|
216
|
-
//#region src/actions/get-active-scheduled-maintenances.ts
|
|
217
|
-
const SnowflakeGetActiveScheduledMaintenancesInput = zod.z.object({});
|
|
218
|
-
const SnowflakeGetActiveScheduledMaintenancesPageSchema = zod.z.object({
|
|
219
|
-
id: zod.z.string().describe("The unique identifier of the status page."),
|
|
220
|
-
url: zod.z.string().describe("The URL of the status page."),
|
|
221
|
-
name: zod.z.string().describe("The name of the status page."),
|
|
222
|
-
time_zone: zod.z.string().describe("The time zone of the status page."),
|
|
223
|
-
updated_at: zod.z.string().describe("The last update time of the status page.")
|
|
224
|
-
});
|
|
225
|
-
const SnowflakeGetActiveScheduledMaintenancesIncidentUpdateSchema = zod.z.object({
|
|
226
|
-
id: zod.z.string().describe("The unique identifier of the incident update."),
|
|
227
|
-
body: zod.z.string().describe("The body of the incident update."),
|
|
228
|
-
status: zod.z.string().describe("The status of the incident update."),
|
|
229
|
-
created_at: zod.z.string().describe("The creation time of the incident update."),
|
|
230
|
-
display_at: zod.z.string().describe("The display time of the incident update."),
|
|
231
|
-
updated_at: zod.z.string().describe("The last update time of the incident update."),
|
|
232
|
-
incident_id: zod.z.string().describe("The unique identifier of the incident.")
|
|
233
|
-
});
|
|
234
|
-
const SnowflakeGetActiveScheduledMaintenancesScheduledMaintenanceSchema = zod.z.object({
|
|
235
|
-
id: zod.z.string().describe("The unique identifier of the maintenance."),
|
|
236
|
-
name: zod.z.string().describe("The name of the maintenance."),
|
|
237
|
-
impact: zod.z.string().describe("The impact level of the maintenance."),
|
|
238
|
-
status: zod.z.string().describe("The current status of the maintenance."),
|
|
239
|
-
page_id: zod.z.string().describe("The unique identifier of the status page."),
|
|
240
|
-
shortlink: zod.z.string().describe("A short URL link to the maintenance details."),
|
|
241
|
-
created_at: zod.z.string().describe("The creation time of the maintenance."),
|
|
242
|
-
started_at: zod.z.string().describe("The actual start time of the maintenance.").optional(),
|
|
243
|
-
updated_at: zod.z.string().describe("The last update time of the maintenance."),
|
|
244
|
-
resolved_at: zod.z.string().describe("The time when the maintenance was resolved.").optional(),
|
|
245
|
-
monitoring_at: zod.z.string().describe("The time when monitoring started for the maintenance.").optional(),
|
|
246
|
-
scheduled_for: zod.z.string().describe("The scheduled start time of the maintenance."),
|
|
247
|
-
scheduled_until: zod.z.string().describe("The scheduled end time of the maintenance."),
|
|
248
|
-
incident_updates: zod.z.array(SnowflakeGetActiveScheduledMaintenancesIncidentUpdateSchema).describe("A list of updates related to the maintenance.")
|
|
249
|
-
});
|
|
250
|
-
const SnowflakeGetActiveScheduledMaintenancesOutput = zod.z.object({
|
|
251
|
-
page: SnowflakeGetActiveScheduledMaintenancesPageSchema.nullable(),
|
|
252
|
-
scheduled_maintenances: zod.z.array(SnowflakeGetActiveScheduledMaintenancesScheduledMaintenanceSchema).describe("A list of active scheduled maintenances currently in progress or being verified.")
|
|
253
|
-
});
|
|
254
|
-
const snowflakeGetActiveScheduledMaintenances = snowflake.action({
|
|
255
|
-
slug: "snowflake-get-active-scheduled-maintenances",
|
|
256
|
-
name: "Get Active Scheduled Maintenances",
|
|
257
|
-
description: "Retrieves a list of any active scheduled maintenances currently in the In Progress or Verifying state.",
|
|
258
|
-
input: SnowflakeGetActiveScheduledMaintenancesInput,
|
|
259
|
-
output: SnowflakeGetActiveScheduledMaintenancesOutput,
|
|
260
|
-
async run(input) {
|
|
261
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_GET_ACTIVE_SCHEDULED_MAINTENANCES", input);
|
|
262
|
-
return SnowflakeGetActiveScheduledMaintenancesOutput.parse(result);
|
|
263
|
-
}
|
|
264
|
-
});
|
|
265
|
-
//#endregion
|
|
266
|
-
//#region src/actions/get-all-scheduled-maintenances.ts
|
|
267
|
-
const SnowflakeGetAllScheduledMaintenancesInput = zod.z.object({});
|
|
268
|
-
const SnowflakeGetAllScheduledMaintenancesPageSchema = zod.z.object({
|
|
269
|
-
id: zod.z.string().describe("The ID of the page."),
|
|
270
|
-
url: zod.z.string().describe("The URL of the page."),
|
|
271
|
-
name: zod.z.string().describe("The name of the page."),
|
|
272
|
-
time_zone: zod.z.string().describe("The time zone of the page."),
|
|
273
|
-
updated_at: zod.z.string().describe("The timestamp of the last update.")
|
|
274
|
-
});
|
|
275
|
-
const SnowflakeGetAllScheduledMaintenancesAffectedComponentSchema = zod.z.object({
|
|
276
|
-
code: zod.z.string().describe("The code of the affected component."),
|
|
277
|
-
name: zod.z.string().describe("The name of the affected component."),
|
|
278
|
-
new_status: zod.z.string().describe("The new status of the component."),
|
|
279
|
-
old_status: zod.z.string().describe("The previous status of the component.")
|
|
280
|
-
});
|
|
281
|
-
const SnowflakeGetAllScheduledMaintenancesIncidentUpdateSchema = zod.z.object({
|
|
282
|
-
id: zod.z.string().describe("The ID of the incident update."),
|
|
283
|
-
body: zod.z.string().describe("The body of the incident update."),
|
|
284
|
-
status: zod.z.string().describe("The status of the incident update."),
|
|
285
|
-
tweet_id: zod.z.string().describe("Twitter tweet ID if posted.").optional(),
|
|
286
|
-
created_at: zod.z.string().describe("The timestamp of the incident update creation."),
|
|
287
|
-
display_at: zod.z.string().describe("The timestamp to display the incident update."),
|
|
288
|
-
updated_at: zod.z.string().describe("The timestamp of the last update."),
|
|
289
|
-
incident_id: zod.z.string().describe("The ID of the incident."),
|
|
290
|
-
custom_tweet: zod.z.string().describe("Custom tweet text if available.").optional(),
|
|
291
|
-
affected_components: zod.z.array(SnowflakeGetAllScheduledMaintenancesAffectedComponentSchema).describe("List of affected components with their status changes.").optional(),
|
|
292
|
-
deliver_notifications: zod.z.boolean().default(false).describe("Whether notifications were delivered for this update.").optional()
|
|
293
|
-
});
|
|
294
|
-
const SnowflakeGetAllScheduledMaintenancesScheduledMaintenanceSchema = zod.z.object({
|
|
295
|
-
id: zod.z.string().describe("The ID of the scheduled maintenance."),
|
|
296
|
-
name: zod.z.string().describe("The name of the scheduled maintenance."),
|
|
297
|
-
impact: zod.z.string().describe("The impact of the scheduled maintenance."),
|
|
298
|
-
status: zod.z.string().describe("The status of the scheduled maintenance."),
|
|
299
|
-
page_id: zod.z.string().describe("The ID of the page."),
|
|
300
|
-
shortlink: zod.z.string().describe("The shortlink of the scheduled maintenance."),
|
|
301
|
-
created_at: zod.z.string().describe("The timestamp of the scheduled maintenance creation."),
|
|
302
|
-
started_at: zod.z.string().describe("The timestamp when the maintenance actually started.").optional(),
|
|
303
|
-
updated_at: zod.z.string().describe("The timestamp of the last update."),
|
|
304
|
-
resolved_at: zod.z.string().describe("The timestamp of the resolution.").optional(),
|
|
305
|
-
monitoring_at: zod.z.string().describe("The timestamp of the monitoring start.").optional(),
|
|
306
|
-
scheduled_for: zod.z.string().describe("The timestamp of the scheduled maintenance.").optional(),
|
|
307
|
-
scheduled_until: zod.z.string().describe("The timestamp of the scheduled maintenance end.").optional(),
|
|
308
|
-
incident_updates: zod.z.array(SnowflakeGetAllScheduledMaintenancesIncidentUpdateSchema).describe("A list of incident updates.")
|
|
309
|
-
});
|
|
310
|
-
const SnowflakeGetAllScheduledMaintenancesOutput = zod.z.object({
|
|
311
|
-
page: SnowflakeGetAllScheduledMaintenancesPageSchema.nullable(),
|
|
312
|
-
scheduled_maintenances: zod.z.array(SnowflakeGetAllScheduledMaintenancesScheduledMaintenanceSchema).describe("A list of scheduled maintenances.")
|
|
313
|
-
});
|
|
314
|
-
const snowflakeGetAllScheduledMaintenances = snowflake.action({
|
|
315
|
-
slug: "snowflake-get-all-scheduled-maintenances",
|
|
316
|
-
name: "Get All Scheduled Maintenances",
|
|
317
|
-
description: "Retrieves a list of the 50 most recent scheduled maintenances, including those in the Completed state.",
|
|
318
|
-
input: SnowflakeGetAllScheduledMaintenancesInput,
|
|
319
|
-
output: SnowflakeGetAllScheduledMaintenancesOutput,
|
|
320
|
-
async run(input) {
|
|
321
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_GET_ALL_SCHEDULED_MAINTENANCES", input);
|
|
322
|
-
return SnowflakeGetAllScheduledMaintenancesOutput.parse(result);
|
|
323
|
-
}
|
|
324
|
-
});
|
|
325
|
-
//#endregion
|
|
326
|
-
//#region src/actions/get-component-status.ts
|
|
327
|
-
const SnowflakeGetComponentStatusInput = zod.z.object({ limit: zod.z.number().int().describe("Limit number of components returned.").optional() });
|
|
328
|
-
const SnowflakeGetComponentStatusPageSchema = zod.z.object({
|
|
329
|
-
id: zod.z.string().describe("The unique identifier of the page."),
|
|
330
|
-
url: zod.z.string().describe("The URL of the page."),
|
|
331
|
-
name: zod.z.string().describe("The name of the page."),
|
|
332
|
-
updated_at: zod.z.string().describe("The timestamp when the page was last updated.")
|
|
333
|
-
});
|
|
334
|
-
const SnowflakeGetComponentStatusComponentSchema = zod.z.object({
|
|
335
|
-
id: zod.z.string().describe("The unique identifier of the component."),
|
|
336
|
-
name: zod.z.string().describe("The name of the component."),
|
|
337
|
-
group: zod.z.boolean().describe("Indicates if the component is a group."),
|
|
338
|
-
status: zod.z.string().describe("The current status of the component."),
|
|
339
|
-
page_id: zod.z.string().describe("The unique identifier of the page the component belongs to."),
|
|
340
|
-
group_id: zod.z.string().describe("The unique identifier of the group the component belongs to.").optional(),
|
|
341
|
-
position: zod.z.number().int().describe("The position of the component."),
|
|
342
|
-
showcase: zod.z.boolean().describe("Indicates if the component is showcased."),
|
|
343
|
-
created_at: zod.z.string().describe("The timestamp when the component was created."),
|
|
344
|
-
start_date: zod.z.string().describe("The start date of the component.").optional(),
|
|
345
|
-
updated_at: zod.z.string().describe("The timestamp when the component was last updated."),
|
|
346
|
-
description: zod.z.string().describe("A description of the component.").optional(),
|
|
347
|
-
only_show_if_degraded: zod.z.boolean().describe("Indicates if the component should only be shown if it is degraded.")
|
|
348
|
-
});
|
|
349
|
-
const SnowflakeGetComponentStatusOutput = zod.z.object({
|
|
350
|
-
page: SnowflakeGetComponentStatusPageSchema.nullable(),
|
|
351
|
-
components: zod.z.array(SnowflakeGetComponentStatusComponentSchema).describe("A list of components and their current status.")
|
|
352
|
-
});
|
|
353
|
-
const snowflakeGetComponentStatus = snowflake.action({
|
|
354
|
-
slug: "snowflake-get-component-status",
|
|
355
|
-
name: "Get Component Status",
|
|
356
|
-
description: "Retrieves the status of individual components, each listed with its current status.",
|
|
357
|
-
input: SnowflakeGetComponentStatusInput,
|
|
358
|
-
output: SnowflakeGetComponentStatusOutput,
|
|
359
|
-
async run(input) {
|
|
360
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_GET_COMPONENT_STATUS", input);
|
|
361
|
-
return SnowflakeGetComponentStatusOutput.parse(result);
|
|
362
|
-
}
|
|
363
|
-
});
|
|
364
|
-
//#endregion
|
|
365
|
-
//#region src/actions/get-status-rollup.ts
|
|
366
|
-
const SnowflakeGetStatusRollupInput = zod.z.object({});
|
|
367
|
-
const SnowflakeGetStatusRollupPageSchema = zod.z.object({
|
|
368
|
-
id: zod.z.string().describe("The ID of the status page."),
|
|
369
|
-
url: zod.z.string().describe("The URL of the status page."),
|
|
370
|
-
name: zod.z.string().describe("The name of the status page."),
|
|
371
|
-
time_zone: zod.z.string().describe("The time zone of the status page."),
|
|
372
|
-
updated_at: zod.z.string().describe("The timestamp of the last update in ISO 8601 format.")
|
|
373
|
-
});
|
|
374
|
-
const SnowflakeGetStatusRollupStatusSchema = zod.z.object({
|
|
375
|
-
indicator: zod.z.string().describe("An indicator of the system status. Possible values include 'none' (all systems operational), 'minor' (minor issues), 'major' (major outage), 'critical' (critical outage)."),
|
|
376
|
-
description: zod.z.string().describe("A human-readable description of the overall system status.")
|
|
377
|
-
});
|
|
378
|
-
const SnowflakeGetStatusRollupOutput = zod.z.object({
|
|
379
|
-
page: SnowflakeGetStatusRollupPageSchema.nullable(),
|
|
380
|
-
status: SnowflakeGetStatusRollupStatusSchema.nullable()
|
|
381
|
-
});
|
|
382
|
-
const snowflakeGetStatusRollup = snowflake.action({
|
|
383
|
-
slug: "snowflake-get-status-rollup",
|
|
384
|
-
name: "Get Status Rollup",
|
|
385
|
-
description: "Retrieves the status rollup for the entire page, including indicators and human-readable descriptions of the blended component status.",
|
|
386
|
-
input: SnowflakeGetStatusRollupInput,
|
|
387
|
-
output: SnowflakeGetStatusRollupOutput,
|
|
388
|
-
async run(input) {
|
|
389
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_GET_STATUS_ROLLUP", input);
|
|
390
|
-
return SnowflakeGetStatusRollupOutput.parse(result);
|
|
391
|
-
}
|
|
392
|
-
});
|
|
393
|
-
//#endregion
|
|
394
|
-
//#region src/actions/get-status-summary.ts
|
|
395
|
-
const SnowflakeGetStatusSummaryInput = zod.z.object({});
|
|
396
|
-
const SnowflakeGetStatusSummaryPageSchema = zod.z.object({
|
|
397
|
-
id: zod.z.string().describe("The ID of the page.").optional(),
|
|
398
|
-
url: zod.z.string().describe("The URL of the page.").optional(),
|
|
399
|
-
name: zod.z.string().describe("The name of the page.").optional(),
|
|
400
|
-
time_zone: zod.z.string().describe("The time zone of the page.").optional(),
|
|
401
|
-
updated_at: zod.z.string().describe("The timestamp of the last update.").optional()
|
|
402
|
-
});
|
|
403
|
-
const SnowflakeGetStatusSummaryStatusSchema = zod.z.object({
|
|
404
|
-
indicator: zod.z.string().describe("The indicator of the status.").optional(),
|
|
405
|
-
description: zod.z.string().describe("The description of the status.").optional()
|
|
406
|
-
});
|
|
407
|
-
const SnowflakeGetStatusSummaryIncidentUpdateSchema = zod.z.object({
|
|
408
|
-
id: zod.z.string().describe("The ID of the incident update.").optional(),
|
|
409
|
-
body: zod.z.string().describe("The body of the incident update.").optional(),
|
|
410
|
-
status: zod.z.string().describe("The status of the incident update.").optional(),
|
|
411
|
-
created_at: zod.z.string().describe("The timestamp of the incident update creation.").optional(),
|
|
412
|
-
display_at: zod.z.string().describe("The timestamp to display the incident update.").optional(),
|
|
413
|
-
updated_at: zod.z.string().describe("The timestamp of the last update.").optional(),
|
|
414
|
-
incident_id: zod.z.string().describe("The ID of the incident.").optional()
|
|
415
|
-
});
|
|
416
|
-
const SnowflakeGetStatusSummaryIncidentSchema = zod.z.object({
|
|
417
|
-
id: zod.z.string().describe("The ID of the incident.").optional(),
|
|
418
|
-
name: zod.z.string().describe("The name of the incident.").optional(),
|
|
419
|
-
impact: zod.z.string().describe("The impact of the incident.").optional(),
|
|
420
|
-
status: zod.z.string().describe("The status of the incident.").optional(),
|
|
421
|
-
page_id: zod.z.string().describe("The ID of the page the incident belongs to.").optional(),
|
|
422
|
-
shortlink: zod.z.string().describe("The shortlink of the incident.").optional(),
|
|
423
|
-
created_at: zod.z.string().describe("The timestamp of the incident creation.").optional(),
|
|
424
|
-
updated_at: zod.z.string().describe("The timestamp of the last update.").optional(),
|
|
425
|
-
resolved_at: zod.z.string().describe("The timestamp of the incident resolution.").optional(),
|
|
426
|
-
monitoring_at: zod.z.string().describe("The timestamp of the monitoring start.").optional(),
|
|
427
|
-
incident_updates: zod.z.array(SnowflakeGetStatusSummaryIncidentUpdateSchema).default([]).describe("A list of incident updates.").optional()
|
|
428
|
-
});
|
|
429
|
-
const SnowflakeGetStatusSummaryComponentSchema = zod.z.object({
|
|
430
|
-
id: zod.z.string().describe("The ID of the component.").optional(),
|
|
431
|
-
name: zod.z.string().describe("The name of the component.").optional(),
|
|
432
|
-
group: zod.z.boolean().describe("Whether this component is a group containing other components.").optional(),
|
|
433
|
-
status: zod.z.string().describe("The status of the component.").optional(),
|
|
434
|
-
page_id: zod.z.string().describe("The ID of the page the component belongs to.").optional(),
|
|
435
|
-
group_id: zod.z.string().describe("The ID of the group this component belongs to.").optional(),
|
|
436
|
-
position: zod.z.number().int().describe("The position of the component.").optional(),
|
|
437
|
-
showcase: zod.z.boolean().describe("Whether the component is showcased on the status page.").optional(),
|
|
438
|
-
components: zod.z.array(zod.z.string()).describe("List of component IDs that belong to this group (if this is a group component).").optional(),
|
|
439
|
-
created_at: zod.z.string().describe("The timestamp of the component creation.").optional(),
|
|
440
|
-
start_date: zod.z.string().describe("The start date of the component.").optional(),
|
|
441
|
-
updated_at: zod.z.string().describe("The timestamp of the last update.").optional(),
|
|
442
|
-
description: zod.z.string().describe("The description of the component.").optional(),
|
|
443
|
-
only_show_if_degraded: zod.z.boolean().describe("Whether to only show this component if it's degraded.").optional()
|
|
444
|
-
});
|
|
445
|
-
const SnowflakeGetStatusSummaryScheduledMaintenanceSchema = zod.z.object({
|
|
446
|
-
id: zod.z.string().describe("The ID of the scheduled maintenance.").optional(),
|
|
447
|
-
name: zod.z.string().describe("The name of the scheduled maintenance.").optional(),
|
|
448
|
-
impact: zod.z.string().describe("The impact of the scheduled maintenance.").optional(),
|
|
449
|
-
status: zod.z.string().describe("The status of the scheduled maintenance.").optional(),
|
|
450
|
-
page_id: zod.z.string().describe("The ID of the page the scheduled maintenance belongs to.").optional(),
|
|
451
|
-
shortlink: zod.z.string().describe("The shortlink of the scheduled maintenance.").optional(),
|
|
452
|
-
created_at: zod.z.string().describe("The timestamp of the scheduled maintenance creation.").optional(),
|
|
453
|
-
updated_at: zod.z.string().describe("The timestamp of the last update.").optional(),
|
|
454
|
-
resolved_at: zod.z.string().describe("The timestamp of the scheduled maintenance resolution.").optional(),
|
|
455
|
-
monitoring_at: zod.z.string().describe("The timestamp of the monitoring start.").optional(),
|
|
456
|
-
scheduled_for: zod.z.string().describe("The timestamp of the scheduled maintenance start.").optional(),
|
|
457
|
-
scheduled_until: zod.z.string().describe("The timestamp of the scheduled maintenance end.").optional(),
|
|
458
|
-
incident_updates: zod.z.array(SnowflakeGetStatusSummaryIncidentUpdateSchema).default([]).describe("A list of incident updates.").optional()
|
|
459
|
-
});
|
|
460
|
-
const SnowflakeGetStatusSummaryOutput = zod.z.object({
|
|
461
|
-
page: SnowflakeGetStatusSummaryPageSchema.nullable().optional(),
|
|
462
|
-
status: SnowflakeGetStatusSummaryStatusSchema.nullable().optional(),
|
|
463
|
-
incidents: zod.z.array(SnowflakeGetStatusSummaryIncidentSchema).default([]).describe("A list of incidents.").optional(),
|
|
464
|
-
components: zod.z.array(SnowflakeGetStatusSummaryComponentSchema).default([]).describe("A list of components.").optional(),
|
|
465
|
-
scheduled_maintenances: zod.z.array(SnowflakeGetStatusSummaryScheduledMaintenanceSchema).default([]).describe("A list of scheduled maintenances.").optional()
|
|
466
|
-
});
|
|
467
|
-
const snowflakeGetStatusSummary = snowflake.action({
|
|
468
|
-
slug: "snowflake-get-status-summary",
|
|
469
|
-
name: "Get Status Summary",
|
|
470
|
-
description: "Retrieves the current status summary from Snowflake's public status page (status.snowflake.com). Returns overall system status, operational status of all regional components (AWS, Azure, GCP regions), any unresolved incidents, and upcoming or in-progress scheduled maintenances. This is a public endpoint that provides global Snowflake service status, not account-specific information.",
|
|
471
|
-
input: SnowflakeGetStatusSummaryInput,
|
|
472
|
-
output: SnowflakeGetStatusSummaryOutput,
|
|
473
|
-
async run(input) {
|
|
474
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_GET_STATUS_SUMMARY", input);
|
|
475
|
-
return SnowflakeGetStatusSummaryOutput.parse(result);
|
|
476
|
-
}
|
|
477
|
-
});
|
|
478
|
-
//#endregion
|
|
479
|
-
//#region src/actions/get-unresolved-incidents.ts
|
|
480
|
-
const SnowflakeGetUnresolvedIncidentsInput = zod.z.object({});
|
|
481
|
-
const SnowflakeGetUnresolvedIncidentsPageInfoSchema = zod.z.object({
|
|
482
|
-
id: zod.z.string().describe("The unique identifier of the Snowflake status page."),
|
|
483
|
-
url: zod.z.string().describe("The URL of the status page."),
|
|
484
|
-
name: zod.z.string().describe("The name of the service (Snowflake)."),
|
|
485
|
-
time_zone: zod.z.string().describe("The timezone used for the status page (e.g., Etc/UTC)."),
|
|
486
|
-
updated_at: zod.z.string().describe("The timestamp when the status page was last updated.")
|
|
487
|
-
});
|
|
488
|
-
const SnowflakeGetUnresolvedIncidentsIncidentUpdateSchema = zod.z.object({
|
|
489
|
-
id: zod.z.string().describe("The ID of the incident update."),
|
|
490
|
-
body: zod.z.string().describe("The body of the incident update."),
|
|
491
|
-
status: zod.z.string().describe("The status of the incident update."),
|
|
492
|
-
created_at: zod.z.string().describe("The timestamp when the incident update was created."),
|
|
493
|
-
display_at: zod.z.string().describe("The timestamp when the incident update should be displayed."),
|
|
494
|
-
updated_at: zod.z.string().describe("The timestamp when the incident update was last updated."),
|
|
495
|
-
incident_id: zod.z.string().describe("The ID of the incident.")
|
|
496
|
-
});
|
|
497
|
-
const SnowflakeGetUnresolvedIncidentsIncidentSchema = zod.z.object({
|
|
498
|
-
id: zod.z.string().describe("The ID of the incident."),
|
|
499
|
-
name: zod.z.string().describe("The name of the incident."),
|
|
500
|
-
impact: zod.z.string().describe("The impact of the incident."),
|
|
501
|
-
status: zod.z.string().describe("The status of the incident."),
|
|
502
|
-
page_id: zod.z.string().describe("The ID of the page."),
|
|
503
|
-
shortlink: zod.z.string().describe("The shortlink for the incident."),
|
|
504
|
-
created_at: zod.z.string().describe("The timestamp when the incident was created."),
|
|
505
|
-
updated_at: zod.z.string().describe("The timestamp when the incident was last updated."),
|
|
506
|
-
resolved_at: zod.z.string().describe("The timestamp when the incident was resolved.").optional(),
|
|
507
|
-
monitoring_at: zod.z.string().describe("The timestamp when the incident monitoring started.").optional(),
|
|
508
|
-
incident_updates: zod.z.array(SnowflakeGetUnresolvedIncidentsIncidentUpdateSchema).describe("A list of incident updates.")
|
|
509
|
-
});
|
|
510
|
-
const SnowflakeGetUnresolvedIncidentsOutput = zod.z.object({
|
|
511
|
-
page: SnowflakeGetUnresolvedIncidentsPageInfoSchema.nullable(),
|
|
512
|
-
incidents: zod.z.array(SnowflakeGetUnresolvedIncidentsIncidentSchema).describe("A list of unresolved incidents currently in the Investigating, Identified, or Monitoring state. Returns an empty list if there are no active incidents.")
|
|
513
|
-
});
|
|
514
|
-
const snowflakeGetUnresolvedIncidents = snowflake.action({
|
|
515
|
-
slug: "snowflake-get-unresolved-incidents",
|
|
516
|
-
name: "Get Unresolved Incidents",
|
|
517
|
-
description: "Retrieves a list of any unresolved incidents from the Snowflake status page. This endpoint returns incidents currently in the Investigating, Identified, or Monitoring state. Returns an empty list if there are no active incidents. This is a public status page API that does not require authentication.",
|
|
518
|
-
input: SnowflakeGetUnresolvedIncidentsInput,
|
|
519
|
-
output: SnowflakeGetUnresolvedIncidentsOutput,
|
|
520
|
-
async run(input) {
|
|
521
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_GET_UNRESOLVED_INCIDENTS", input);
|
|
522
|
-
return SnowflakeGetUnresolvedIncidentsOutput.parse(result);
|
|
523
|
-
}
|
|
524
|
-
});
|
|
525
|
-
//#endregion
|
|
526
|
-
//#region src/actions/get-upcoming-scheduled-maintenances.ts
|
|
527
|
-
const SnowflakeGetUpcomingScheduledMaintenancesInput = zod.z.record(zod.z.string(), zod.z.unknown()).describe("Request model for getting upcoming scheduled maintenances.");
|
|
528
|
-
const SnowflakeGetUpcomingScheduledMaintenancesPageInfoSchema = zod.z.object({
|
|
529
|
-
id: zod.z.string().describe("The ID of the Snowflake status page."),
|
|
530
|
-
url: zod.z.string().describe("The URL of the status page."),
|
|
531
|
-
name: zod.z.string().describe("The name of the status page."),
|
|
532
|
-
time_zone: zod.z.string().describe("The time zone of the status page."),
|
|
533
|
-
updated_at: zod.z.string().describe("The timestamp when the status page was last updated.")
|
|
534
|
-
});
|
|
535
|
-
const SnowflakeGetUpcomingScheduledMaintenancesIncidentUpdateSchema = zod.z.object({
|
|
536
|
-
id: zod.z.string().describe("The ID of the incident update."),
|
|
537
|
-
body: zod.z.string().describe("The body of the incident update."),
|
|
538
|
-
status: zod.z.string().describe("The status of the incident update."),
|
|
539
|
-
created_at: zod.z.string().describe("The timestamp when the incident update was created."),
|
|
540
|
-
display_at: zod.z.string().describe("The timestamp when the incident update should be displayed."),
|
|
541
|
-
updated_at: zod.z.string().describe("The timestamp when the incident update was last updated."),
|
|
542
|
-
incident_id: zod.z.string().describe("The ID of the incident.")
|
|
543
|
-
});
|
|
544
|
-
const SnowflakeGetUpcomingScheduledMaintenancesScheduledMaintenanceSchema = zod.z.object({
|
|
545
|
-
id: zod.z.string().describe("The ID of the scheduled maintenance."),
|
|
546
|
-
name: zod.z.string().describe("The name of the scheduled maintenance."),
|
|
547
|
-
impact: zod.z.string().describe("The impact of the scheduled maintenance."),
|
|
548
|
-
status: zod.z.string().describe("The status of the scheduled maintenance."),
|
|
549
|
-
page_id: zod.z.string().describe("The ID of the page."),
|
|
550
|
-
shortlink: zod.z.string().describe("A short link to the scheduled maintenance."),
|
|
551
|
-
created_at: zod.z.string().describe("The timestamp when the scheduled maintenance was created."),
|
|
552
|
-
updated_at: zod.z.string().describe("The timestamp when the scheduled maintenance was last updated."),
|
|
553
|
-
resolved_at: zod.z.string().describe("The timestamp when the scheduled maintenance was resolved.").optional(),
|
|
554
|
-
monitoring_at: zod.z.string().describe("The timestamp when the scheduled maintenance was last monitored.").optional(),
|
|
555
|
-
scheduled_for: zod.z.string().describe("The timestamp when the maintenance is scheduled for."),
|
|
556
|
-
scheduled_until: zod.z.string().describe("The timestamp when the maintenance is scheduled until."),
|
|
557
|
-
incident_updates: zod.z.array(SnowflakeGetUpcomingScheduledMaintenancesIncidentUpdateSchema).describe("A list of incident updates for the scheduled maintenance.")
|
|
558
|
-
});
|
|
559
|
-
const SnowflakeGetUpcomingScheduledMaintenancesOutput = zod.z.object({
|
|
560
|
-
page: SnowflakeGetUpcomingScheduledMaintenancesPageInfoSchema.nullable(),
|
|
561
|
-
scheduled_maintenances: zod.z.array(SnowflakeGetUpcomingScheduledMaintenancesScheduledMaintenanceSchema).describe("A list of upcoming scheduled maintenances that are still in the 'Scheduled' state.")
|
|
562
|
-
});
|
|
563
|
-
const snowflakeGetUpcomingScheduledMaintenances = snowflake.action({
|
|
564
|
-
slug: "snowflake-get-upcoming-scheduled-maintenances",
|
|
565
|
-
name: "Get Upcoming Scheduled Maintenances",
|
|
566
|
-
description: "Retrieves upcoming scheduled maintenances from Snowflake's public status page. This action queries the Snowflake status API to get a list of any scheduled maintenance events that are still in the 'Scheduled' state (not yet started or completed). The response includes maintenance details such as impact level, scheduled time windows, incident updates, and direct links to the maintenance notices. Note: This uses Snowflake's public status API and does not require authentication.",
|
|
567
|
-
input: SnowflakeGetUpcomingScheduledMaintenancesInput,
|
|
568
|
-
output: SnowflakeGetUpcomingScheduledMaintenancesOutput,
|
|
569
|
-
async run(input) {
|
|
570
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_GET_UPCOMING_SCHEDULED_MAINTENANCES", input);
|
|
571
|
-
return SnowflakeGetUpcomingScheduledMaintenancesOutput.parse(result);
|
|
572
|
-
}
|
|
573
|
-
});
|
|
574
|
-
//#endregion
|
|
575
|
-
//#region src/actions/show-databases.ts
|
|
576
|
-
const SnowflakeShowDatabasesInput = zod.z.object({
|
|
577
|
-
role: zod.z.string().describe("Role to use when executing the statement.").optional(),
|
|
578
|
-
limit: zod.z.number().int().describe("Maximum number of rows to return. Cannot exceed 10000.").optional(),
|
|
579
|
-
terse: zod.z.boolean().default(false).describe("If true, returns only a subset of output columns (created_on, name, kind, database_name, schema_name).").optional(),
|
|
580
|
-
history: zod.z.boolean().default(false).describe("If true, includes dropped databases that are still within Time Travel retention period.").optional(),
|
|
581
|
-
timeout: zod.z.number().int().describe("Timeout in seconds for statement execution.").optional(),
|
|
582
|
-
from_name: zod.z.string().describe("Used with LIMIT for pagination. Returns results starting from databases whose names match this string.").optional(),
|
|
583
|
-
warehouse: zod.z.string().describe("Warehouse to use for the query (though SHOW DATABASES doesn't require a running warehouse).").optional(),
|
|
584
|
-
starts_with: zod.z.string().describe("Filters results by databases whose names start with this string. Case-sensitive.").optional(),
|
|
585
|
-
like_pattern: zod.z.string().describe("Filters results by database name using SQL wildcard pattern (% and _). Case-insensitive.").optional()
|
|
586
|
-
});
|
|
587
|
-
const SnowflakeShowDatabasesOutput = zod.z.object({
|
|
588
|
-
data: zod.z.array(zod.z.array(zod.z.union([
|
|
589
|
-
zod.z.string(),
|
|
590
|
-
zod.z.number().int(),
|
|
591
|
-
zod.z.number(),
|
|
592
|
-
zod.z.boolean()
|
|
593
|
-
]).nullable())).describe("List of databases with their metadata. Each row contains database information like name, creation date, owner, etc."),
|
|
594
|
-
columns: zod.z.array(zod.z.string()).describe("Column names in the result set.").optional()
|
|
595
|
-
});
|
|
596
|
-
const snowflakeShowDatabases = snowflake.action({
|
|
597
|
-
slug: "snowflake-show-databases",
|
|
598
|
-
name: "Show Databases",
|
|
599
|
-
description: "Lists all databases for which you have access privileges. Shows database metadata including name, creation date, owner, retention time, and more. Can filter results and include dropped databases within Time Travel retention period.",
|
|
600
|
-
input: SnowflakeShowDatabasesInput,
|
|
601
|
-
output: SnowflakeShowDatabasesOutput,
|
|
602
|
-
async run(input) {
|
|
603
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_SHOW_DATABASES", input);
|
|
604
|
-
return SnowflakeShowDatabasesOutput.parse(result);
|
|
605
|
-
}
|
|
606
|
-
});
|
|
607
|
-
//#endregion
|
|
608
|
-
//#region src/actions/show-schemas.ts
|
|
609
|
-
const SnowflakeShowSchemasInput = zod.z.object({
|
|
610
|
-
role: zod.z.string().describe("Role to use when executing the statement.").optional(),
|
|
611
|
-
limit: zod.z.number().int().describe("Maximum number of rows to return. Cannot exceed 10000.").optional(),
|
|
612
|
-
terse: zod.z.boolean().default(false).describe("If true, returns only a subset of output columns (created_on, name, kind, database_name, schema_name).").optional(),
|
|
613
|
-
history: zod.z.boolean().default(false).describe("If true, includes dropped schemas that are still within Time Travel retention period.").optional(),
|
|
614
|
-
timeout: zod.z.number().int().describe("Timeout in seconds for statement execution.").optional(),
|
|
615
|
-
database: zod.z.string().describe("Database context for the query.").optional(),
|
|
616
|
-
in_scope: zod.z.string().describe("Scope for the command. Options: 'ACCOUNT', 'DATABASE', or a specific database name.").optional(),
|
|
617
|
-
from_name: zod.z.string().describe("Used with LIMIT for pagination. Returns results starting from schemas whose names match this string.").optional(),
|
|
618
|
-
warehouse: zod.z.string().describe("Warehouse to use for the query (though SHOW SCHEMAS doesn't require a running warehouse).").optional(),
|
|
619
|
-
starts_with: zod.z.string().describe("Filters results by schemas whose names start with this string. Case-sensitive.").optional(),
|
|
620
|
-
like_pattern: zod.z.string().describe("Filters results by schema name using SQL wildcard pattern (% and _). Case-insensitive.").optional()
|
|
621
|
-
});
|
|
622
|
-
const SnowflakeShowSchemasOutput = zod.z.object({
|
|
623
|
-
data: zod.z.array(zod.z.array(zod.z.union([
|
|
624
|
-
zod.z.string(),
|
|
625
|
-
zod.z.number().int(),
|
|
626
|
-
zod.z.number(),
|
|
627
|
-
zod.z.boolean()
|
|
628
|
-
]).nullable())).describe("List of schemas with their metadata. Each row contains schema information like name, creation date, owner, database, etc."),
|
|
629
|
-
columns: zod.z.array(zod.z.string()).describe("Column names in the result set.").optional()
|
|
630
|
-
});
|
|
631
|
-
const snowflakeShowSchemas = snowflake.action({
|
|
632
|
-
slug: "snowflake-show-schemas",
|
|
633
|
-
name: "Show Schemas",
|
|
634
|
-
description: "Lists all schemas for which you have access privileges. Shows schema metadata including name, creation date, owner, database, retention time, and more. Can filter results and include dropped schemas within Time Travel retention period.",
|
|
635
|
-
input: SnowflakeShowSchemasInput,
|
|
636
|
-
output: SnowflakeShowSchemasOutput,
|
|
637
|
-
async run(input) {
|
|
638
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_SHOW_SCHEMAS", input);
|
|
639
|
-
return SnowflakeShowSchemasOutput.parse(result);
|
|
640
|
-
}
|
|
641
|
-
});
|
|
642
|
-
//#endregion
|
|
643
|
-
//#region src/actions/show-tables.ts
|
|
644
|
-
const SnowflakeShowTablesInput = zod.z.object({
|
|
645
|
-
role: zod.z.string().describe("Role to use when executing the statement.").optional(),
|
|
646
|
-
limit: zod.z.number().int().describe("Maximum number of rows to return. Cannot exceed 10000.").optional(),
|
|
647
|
-
terse: zod.z.boolean().default(false).describe("If true, returns only a subset of output columns (created_on, name, kind, database_name, schema_name).").optional(),
|
|
648
|
-
schema: zod.z.string().describe("Schema context for the query.").optional(),
|
|
649
|
-
history: zod.z.boolean().default(false).describe("If true, includes dropped tables that are still within Time Travel retention period.").optional(),
|
|
650
|
-
timeout: zod.z.number().int().describe("Timeout in seconds for statement execution.").optional(),
|
|
651
|
-
database: zod.z.string().describe("Database context for the query.").optional(),
|
|
652
|
-
in_scope: zod.z.string().describe("Scope for the command. Options: 'ACCOUNT', 'DATABASE', 'SCHEMA', or specific database/schema names.").optional(),
|
|
653
|
-
from_name: zod.z.string().describe("Used with LIMIT for pagination. Returns results starting from tables whose names match this string.").optional(),
|
|
654
|
-
warehouse: zod.z.string().describe("Warehouse to use for the query (though SHOW TABLES doesn't require a running warehouse).").optional(),
|
|
655
|
-
starts_with: zod.z.string().describe("Filters results by tables whose names start with this string. Case-sensitive.").optional(),
|
|
656
|
-
like_pattern: zod.z.string().describe("Filters results by table name using SQL wildcard pattern (% and _). Case-insensitive.").optional()
|
|
657
|
-
});
|
|
658
|
-
const SnowflakeShowTablesOutput = zod.z.object({
|
|
659
|
-
data: zod.z.array(zod.z.array(zod.z.union([
|
|
660
|
-
zod.z.string(),
|
|
661
|
-
zod.z.number().int(),
|
|
662
|
-
zod.z.number(),
|
|
663
|
-
zod.z.boolean()
|
|
664
|
-
]).nullable())).describe("List of tables with their metadata. Each row contains table information like name, creation date, owner, database, schema, row count, size, etc."),
|
|
665
|
-
columns: zod.z.array(zod.z.string()).describe("Column names in the result set.").optional()
|
|
666
|
-
});
|
|
667
|
-
const snowflakeShowTables = snowflake.action({
|
|
668
|
-
slug: "snowflake-show-tables",
|
|
669
|
-
name: "Show Tables",
|
|
670
|
-
description: "Lists all tables for which you have access privileges. Shows table metadata including name, creation date, owner, database, schema, row count, size in bytes, clustering keys, and more. Can filter results and include dropped tables within Time Travel retention period.",
|
|
671
|
-
input: SnowflakeShowTablesInput,
|
|
672
|
-
output: SnowflakeShowTablesOutput,
|
|
673
|
-
async run(input) {
|
|
674
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_SHOW_TABLES", input);
|
|
675
|
-
return SnowflakeShowTablesOutput.parse(result);
|
|
676
|
-
}
|
|
677
|
-
});
|
|
678
|
-
//#endregion
|
|
679
|
-
//#region src/actions/validate-credential.ts
|
|
680
|
-
const SnowflakeValidateCredentialInput = zod.z.object({}).describe("Request model for validating Snowflake credentials.");
|
|
681
|
-
const SnowflakeValidateCredentialOutput = zod.z.object({
|
|
682
|
-
message: zod.z.string().describe("Additional status message or error details").optional(),
|
|
683
|
-
is_valid: zod.z.boolean().describe("Indicates whether the credentials are valid and the session is active"),
|
|
684
|
-
session_id: zod.z.string().describe("Unique system identifier for the Snowflake session if credentials are valid").optional()
|
|
685
|
-
}).describe("Response model for credential validation.");
|
|
686
|
-
const snowflakeValidateCredential = snowflake.action({
|
|
687
|
-
slug: "snowflake-validate-credential",
|
|
688
|
-
name: "Validate Credential",
|
|
689
|
-
description: "Validates Snowflake credentials by executing a lightweight test query. Returns session information if credentials are valid, or error details if authentication fails. Use this action when you need to verify that API credentials are properly configured and have access to the Snowflake account before executing other operations. This check does not require compute resources (warehouse) and completes quickly.",
|
|
690
|
-
input: SnowflakeValidateCredentialInput,
|
|
691
|
-
output: SnowflakeValidateCredentialOutput,
|
|
692
|
-
async run(input) {
|
|
693
|
-
const result = await executeSnowflakeTool("SNOWFLAKE_VALIDATE_CREDENTIAL", input);
|
|
694
|
-
return SnowflakeValidateCredentialOutput.parse(result);
|
|
695
|
-
}
|
|
696
|
-
});
|
|
697
|
-
//#endregion
|
|
698
|
-
Object.defineProperty(exports, "snowflake", {
|
|
699
|
-
enumerable: true,
|
|
700
|
-
get: function() {
|
|
701
|
-
return snowflake;
|
|
702
|
-
}
|
|
703
|
-
});
|
|
704
|
-
Object.defineProperty(exports, "snowflakeCancelStatementExecution", {
|
|
705
|
-
enumerable: true,
|
|
706
|
-
get: function() {
|
|
707
|
-
return snowflakeCancelStatementExecution;
|
|
708
|
-
}
|
|
709
|
-
});
|
|
710
|
-
Object.defineProperty(exports, "snowflakeCheckStatementStatus", {
|
|
711
|
-
enumerable: true,
|
|
712
|
-
get: function() {
|
|
713
|
-
return snowflakeCheckStatementStatus;
|
|
714
|
-
}
|
|
715
|
-
});
|
|
716
|
-
Object.defineProperty(exports, "snowflakeDropWarehouse", {
|
|
717
|
-
enumerable: true,
|
|
718
|
-
get: function() {
|
|
719
|
-
return snowflakeDropWarehouse;
|
|
720
|
-
}
|
|
721
|
-
});
|
|
722
|
-
Object.defineProperty(exports, "snowflakeExecuteSql", {
|
|
723
|
-
enumerable: true,
|
|
724
|
-
get: function() {
|
|
725
|
-
return snowflakeExecuteSql;
|
|
726
|
-
}
|
|
727
|
-
});
|
|
728
|
-
Object.defineProperty(exports, "snowflakeFetchCatalogIntegration", {
|
|
729
|
-
enumerable: true,
|
|
730
|
-
get: function() {
|
|
731
|
-
return snowflakeFetchCatalogIntegration;
|
|
732
|
-
}
|
|
733
|
-
});
|
|
734
|
-
Object.defineProperty(exports, "snowflakeGetActiveScheduledMaintenances", {
|
|
735
|
-
enumerable: true,
|
|
736
|
-
get: function() {
|
|
737
|
-
return snowflakeGetActiveScheduledMaintenances;
|
|
738
|
-
}
|
|
739
|
-
});
|
|
740
|
-
Object.defineProperty(exports, "snowflakeGetAllScheduledMaintenances", {
|
|
741
|
-
enumerable: true,
|
|
742
|
-
get: function() {
|
|
743
|
-
return snowflakeGetAllScheduledMaintenances;
|
|
744
|
-
}
|
|
745
|
-
});
|
|
746
|
-
Object.defineProperty(exports, "snowflakeGetComponentStatus", {
|
|
747
|
-
enumerable: true,
|
|
748
|
-
get: function() {
|
|
749
|
-
return snowflakeGetComponentStatus;
|
|
750
|
-
}
|
|
751
|
-
});
|
|
752
|
-
Object.defineProperty(exports, "snowflakeGetStatusRollup", {
|
|
753
|
-
enumerable: true,
|
|
754
|
-
get: function() {
|
|
755
|
-
return snowflakeGetStatusRollup;
|
|
756
|
-
}
|
|
757
|
-
});
|
|
758
|
-
Object.defineProperty(exports, "snowflakeGetStatusSummary", {
|
|
759
|
-
enumerable: true,
|
|
760
|
-
get: function() {
|
|
761
|
-
return snowflakeGetStatusSummary;
|
|
762
|
-
}
|
|
763
|
-
});
|
|
764
|
-
Object.defineProperty(exports, "snowflakeGetUnresolvedIncidents", {
|
|
765
|
-
enumerable: true,
|
|
766
|
-
get: function() {
|
|
767
|
-
return snowflakeGetUnresolvedIncidents;
|
|
768
|
-
}
|
|
769
|
-
});
|
|
770
|
-
Object.defineProperty(exports, "snowflakeGetUpcomingScheduledMaintenances", {
|
|
771
|
-
enumerable: true,
|
|
772
|
-
get: function() {
|
|
773
|
-
return snowflakeGetUpcomingScheduledMaintenances;
|
|
774
|
-
}
|
|
775
|
-
});
|
|
776
|
-
Object.defineProperty(exports, "snowflakeShowDatabases", {
|
|
777
|
-
enumerable: true,
|
|
778
|
-
get: function() {
|
|
779
|
-
return snowflakeShowDatabases;
|
|
780
|
-
}
|
|
781
|
-
});
|
|
782
|
-
Object.defineProperty(exports, "snowflakeShowSchemas", {
|
|
783
|
-
enumerable: true,
|
|
784
|
-
get: function() {
|
|
785
|
-
return snowflakeShowSchemas;
|
|
786
|
-
}
|
|
787
|
-
});
|
|
788
|
-
Object.defineProperty(exports, "snowflakeShowTables", {
|
|
789
|
-
enumerable: true,
|
|
790
|
-
get: function() {
|
|
791
|
-
return snowflakeShowTables;
|
|
792
|
-
}
|
|
793
|
-
});
|
|
794
|
-
Object.defineProperty(exports, "snowflakeValidateCredential", {
|
|
795
|
-
enumerable: true,
|
|
796
|
-
get: function() {
|
|
797
|
-
return snowflakeValidateCredential;
|
|
798
|
-
}
|
|
799
|
-
});
|
|
800
|
-
|
|
801
|
-
//# sourceMappingURL=actions-BGkaZb6a.cjs.map
|