Skip to content

Commit 8794e12

Browse files
waleedlatif1claude
andcommitted
fix: restore cloudwatch/cloudformation files from staging
These files were accidentally regressed during rebase conflict resolution, reverting changes from #4027. Restoring to staging versions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent fe8d611 commit 8794e12

5 files changed

Lines changed: 130 additions & 32 deletions

File tree

apps/docs/content/docs/en/tools/cloudwatch.mdx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,20 @@ import { BlockInfoCard } from "@/components/ui/block-info-card"
1111
/>
1212

1313
{/* MANUAL-CONTENT-START:intro */}
14-
[Amazon CloudWatch](https://aws.amazon.com/cloudwatch/) is a monitoring and observability service that collects and tracks metrics, collects and monitors log files, and sets alarms for your AWS resources. CloudWatch provides a unified view of operational health across your AWS infrastructure and applications.
14+
[AWS CloudWatch](https://aws.amazon.com/cloudwatch/) is a monitoring and observability service that provides data and actionable insights for AWS resources, applications, and services. CloudWatch collects monitoring and operational data in the form of logs, metrics, and events, giving you a unified view of your AWS environment.
1515

1616
With the CloudWatch integration, you can:
1717

18-
- **Query Logs (Insights)**: Run powerful CloudWatch Log Insights queries across one or more log groups to search, analyze, and visualize your log data
19-
- **Describe Log Groups**: List available log groups in your account with metadata like stored bytes, retention settings, and creation time
20-
- **Get Log Events**: Retrieve individual log events from a specific log stream with optional time range filtering
21-
- **Describe Log Streams**: List log streams within a log group, sorted by last event time or filtered by name prefix
22-
- **List Metrics**: Browse available CloudWatch metrics, filtered by namespace or metric name, with support for recently active metrics
23-
- **Get Metric Statistics**: Retrieve statistical data (average, sum, min, max, sample count) for a metric over a specified time range and period
24-
- **Publish Metric**: Publish custom metric data points to CloudWatch with optional units and dimensions
25-
- **Describe Alarms**: List and filter CloudWatch alarms by name prefix, state (OK, ALARM, INSUFFICIENT_DATA), or type (Metric, Composite)
18+
- **Query Logs (Insights)**: Run CloudWatch Log Insights queries against one or more log groups to analyze log data with a powerful query language
19+
- **Describe Log Groups**: List available CloudWatch log groups in your account, optionally filtered by name prefix
20+
- **Get Log Events**: Retrieve log events from a specific log stream within a log group
21+
- **Describe Log Streams**: List log streams within a log group, ordered by last event time or filtered by name prefix
22+
- **List Metrics**: Browse available CloudWatch metrics, optionally filtered by namespace, metric name, or recent activity
23+
- **Get Metric Statistics**: Retrieve statistical data for a metric over a specified time range with configurable granularity
24+
- **Publish Metric**: Publish custom metric data points to CloudWatch for your own application monitoring
25+
- **Describe Alarms**: List and filter CloudWatch alarms by name prefix, state, or alarm type
2626

27-
In Sim, the CloudWatch integration enables your agents to monitor application health, analyze logs for errors, track custom business metrics, and respond to alarm states as part of automated observability and incident response workflows. This pairs well with CloudFormation for infrastructure monitoring and SNS for alerting.
27+
In Sim, the CloudWatch integration enables your agents to monitor AWS infrastructure, analyze application logs, track custom metrics, and respond to alarm states as part of automated DevOps and SRE workflows. This is especially powerful when combined with other AWS integrations like CloudFormation and SNS for end-to-end infrastructure management.
2828
{/* MANUAL-CONTENT-END */}
2929

3030

apps/sim/blocks/blocks/cloudwatch.ts

Lines changed: 48 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@ export const CloudWatchBlock: BlockConfig<
2727
description: 'Query and monitor AWS CloudWatch logs, metrics, and alarms',
2828
longDescription:
2929
'Integrate AWS CloudWatch into workflows. Run Log Insights queries, list log groups, retrieve log events, list and get metrics, and monitor alarms. Requires AWS access key and secret access key.',
30-
docsLink: 'https://docs.sim.ai/tools/cloudwatch',
3130
category: 'tools',
3231
integrationType: IntegrationType.Analytics,
32+
docsLink: 'https://docs.sim.ai/tools/cloudwatch',
3333
tags: ['cloud', 'monitoring'],
3434
bgColor: 'linear-gradient(45deg, #B0084D 0%, #FF4F8B 100%)',
3535
icon: CloudWatchIcon,
@@ -73,7 +73,6 @@ export const CloudWatchBlock: BlockConfig<
7373
password: true,
7474
required: true,
7575
},
76-
// Query Logs fields
7776
{
7877
id: 'logGroupSelector',
7978
title: 'Log Group',
@@ -130,9 +129,10 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
130129
required: { field: 'operation', value: ['query_logs', 'get_metric_statistics'] },
131130
wandConfig: {
132131
enabled: true,
133-
prompt:
134-
'Generate a Unix epoch timestamp in seconds for the described start time. Return ONLY the numeric timestamp - no explanations, no extra text.',
135-
placeholder: 'Describe the start time (e.g., "1 hour ago", "start of today")...',
132+
prompt: `Generate a Unix epoch timestamp (in seconds) based on the user's description of a point in time.
133+
134+
Return ONLY the numeric timestamp - no explanations, no quotes, no extra text.`,
135+
placeholder: 'Describe the start time (e.g., "1 hour ago", "beginning of today")...',
136136
generationType: 'timestamp',
137137
},
138138
},
@@ -148,21 +148,20 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
148148
required: { field: 'operation', value: ['query_logs', 'get_metric_statistics'] },
149149
wandConfig: {
150150
enabled: true,
151-
prompt:
152-
'Generate a Unix epoch timestamp in seconds for the described end time. Return ONLY the numeric timestamp - no explanations, no extra text.',
153-
placeholder: 'Describe the end time (e.g., "now", "end of today")...',
151+
prompt: `Generate a Unix epoch timestamp (in seconds) based on the user's description of a point in time.
152+
153+
Return ONLY the numeric timestamp - no explanations, no quotes, no extra text.`,
154+
placeholder: 'Describe the end time (e.g., "now", "end of yesterday")...',
154155
generationType: 'timestamp',
155156
},
156157
},
157-
// Describe Log Groups fields
158158
{
159159
id: 'prefix',
160160
title: 'Log Group Name Prefix',
161161
type: 'short-input',
162162
placeholder: '/aws/lambda/',
163163
condition: { field: 'operation', value: 'describe_log_groups' },
164164
},
165-
// Get Log Events / Describe Log Streams — shared log group selector
166165
{
167166
id: 'logGroupNameSelector',
168167
title: 'Log Group',
@@ -185,15 +184,13 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
185184
required: { field: 'operation', value: ['get_log_events', 'describe_log_streams'] },
186185
mode: 'advanced',
187186
},
188-
// Describe Log Streams — stream prefix filter
189187
{
190188
id: 'streamPrefix',
191189
title: 'Stream Name Prefix',
192190
type: 'short-input',
193191
placeholder: '2024/03/31/',
194192
condition: { field: 'operation', value: 'describe_log_streams' },
195193
},
196-
// Get Log Events — log stream selector (cascading: depends on log group)
197194
{
198195
id: 'logStreamNameSelector',
199196
title: 'Log Stream',
@@ -216,7 +213,6 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
216213
required: { field: 'operation', value: 'get_log_events' },
217214
mode: 'advanced',
218215
},
219-
// List Metrics fields
220216
{
221217
id: 'metricNamespace',
222218
title: 'Namespace',
@@ -252,7 +248,6 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
252248
condition: { field: 'operation', value: 'list_metrics' },
253249
mode: 'advanced',
254250
},
255-
// Publish Metric fields
256251
{
257252
id: 'metricValue',
258253
title: 'Value',
@@ -276,8 +271,22 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
276271
{ label: 'Kilobytes', id: 'Kilobytes' },
277272
{ label: 'Megabytes', id: 'Megabytes' },
278273
{ label: 'Gigabytes', id: 'Gigabytes' },
274+
{ label: 'Terabytes', id: 'Terabytes' },
279275
{ label: 'Bits', id: 'Bits' },
276+
{ label: 'Kilobits', id: 'Kilobits' },
277+
{ label: 'Megabits', id: 'Megabits' },
278+
{ label: 'Gigabits', id: 'Gigabits' },
279+
{ label: 'Terabits', id: 'Terabits' },
280280
{ label: 'Bytes/Second', id: 'Bytes/Second' },
281+
{ label: 'Kilobytes/Second', id: 'Kilobytes/Second' },
282+
{ label: 'Megabytes/Second', id: 'Megabytes/Second' },
283+
{ label: 'Gigabytes/Second', id: 'Gigabytes/Second' },
284+
{ label: 'Terabytes/Second', id: 'Terabytes/Second' },
285+
{ label: 'Bits/Second', id: 'Bits/Second' },
286+
{ label: 'Kilobits/Second', id: 'Kilobits/Second' },
287+
{ label: 'Megabits/Second', id: 'Megabits/Second' },
288+
{ label: 'Gigabits/Second', id: 'Gigabits/Second' },
289+
{ label: 'Terabits/Second', id: 'Terabits/Second' },
281290
{ label: 'Count/Second', id: 'Count/Second' },
282291
],
283292
value: () => 'None',
@@ -290,7 +299,6 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
290299
columns: ['name', 'value'],
291300
condition: { field: 'operation', value: 'put_metric_data' },
292301
},
293-
// Get Metric Statistics fields
294302
{
295303
id: 'metricPeriod',
296304
title: 'Period (seconds)',
@@ -320,7 +328,6 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
320328
columns: ['name', 'value'],
321329
condition: { field: 'operation', value: 'get_metric_statistics' },
322330
},
323-
// Describe Alarms fields
324331
{
325332
id: 'alarmNamePrefix',
326333
title: 'Alarm Name Prefix',
@@ -353,7 +360,6 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
353360
value: () => '',
354361
condition: { field: 'operation', value: 'describe_alarms' },
355362
},
356-
// Shared limit field
357363
{
358364
id: 'limit',
359365
title: 'Limit',
@@ -564,14 +570,18 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
564570
if (rest.metricValue === undefined || rest.metricValue === '') {
565571
throw new Error('Metric value is required')
566572
}
573+
const numericValue = Number(rest.metricValue)
574+
if (!Number.isFinite(numericValue)) {
575+
throw new Error('Metric value must be a finite number')
576+
}
567577

568578
return {
569579
awsRegion,
570580
awsAccessKeyId,
571581
awsSecretAccessKey,
572582
namespace: rest.metricNamespace,
573583
metricName: rest.metricName,
574-
value: Number(rest.metricValue),
584+
value: numericValue,
575585
...(rest.metricUnit && rest.metricUnit !== 'None' && { unit: rest.metricUnit }),
576586
...(rest.publishDimensions && {
577587
dimensions: (() => {
@@ -686,6 +696,26 @@ Return ONLY the query — no explanations, no markdown code blocks.`,
686696
type: 'array',
687697
description: 'CloudWatch alarms with state and configuration',
688698
},
699+
success: {
700+
type: 'boolean',
701+
description: 'Whether the published metric was successful',
702+
},
703+
namespace: {
704+
type: 'string',
705+
description: 'Metric namespace',
706+
},
707+
metricName: {
708+
type: 'string',
709+
description: 'Metric name',
710+
},
711+
value: {
712+
type: 'number',
713+
description: 'Published metric value',
714+
},
715+
unit: {
716+
type: 'string',
717+
description: 'Metric unit',
718+
},
689719
timestamp: {
690720
type: 'string',
691721
description: 'Timestamp when metric was published',

apps/sim/tools/cloudformation/index.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@ import { getTemplateTool } from '@/tools/cloudformation/get_template'
88
import { listStackResourcesTool } from '@/tools/cloudformation/list_stack_resources'
99
import { validateTemplateTool } from '@/tools/cloudformation/validate_template'
1010

11-
export * from './types'
12-
1311
export const cloudformationDescribeStacksTool = describeStacksTool
1412
export const cloudformationListStackResourcesTool = listStackResourcesTool
1513
export const cloudformationDetectStackDriftTool = detectStackDriftTool

apps/sim/tools/cloudwatch/index.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,3 @@ export const cloudwatchGetMetricStatisticsTool = getMetricStatisticsTool
1717
export const cloudwatchListMetricsTool = listMetricsTool
1818
export const cloudwatchPutMetricDataTool = putMetricDataTool
1919
export const cloudwatchQueryLogsTool = queryLogsTool
20-
21-
export * from './types'

apps/sim/tools/registry.ts

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,16 @@ import {
163163
ashbySearchCandidatesTool,
164164
ashbyUpdateCandidateTool,
165165
} from '@/tools/ashby'
166+
import {
167+
athenaCreateNamedQueryTool,
168+
athenaGetNamedQueryTool,
169+
athenaGetQueryExecutionTool,
170+
athenaGetQueryResultsTool,
171+
athenaListNamedQueriesTool,
172+
athenaListQueryExecutionsTool,
173+
athenaStartQueryTool,
174+
athenaStopQueryTool,
175+
} from '@/tools/athena'
166176
import {
167177
attioAssertRecordTool,
168178
attioCreateCommentTool,
@@ -356,6 +366,11 @@ import {
356366
confluenceUpdateTool,
357367
confluenceUploadAttachmentTool,
358368
} from '@/tools/confluence'
369+
import {
370+
crowdstrikeGetSensorAggregatesTool,
371+
crowdstrikeGetSensorDetailsTool,
372+
crowdstrikeQuerySensorsTool,
373+
} from '@/tools/crowdstrike'
359374
import {
360375
cursorAddFollowupTool,
361376
cursorAddFollowupV2Tool,
@@ -376,6 +391,22 @@ import {
376391
cursorStopAgentTool,
377392
cursorStopAgentV2Tool,
378393
} from '@/tools/cursor'
394+
import {
395+
dagsterDeleteRunTool,
396+
dagsterGetRunLogsTool,
397+
dagsterGetRunTool,
398+
dagsterLaunchRunTool,
399+
dagsterListJobsTool,
400+
dagsterListRunsTool,
401+
dagsterListSchedulesTool,
402+
dagsterListSensorsTool,
403+
dagsterReexecuteRunTool,
404+
dagsterStartScheduleTool,
405+
dagsterStartSensorTool,
406+
dagsterStopScheduleTool,
407+
dagsterStopSensorTool,
408+
dagsterTerminateRunTool,
409+
} from '@/tools/dagster'
379410
import {
380411
databricksCancelRunTool,
381412
databricksExecuteSqlTool,
@@ -1280,6 +1311,9 @@ import {
12801311
jsmGetApprovalsTool,
12811312
jsmGetCommentsTool,
12821313
jsmGetCustomersTool,
1314+
jsmGetFormStructureTool,
1315+
jsmGetFormTemplatesTool,
1316+
jsmGetIssueFormsTool,
12831317
jsmGetOrganizationsTool,
12841318
jsmGetParticipantsTool,
12851319
jsmGetQueuesTool,
@@ -2212,6 +2246,12 @@ import {
22122246
similarwebVisitDurationTool,
22132247
similarwebWebsiteOverviewTool,
22142248
} from '@/tools/similarweb'
2249+
import {
2250+
sixtyfourEnrichCompanyTool,
2251+
sixtyfourEnrichLeadTool,
2252+
sixtyfourFindEmailTool,
2253+
sixtyfourFindPhoneTool,
2254+
} from '@/tools/sixtyfour'
22152255
import {
22162256
slackAddReactionTool,
22172257
slackCanvasTool,
@@ -2835,6 +2875,14 @@ export const tools: Record<string, ToolConfig> = {
28352875
ashby_remove_candidate_tag: ashbyRemoveCandidateTagTool,
28362876
ashby_search_candidates: ashbySearchCandidatesTool,
28372877
ashby_update_candidate: ashbyUpdateCandidateTool,
2878+
athena_create_named_query: athenaCreateNamedQueryTool,
2879+
athena_get_named_query: athenaGetNamedQueryTool,
2880+
athena_get_query_execution: athenaGetQueryExecutionTool,
2881+
athena_get_query_results: athenaGetQueryResultsTool,
2882+
athena_list_named_queries: athenaListNamedQueriesTool,
2883+
athena_list_query_executions: athenaListQueryExecutionsTool,
2884+
athena_start_query: athenaStartQueryTool,
2885+
athena_stop_query: athenaStopQueryTool,
28382886
brandfetch_get_brand: brandfetchGetBrandTool,
28392887
brandfetch_search: brandfetchSearchTool,
28402888
box_copy_file: boxCopyFileTool,
@@ -3079,6 +3127,9 @@ export const tools: Record<string, ToolConfig> = {
30793127
jsm_add_participants: jsmAddParticipantsTool,
30803128
jsm_get_approvals: jsmGetApprovalsTool,
30813129
jsm_answer_approval: jsmAnswerApprovalTool,
3130+
jsm_get_form_templates: jsmGetFormTemplatesTool,
3131+
jsm_get_form_structure: jsmGetFormStructureTool,
3132+
jsm_get_issue_forms: jsmGetIssueFormsTool,
30823133
kalshi_get_markets: kalshiGetMarketsTool,
30833134
kalshi_get_markets_v2: kalshiGetMarketsV2Tool,
30843135
kalshi_get_market: kalshiGetMarketTool,
@@ -3172,6 +3223,10 @@ export const tools: Record<string, ToolConfig> = {
31723223
servicenow_read_record: servicenowReadRecordTool,
31733224
servicenow_update_record: servicenowUpdateRecordTool,
31743225
servicenow_delete_record: servicenowDeleteRecordTool,
3226+
sixtyfour_find_phone: sixtyfourFindPhoneTool,
3227+
sixtyfour_find_email: sixtyfourFindEmailTool,
3228+
sixtyfour_enrich_lead: sixtyfourEnrichLeadTool,
3229+
sixtyfour_enrich_company: sixtyfourEnrichCompanyTool,
31753230
tavily_search: tavilySearchTool,
31763231
tavily_extract: tavilyExtractTool,
31773232
tavily_crawl: tavilyCrawlTool,
@@ -3441,6 +3496,9 @@ export const tools: Record<string, ToolConfig> = {
34413496
cloudwatch_list_metrics: cloudwatchListMetricsTool,
34423497
cloudwatch_put_metric_data: cloudwatchPutMetricDataTool,
34433498
cloudwatch_query_logs: cloudwatchQueryLogsTool,
3499+
crowdstrike_get_sensor_aggregates: crowdstrikeGetSensorAggregatesTool,
3500+
crowdstrike_get_sensor_details: crowdstrikeGetSensorDetailsTool,
3501+
crowdstrike_query_sensors: crowdstrikeQuerySensorsTool,
34443502
dynamodb_get: dynamodbGetTool,
34453503
dynamodb_put: dynamodbPutTool,
34463504
dynamodb_query: dynamodbQueryTool,
@@ -3462,6 +3520,20 @@ export const tools: Record<string, ToolConfig> = {
34623520
devin_get_session: devinGetSessionTool,
34633521
devin_list_sessions: devinListSessionsTool,
34643522
devin_send_message: devinSendMessageTool,
3523+
dagster_delete_run: dagsterDeleteRunTool,
3524+
dagster_get_run: dagsterGetRunTool,
3525+
dagster_get_run_logs: dagsterGetRunLogsTool,
3526+
dagster_launch_run: dagsterLaunchRunTool,
3527+
dagster_list_jobs: dagsterListJobsTool,
3528+
dagster_list_runs: dagsterListRunsTool,
3529+
dagster_list_schedules: dagsterListSchedulesTool,
3530+
dagster_list_sensors: dagsterListSensorsTool,
3531+
dagster_reexecute_run: dagsterReexecuteRunTool,
3532+
dagster_start_schedule: dagsterStartScheduleTool,
3533+
dagster_start_sensor: dagsterStartSensorTool,
3534+
dagster_stop_schedule: dagsterStopScheduleTool,
3535+
dagster_stop_sensor: dagsterStopSensorTool,
3536+
dagster_terminate_run: dagsterTerminateRunTool,
34653537
databricks_cancel_run: databricksCancelRunTool,
34663538
databricks_execute_sql: databricksExecuteSqlTool,
34673539
databricks_get_run: databricksGetRunTool,

0 commit comments

Comments
 (0)