AWS Athena integration
Amazon Athena interactive query service API. Run SQL queries against data in S3, manage workgroups, named queries, and query executions for serverless data analytics.
Say what should happen.
The workflow builds itself.
Common AWS Athena use cases
- audit resource tags
- update a stored SQL query
- remove cost allocation tags
- inspect a prepared statement's SQL
- tag workgroups for cost allocation
- analyze query execution performance
- clean up unused prepared statements
- deregister an external data catalog
- register a Lambda-backed data source
- create reusable parameterized queries
What you can do with AWS Athena
Each of these is one operation on one endpoint, available both as a workflow step and as a tool an AI agent can call on its own. Nothing bundles several operations into one action, so what a run did stays readable afterwards.
Each badge shows the default agent permission of an endpoint (allowed: an agent calls it without asking; ask first: you are asked before an agent calls it, when the agent or chat asks permission for sensitive actions; never: no agent may call it), which every user can change endpoint by endpoint in their credential settings.
Most endpoints run on the free plan. A few, mainly the ones that publish on your behalf, need a paid plan.
Prepared statement, 6 operations
batch_get_prepared_statementBatch get prepared statementPOSTAgents: ask firstRetrieves details for up to 256 prepared statements in a single request. Returns full PreparedStatement objects and any unprocessed names.create_prepared_statementCreate prepared statementPOSTAgents: ask firstCreates a prepared statement with parameterized SQL for reuse. Parameters are filled at execution time via ExecutionParameters in StartQueryExecution.delete_prepared_statementDelete prepared statementPOSTAgents: ask firstDeletes a prepared statement from the specified workgroup.get_prepared_statementGet prepared statementPOSTAgents: ask firstRetrieves a prepared statement by name from the specified workgroup, including its SQL and description.list_prepared_statementsList prepared statementsPOSTAgents: ask firstLists all prepared statements in the specified workgroup with their names and last modified times.update_prepared_statementUpdate prepared statementPOSTAgents: ask firstUpdates the SQL query or description of an existing prepared statement in a workgroup.
Data catalog, 3 operations
create_data_catalogCreate data catalogPOSTAgents: ask firstCreates and registers a new data catalog (LAMBDA, GLUE, HIVE, or FEDERATED type) for use with Athena queries.delete_data_catalogDelete data catalogPOSTAgents: ask firstDeletes a data catalog by name. The built-in AwsDataCatalog cannot be deleted.update_data_catalogUpdate data catalogPOSTAgents: ask firstUpdates the configuration, description, or Lambda parameters of an existing data catalog.
Resource tag, 3 operations
list_tags_for_resourceList tags for resourcePOSTAgents: ask firstLists all tags associated with an Athena workgroup or data catalog, identified by its ARN.tag_resourceTag resourcePOSTAgents: ask firstAdds tags to an Athena workgroup or data catalog resource identified by its ARN.untag_resourceUntag resourcePOSTAgents: ask firstRemoves specified tags from an Athena workgroup or data catalog resource.
Batch get named query, 1 operation
batch_get_named_queryBatch get named queryPOSTAgents: ask firstReturns the details of a single named query or a list of up to 50 queries, which you provide as an array of query ID strings.
Batch get query execution, 1 operation
batch_get_query_executionBatch get query executionPOSTAgents: ask firstReturns the details of a single query execution or a list of up to 50 query executions.
Create named query, 1 operation
create_named_queryCreate named queryPOSTAgents: ask firstCreates a named query in the specified workgroup. Named queries allow you to store and run SQL queries that you use regularly.
Create work group, 1 operation
create_work_groupCreate work groupPOSTAgents: ask firstCreates a workgroup with the specified name. A workgroup lets you manage users, workloads, and query settings.
Database, 1 operation
list_databasesList databasesPOSTAgents: ask firstLists the databases in the specified data catalog.
Delete named query, 1 operation
delete_named_queryDelete named queryPOSTAgents: ask firstDeletes the named query if you have access to the workgroup in which the query was saved.
Delete work group, 1 operation
delete_work_groupDelete work groupPOSTAgents: ask firstDeletes the workgroup with the specified name. The primary workgroup cannot be deleted.
Get data catalog, 1 operation
get_data_catalogGet data catalogPOSTAgents: ask firstReturns the specified data catalog.
Get database, 1 operation
get_databaseGet databasePOSTAgents: ask firstReturns a database object for the specified database and data catalog.
Get named query, 1 operation
get_named_queryGet named queryPOSTAgents: ask firstReturns information about a single named query or a list of up to 50 queries that you provide.
Get query execution, 1 operation
get_query_executionGet query executionPOSTAgents: ask firstReturns information about a single execution of a query if you have access to the workgroup in which the query ran.
Get query result, 1 operation
get_query_resultsGet query resultsPOSTAgents: ask firstStreams the results of the specified query execution stored as a paginated list of result rows in Amazon S3.
Get table metadata, 1 operation
get_table_metadataGet table metadataPOSTAgents: ask firstReturns table metadata for the specified catalog, database, and table.
Get work group, 1 operation
get_work_groupGet work groupPOSTAgents: ask firstReturns information about the workgroup with the specified name.
List data catalog, 1 operation
list_data_catalogsList data catalogsPOSTAgents: ask firstLists the data catalogs in the current Amazon Web Services account.
List engine version, 1 operation
list_engine_versionsList engine versionsPOSTAgents: ask firstReturns a list of engine versions that are available to choose from, including the Auto option.
List named query, 1 operation
list_named_queriesList named queriesPOSTAgents: ask firstProvides a list of available query IDs only for queries saved in the specified workgroup.
List query execution, 1 operation
list_query_executionsList query executionsPOSTAgents: ask firstProvides a list of available query execution IDs for the queries in the specified workgroup.
List table metadata, 1 operation
list_table_metadataList table metadataPOSTAgents: ask firstLists the metadata for the tables in the specified database and data catalog.
List work group, 1 operation
list_work_groupsList work groupsPOSTAgents: ask firstLists available workgroups for the account.
Named query, 1 operation
update_named_queryUpdate named queryPOSTAgents: ask firstUpdates a named query in the specified workgroup. The NamedQueryId, Name, and QueryString are all required.
Query runtime statistics, 1 operation
get_query_runtime_statisticsGet query runtime statisticsPOSTAgents: ask firstReturns detailed runtime statistics for a query execution including timeline, rows processed, and output stage breakdown.
Start query execution, 1 operation
start_query_executionStart query executionPOSTAgents: ask firstRuns the SQL query statements contained in the QueryString. Execution parameters may be set for the query.
Stop query execution, 1 operation
stop_query_executionStop query executionPOSTAgents: ask firstStops a query execution. Athena automatically retains query results for 45 days.
Update work group, 1 operation
update_work_groupUpdate work groupPOSTAgents: ask firstUpdates the workgroup with the specified name. The workgroup's Name cannot be changed.
Use AWS Athena from Claude Code, Cursor or Codex
Connect AWS Athena in LiveContext, create an API key in Settings, then add the LiveContext MCP server to your client. Its AWS Athena operations become tools the client can call, next to every other integration you connected.
claude mcp add --transport http livecontext https://livecontext.ai/mcp --header "X-API-Key: YOUR_API_KEY"[mcp_servers.livecontext]
url = "https://livecontext.ai/mcp"
[mcp_servers.livecontext.http_headers]
"X-API-Key" = "YOUR_API_KEY"{
"mcpServers": {
"livecontext": {
"type": "http",
"url": "https://livecontext.ai/mcp",
"headers": {
"X-API-Key": "YOUR_API_KEY"
}
}
}
}How to connect AWS Athena
- Create your workspace
Sign up free. Nothing to install.
- Connect AWS Athena once
Add your AWS Athena connection in Settings. Every tool from this integration reuses it, and secrets are encrypted at rest and visible only to you.
- Describe the job in chat
The workflow builds itself in front of you and picks the endpoints it needs. Drag the steps yourself on the canvas whenever you would rather be explicit.
AWS Athena integration FAQ
What can you do with the AWS Athena integration?
LiveContext exposes 37 operations on AWS Athena, covering prepared statement, data catalog, resource tag and batch get named query. Common uses include audit resource tags, update a stored SQL query and remove cost allocation tags.
