# Directory Structure
```
├── .gitignore
├── package-lock.json
├── package.json
├── README.md
├── setup.sh
├── src
│ ├── aws-cli.ts
│ ├── aws-services.ts
│ ├── index.ts
│ ├── test.ts
│ └── types.ts
└── tsconfig.json
```
# Files
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
```
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | lerna-debug.log*
8 | .pnpm-debug.log*
9 |
10 | # Diagnostic reports (https://nodejs.org/api/report.html)
11 | report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
12 |
13 | # Runtime data
14 | pids
15 | *.pid
16 | *.seed
17 | *.pid.lock
18 |
19 | # Directory for instrumented libs generated by jscoverage/JSCover
20 | lib-cov
21 |
22 | # Coverage directory used by tools like istanbul
23 | coverage
24 | *.lcov
25 |
26 | # nyc test coverage
27 | .nyc_output
28 |
29 | # Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
30 | .grunt
31 |
32 | # Bower dependency directory (https://bower.io/)
33 | bower_components
34 |
35 | # node-waf configuration
36 | .lock-wscript
37 |
38 | # Compiled binary addons (https://nodejs.org/api/addons.html)
39 | build/Release
40 |
41 | # Dependency directories
42 | node_modules/
43 | jspm_packages/
44 |
45 | # Snowpack dependency directory (https://snowpack.dev/)
46 | web_modules/
47 |
48 | # TypeScript cache
49 | *.tsbuildinfo
50 |
51 | # Optional npm cache directory
52 | .npm
53 |
54 | # Optional eslint cache
55 | .eslintcache
56 |
57 | # Optional stylelint cache
58 | .stylelintcache
59 |
60 | # Microbundle cache
61 | .rpt2_cache/
62 | .rts2_cache_cjs/
63 | .rts2_cache_es/
64 | .rts2_cache_umd/
65 |
66 | # Optional REPL history
67 | .node_repl_history
68 |
69 | # Output of 'npm pack'
70 | *.tgz
71 |
72 | # Yarn Integrity file
73 | .yarn-integrity
74 |
75 | # dotenv environment variable files
76 | .env
77 | .env.development.local
78 | .env.test.local
79 | .env.production.local
80 | .env.local
81 |
82 | # parcel-bundler cache (https://parceljs.org/)
83 | .cache
84 | .parcel-cache
85 |
86 | # Next.js build output
87 | .next
88 | out
89 |
90 | # Nuxt.js build / generate output
91 | .nuxt
92 | dist
93 |
94 | # Gatsby files
95 | .cache/
96 | # Comment in the public line in if your project uses Gatsby and not Next.js
97 | # https://nextjs.org/blog/next-9-1#public-directory-support
98 | # public
99 |
100 | # vuepress build output
101 | .vuepress/dist
102 |
103 | # vuepress v2.x temp and cache directory
104 | .temp
105 | .cache
106 |
107 | # vitepress build output
108 | **/.vitepress/dist
109 |
110 | # vitepress cache directory
111 | **/.vitepress/cache
112 |
113 | # Docusaurus cache and generated files
114 | .docusaurus
115 |
116 | # Serverless directories
117 | .serverless/
118 |
119 | # FuseBox cache
120 | .fusebox/
121 |
122 | # DynamoDB Local files
123 | .dynamodb/
124 |
125 | # TernJS port file
126 | .tern-port
127 |
128 | # Stores VSCode versions used for testing VSCode extensions
129 | .vscode-test
130 |
131 | # yarn v2
132 | .yarn/cache
133 | .yarn/unplugged
134 | .yarn/build-state.yml
135 | .yarn/install-state.gz
136 | .pnp.*
137 |
```
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
```markdown
1 | # AWS CLI MCP Server
2 |
3 | An MCP (Model Context Protocol) server that lets you generate and execute AWS CLI commands directly from Claude.
4 |
5 | ## Features
6 |
7 | - Execute AWS CLI commands through the MCP protocol
8 | - Get detailed information about AWS services
9 | - List available AWS services
10 | - Full access to AWS CLI capabilities
11 |
12 | ## Tools
13 |
14 | - **execute-aws-command**: Execute AWS CLI commands
15 | - Parameters:
16 | - `command`: AWS service (e.g., s3, ec2, lambda)
17 | - `subcommand` (optional): Command to execute (e.g., ls, describe-instances)
18 | - `options` (optional): Command options as key-value pairs
19 |
20 | - **get-service-details**: Get details about a specific AWS service
21 | - Parameters:
22 | - `service`: AWS service name (e.g., s3, ec2, lambda)
23 |
24 | ## Resources
25 |
26 | - **aws-services://list**: List available AWS services
27 |
28 | ## Setup and Installation
29 |
30 | ### Prerequisites
31 |
32 | - Node.js (v20 or later recommended)
33 | - npm or yarn
34 | - AWS CLI installed and configured with credentials
35 | - TypeScript
36 |
37 | ### Local Installation
38 |
39 | 1. Clone this repository:
40 | ```bash
41 | git clone https://github.com/IcyKallen/aws-cli-mcp-server
42 | cd aws-cli-mcp-server
43 | ```
44 |
45 | 2. Install dependencies:
46 | ```bash
47 | npm install
48 | ```
49 |
50 | 3. Build the project:
51 | ```bash
52 | npm run build
53 | ```
54 |
55 | 4. Ensure AWS CLI is configured:
56 | ```bash
57 | aws configure
58 | ```
59 |
60 | 5. Start the MCP server:
61 | ```bash
62 | npm start
63 | ```
64 |
65 | ### Integration with Claude Desktop
66 |
67 | Add this to your `claude_desktop_config.json`:
68 |
69 | After building the project, you can use:
70 |
71 | ```json
72 | {
73 | "mcpServers": {
74 | "aws-cli": {
75 | "command": "node",
76 | "args": [
77 | "/path/to/aws-cli-mcp-server/dist/index.js"
78 | ]
79 | }
80 | }
81 | }
82 | ```
83 |
84 | ## Example Usage in Claude
85 |
86 | ### List S3 Buckets
87 | ```
88 | I need to list my S3 buckets.
89 | ```
90 |
91 | ### Create an S3 Bucket
92 | ```
93 | Create a new S3 bucket named "my-test-bucket" in the us-west-2 region.
94 | ```
95 |
96 | ### Get EC2 Service Details
97 | ```
98 | What EC2 commands are available?
99 | ```
100 |
101 | ## Security Notes
102 |
103 | - This server executes AWS CLI commands with the same permissions as your configured AWS credentials
104 | - Be careful about who can access this server
105 | - Consider implementing additional authentication for production use
106 |
107 | ## License
108 |
109 | MIT License
110 |
```
--------------------------------------------------------------------------------
/src/types.ts:
--------------------------------------------------------------------------------
```typescript
1 | /**
2 | * Service details interface
3 | */
4 | export interface ServiceDetails {
5 | description: string;
6 | commands: string[];
7 | }
8 |
9 | /**
10 | * AWS Command Options interface
11 | */
12 | export interface AwsCommandOptions {
13 | [key: string]: string;
14 | }
15 |
16 | /**
17 | * AWS Command Result interface
18 | */
19 | export interface AwsCommandResult {
20 | stdout: string;
21 | stderr?: string;
22 | }
23 |
24 | /**
25 | * AWS Command Error interface
26 | */
27 | export interface AwsCommandError extends Error {
28 | stderr?: string;
29 | code?: number;
30 | }
```
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
```json
1 | {
2 | "name": "aws-cli-mcp-server",
3 | "version": "1.0.0",
4 | "description": "An MCP server that can generate and execute AWS CLI commands",
5 | "main": "dist/index.js",
6 | "scripts": {
7 | "build": "tsc",
8 | "start": "node dist/index.js",
9 | "dev": "ts-node src/index.ts",
10 | "test": "echo \"Error: no test specified\" && exit 1",
11 | "test:aws": "ts-node src/test.ts"
12 | },
13 | "keywords": [],
14 | "author": "",
15 | "license": "ISC",
16 | "devDependencies": {
17 | "@types/node": "^22.13.12",
18 | "ts-node": "^10.9.2",
19 | "typescript": "^5.8.2"
20 | },
21 | "dependencies": {
22 | "@modelcontextprotocol/sdk": "^1.7.0",
23 | "zod": "^3.24.2"
24 | }
25 | }
```
--------------------------------------------------------------------------------
/setup.sh:
--------------------------------------------------------------------------------
```bash
1 | #!/bin/bash
2 |
3 | # Check if AWS CLI is installed
4 | echo "Checking if AWS CLI is installed..."
5 | if command -v aws &> /dev/null; then
6 | echo "AWS CLI is installed."
7 |
8 | # Check AWS CLI version
9 | aws_version=$(aws --version)
10 | echo "AWS CLI version: $aws_version"
11 |
12 | # Check if AWS credentials are configured
13 | echo "Checking AWS credentials..."
14 | aws sts get-caller-identity &> /dev/null
15 | if [ $? -eq 0 ]; then
16 | echo "AWS credentials are properly configured."
17 | identity=$(aws sts get-caller-identity)
18 | echo "You are authenticated as:"
19 | echo "$identity"
20 | else
21 | echo "AWS credentials are not configured or are invalid."
22 | echo "Please run 'aws configure' to set up your AWS credentials."
23 | exit 1
24 | fi
25 | else
26 | echo "AWS CLI is not installed."
27 | echo "Please install AWS CLI first. You can find installation instructions at:"
28 | echo "https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html"
29 | exit 1
30 | fi
31 |
32 | # Install dependencies
33 | echo "Installing dependencies..."
34 | npm install
35 |
36 | # Build the project
37 | echo "Building the project..."
38 | npm run build
39 |
40 | echo "Setup complete! You can now run the server with 'npm start' or 'npm run dev'"
```
--------------------------------------------------------------------------------
/src/test.ts:
--------------------------------------------------------------------------------
```typescript
1 | import { executeAwsCommand } from './aws-cli';
2 | import { listServices, getServiceDetails } from './aws-services';
3 |
4 | async function testAwsCli() {
5 | console.log('Testing AWS CLI functionality...');
6 |
7 | try {
8 | // Test AWS CLI version
9 | console.log('\nChecking AWS CLI version:');
10 | const versionResult = await executeAwsCommand('--version');
11 | console.log(versionResult);
12 |
13 | // Test listing services
14 | console.log('\nListing available AWS services:');
15 | const services = listServices();
16 | console.log(services.slice(0, 5).join('\n')); // Show first 5 services
17 | console.log(`... and ${services.length - 5} more services`);
18 |
19 | // Test getting service details
20 | console.log('\nGetting details for S3 service:');
21 | const s3Details = getServiceDetails('s3');
22 | if (s3Details) {
23 | console.log(`Description: ${s3Details.description}`);
24 | console.log('Commands:');
25 | console.log(s3Details.commands.join('\n'));
26 | } else {
27 | console.log('No details found for S3 service');
28 | }
29 |
30 | // Test executing a simple AWS CLI command (list S3 buckets)
31 | console.log('\nListing S3 buckets:');
32 | try {
33 | const s3Result = await executeAwsCommand('s3', 'ls');
34 | console.log(s3Result || 'No S3 buckets found');
35 | } catch (error) {
36 | console.error('Error listing S3 buckets:', error);
37 | }
38 |
39 | console.log('\nTests completed successfully!');
40 | } catch (error) {
41 | console.error('Test failed:', error);
42 | }
43 | }
44 |
45 | testAwsCli();
```
--------------------------------------------------------------------------------
/src/aws-cli.ts:
--------------------------------------------------------------------------------
```typescript
1 | import { exec } from 'child_process';
2 | import { promisify } from 'util';
3 | import { AwsCommandOptions, AwsCommandError } from './types';
4 |
5 | const execPromise = promisify(exec);
6 |
7 | /**
8 | * Execute an AWS CLI command with optional subcommand and options.
9 | *
10 | * @param command - The AWS service command (e.g., 's3', 'ec2', 'lambda')
11 | * @param subcommand - The subcommand to run (e.g., 'ls', 'describe-instances')
12 | * @param options - Key-value pairs of command options
13 | * @returns Promise with the command output
14 | */
15 | export async function executeAwsCommand(
16 | command: string,
17 | subcommand?: string,
18 | options: AwsCommandOptions = {}
19 | ): Promise<string> {
20 | // Build the AWS CLI command
21 | let awsCommand = `aws ${command}`;
22 |
23 | if (subcommand) {
24 | awsCommand += ` ${subcommand}`;
25 | }
26 |
27 | // Add options to the command
28 | for (const [key, value] of Object.entries(options)) {
29 | // Handle options with values vs flags
30 | if (value === '') {
31 | awsCommand += ` --${key}`;
32 | } else {
33 | // Properly quote option values
34 | awsCommand += ` --${key} "${value}"`;
35 | }
36 | }
37 |
38 | try {
39 | // Execute the AWS CLI command
40 | console.log(`Executing: ${awsCommand}`);
41 | const { stdout, stderr } = await execPromise(awsCommand);
42 |
43 | if (stderr) {
44 | console.warn(`AWS CLI warning: ${stderr}`);
45 | }
46 |
47 | return stdout.trim();
48 | } catch (error) {
49 | const execError = error as { stderr?: string; message: string };
50 | console.error(`AWS CLI error: ${execError.message}`);
51 |
52 | // Include stderr in the error message if available
53 | if (execError.stderr) {
54 | throw new Error(`AWS CLI error: ${execError.stderr.trim()}`);
55 | }
56 |
57 | throw error;
58 | }
59 | }
```
--------------------------------------------------------------------------------
/src/index.ts:
--------------------------------------------------------------------------------
```typescript
1 | import { McpServer, ResourceTemplate } from "@modelcontextprotocol/sdk/server/mcp.js";
2 | import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
3 | import { z } from "zod";
4 | import { executeAwsCommand } from "./aws-cli";
5 | import { listServices, getServiceDetails } from "./aws-services";
6 |
7 | // Create an MCP server
8 | const server = new McpServer({
9 | name: "AWS CLI MCP Server",
10 | version: "1.0.0"
11 | });
12 |
13 | // Add a tool to execute AWS CLI commands
14 | server.tool(
15 | "execute-aws-command",
16 | {
17 | command: z.string().describe("AWS service to use (e.g., s3, ec2, lambda)"),
18 | subcommand: z.string().optional().describe("Command to execute (e.g., ls, describe-instances)"),
19 | options: z.record(z.string(), z.string()).optional().describe("Command options as key-value pairs")
20 | },
21 | async ({ command, subcommand, options }) => {
22 | try {
23 | const result = await executeAwsCommand(command, subcommand, options || {});
24 | return {
25 | content: [{ type: "text", text: result }]
26 | };
27 | } catch (error) {
28 | const errorMessage = error instanceof Error ? error.message : String(error);
29 | return {
30 | content: [{ type: "text", text: `Error: ${errorMessage}` }]
31 | };
32 | }
33 | }
34 | );
35 |
36 | // Add a tool to get details about a specific AWS service
37 | server.tool(
38 | "get-service-details",
39 | {
40 | service: z.string().describe("AWS service name (e.g., s3, ec2, lambda)")
41 | },
42 | async ({ service }) => {
43 | const details = getServiceDetails(service);
44 |
45 | if (!details) {
46 | return {
47 | content: [{ type: "text", text: `No details available for service: ${service}` }]
48 | };
49 | }
50 |
51 | const responseText = `${details.description}\n\nCommon commands:\n${details.commands.join('\n')}`;
52 |
53 | return {
54 | content: [{ type: "text", text: responseText }]
55 | };
56 | }
57 | );
58 |
59 | // Add a resource to list available AWS services
60 | server.resource(
61 | "aws-services",
62 | new ResourceTemplate("aws-services://list", { list: undefined }),
63 | async (uri) => {
64 | const services = listServices();
65 | return {
66 | contents: [{
67 | uri: uri.href,
68 | text: services.join("\n")
69 | }]
70 | };
71 | }
72 | );
73 |
74 | // Check if AWS CLI is installed
75 | async function checkAwsCli(): Promise<boolean> {
76 | try {
77 | await executeAwsCommand('--version');
78 | return true;
79 | } catch (error) {
80 | return false;
81 | }
82 | }
83 |
84 | // Start receiving messages on stdin and sending messages on stdout
85 | async function startServer() {
86 | console.log("Starting AWS CLI MCP Server...");
87 |
88 | // Check if AWS CLI is installed
89 | const awsCliInstalled = await checkAwsCli();
90 | if (!awsCliInstalled) {
91 | console.error("AWS CLI is not installed or not in the PATH. Please install it to use this server.");
92 | process.exit(1);
93 | }
94 |
95 | const transport = new StdioServerTransport();
96 | await server.connect(transport);
97 | console.log("AWS CLI MCP Server is running.");
98 | }
99 |
100 | startServer().catch(error => {
101 | console.error("Failed to start server:", error);
102 | process.exit(1);
103 | });
```
--------------------------------------------------------------------------------
/src/aws-services.ts:
--------------------------------------------------------------------------------
```typescript
1 | import { ServiceDetails } from './types';
2 |
3 | /**
4 | * Returns a list of commonly used AWS services that can be accessed via the AWS CLI.
5 | * This is not an exhaustive list, but includes the most widely used services.
6 | *
7 | * @returns Array of AWS service names
8 | */
9 | export function listServices(): string[] {
10 | return [
11 | "s3 - Amazon Simple Storage Service",
12 | "ec2 - Amazon Elastic Compute Cloud",
13 | "lambda - AWS Lambda",
14 | "dynamodb - Amazon DynamoDB",
15 | "cloudformation - AWS CloudFormation",
16 | "iam - AWS Identity and Access Management",
17 | "rds - Amazon Relational Database Service",
18 | "sns - Amazon Simple Notification Service",
19 | "sqs - Amazon Simple Queue Service",
20 | "cloudwatch - Amazon CloudWatch",
21 | "ecs - Amazon Elastic Container Service",
22 | "eks - Amazon Elastic Kubernetes Service",
23 | "apigateway - Amazon API Gateway",
24 | "route53 - Amazon Route 53",
25 | "kms - AWS Key Management Service",
26 | "secretsmanager - AWS Secrets Manager",
27 | "ssm - AWS Systems Manager",
28 | "codepipeline - AWS CodePipeline",
29 | "codebuild - AWS CodeBuild",
30 | "codecommit - AWS CodeCommit"
31 | ];
32 | }
33 |
34 | /**
35 | * Gets details about a specific AWS service and its common commands.
36 | *
37 | * @param service The AWS service to get details for
38 | * @returns Service details and common commands
39 | */
40 | export function getServiceDetails(service: string): ServiceDetails | null {
41 | const services: Record<string, ServiceDetails> = {
42 | 's3': {
43 | description: 'Amazon Simple Storage Service (S3) is an object storage service that offers industry-leading scalability, data availability, security, and performance.',
44 | commands: [
45 | 'ls - List S3 buckets or objects within a bucket',
46 | 'cp - Copy files to/from S3',
47 | 'mb - Make a new bucket',
48 | 'rb - Remove a bucket',
49 | 'mv - Move files within S3 or between S3 and local',
50 | 'rm - Remove files from S3',
51 | 'sync - Sync directories to/from S3'
52 | ]
53 | },
54 | 'ec2': {
55 | description: 'Amazon Elastic Compute Cloud (EC2) provides scalable computing capacity in the AWS Cloud.',
56 | commands: [
57 | 'describe-instances - Get details about your instances',
58 | 'start-instances - Start an instance',
59 | 'stop-instances - Stop an instance',
60 | 'run-instances - Launch a new instance',
61 | 'terminate-instances - Terminate an instance',
62 | 'describe-images - List available AMIs',
63 | 'create-tags - Add or overwrite tags for resources'
64 | ]
65 | },
66 | 'lambda': {
67 | description: 'AWS Lambda lets you run code without provisioning or managing servers.',
68 | commands: [
69 | 'list-functions - List your Lambda functions',
70 | 'create-function - Create a new function',
71 | 'update-function-code - Update function code',
72 | 'invoke - Invoke a function',
73 | 'delete-function - Delete a function',
74 | 'get-function - Get function configuration and details',
75 | 'add-permission - Add permissions to the resource policy'
76 | ]
77 | }
78 | };
79 |
80 | return services[service] || null;
81 | }
```
--------------------------------------------------------------------------------
/tsconfig.json:
--------------------------------------------------------------------------------
```json
1 | {
2 | "compilerOptions": {
3 | /* Visit https://aka.ms/tsconfig to read more about this file */
4 | /* Projects */
5 | // "incremental": true, /* Save .tsbuildinfo files to allow for incremental compilation of projects. */
6 | // "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */
7 | // "tsBuildInfoFile": "./.tsbuildinfo", /* Specify the path to .tsbuildinfo incremental compilation file. */
8 | // "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects. */
9 | // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */
10 | // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */
11 | /* Language and Environment */
12 | "target": "es2016", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */
13 | // "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */
14 | // "jsx": "preserve", /* Specify what JSX code is generated. */
15 | // "libReplacement": true, /* Enable lib replacement. */
16 | // "experimentalDecorators": true, /* Enable experimental support for legacy experimental decorators. */
17 | // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */
18 | // "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h'. */
19 | // "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */
20 | // "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using 'jsx: react-jsx*'. */
21 | // "reactNamespace": "", /* Specify the object invoked for 'createElement'. This only applies when targeting 'react' JSX emit. */
22 | // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */
23 | // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */
24 | // "moduleDetection": "auto", /* Control what method is used to detect module-format JS files. */
25 | /* Modules */
26 | "module": "commonjs", /* Specify what module code is generated. */
27 | "rootDir": "./src",
28 | // "moduleResolution": "node10", /* Specify how TypeScript looks up a file from a given module specifier. */
29 | // "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */
30 | // "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */
31 | // "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */
32 | // "typeRoots": [], /* Specify multiple folders that act like './node_modules/@types'. */
33 | // "types": [], /* Specify type package names to be included without being referenced in a source file. */
34 | // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */
35 | // "moduleSuffixes": [], /* List of file name suffixes to search when resolving a module. */
36 | // "allowImportingTsExtensions": true, /* Allow imports to include TypeScript file extensions. Requires '--moduleResolution bundler' and either '--noEmit' or '--emitDeclarationOnly' to be set. */
37 | // "rewriteRelativeImportExtensions": true, /* Rewrite '.ts', '.tsx', '.mts', and '.cts' file extensions in relative import paths to their JavaScript equivalent in output files. */
38 | // "resolvePackageJsonExports": true, /* Use the package.json 'exports' field when resolving package imports. */
39 | // "resolvePackageJsonImports": true, /* Use the package.json 'imports' field when resolving imports. */
40 | // "customConditions": [], /* Conditions to set in addition to the resolver-specific defaults when resolving imports. */
41 | // "noUncheckedSideEffectImports": true, /* Check side effect imports. */
42 | "resolveJsonModule": true,
43 | // "allowArbitraryExtensions": true, /* Enable importing files with any extension, provided a declaration file is present. */
44 | // "noResolve": true, /* Disallow 'import's, 'require's or '<reference>'s from expanding the number of files TypeScript should add to a project. */
45 | /* JavaScript Support */
46 | // "allowJs": true, /* Allow JavaScript files to be a part of your program. Use the 'checkJS' option to get errors from these files. */
47 | // "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */
48 | // "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from 'node_modules'. Only applicable with 'allowJs'. */
49 | /* Emit */
50 | // "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */
51 | // "declarationMap": true, /* Create sourcemaps for d.ts files. */
52 | // "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */
53 | "sourceMap": true,
54 | // "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */
55 | // "noEmit": true, /* Disable emitting files from a compilation. */
56 | // "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */
57 | "outDir": "./dist",
58 | // "removeComments": true, /* Disable emitting comments. */
59 | // "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */
60 | // "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */
61 | // "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */
62 | // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
63 | // "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */
64 | // "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */
65 | // "newLine": "crlf", /* Set the newline character for emitting files. */
66 | // "stripInternal": true, /* Disable emitting declarations that have '@internal' in their JSDoc comments. */
67 | // "noEmitHelpers": true, /* Disable generating custom helper functions like '__extends' in compiled output. */
68 | // "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */
69 | // "preserveConstEnums": true, /* Disable erasing 'const enum' declarations in generated code. */
70 | // "declarationDir": "./", /* Specify the output directory for generated declaration files. */
71 | /* Interop Constraints */
72 | // "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */
73 | // "verbatimModuleSyntax": true, /* Do not transform or elide any imports or exports not marked as type-only, ensuring they are written in the output file's format based on the 'module' setting. */
74 | // "isolatedDeclarations": true, /* Require sufficient annotation on exports so other tools can trivially generate declaration files. */
75 | // "erasableSyntaxOnly": true, /* Do not allow runtime constructs that are not part of ECMAScript. */
76 | // "allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */
77 | "esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */
78 | // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */
79 | "forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */
80 | /* Type Checking */
81 | "strict": true, /* Enable all strict type-checking options. */
82 | // "noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied 'any' type. */
83 | // "strictNullChecks": true, /* When type checking, take into account 'null' and 'undefined'. */
84 | // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */
85 | // "strictBindCallApply": true, /* Check that the arguments for 'bind', 'call', and 'apply' methods match the original function. */
86 | // "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */
87 | // "strictBuiltinIteratorReturn": true, /* Built-in iterators are instantiated with a 'TReturn' type of 'undefined' instead of 'any'. */
88 | // "noImplicitThis": true, /* Enable error reporting when 'this' is given the type 'any'. */
89 | // "useUnknownInCatchVariables": true, /* Default catch clause variables as 'unknown' instead of 'any'. */
90 | // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */
91 | // "noUnusedLocals": true, /* Enable error reporting when local variables aren't read. */
92 | // "noUnusedParameters": true, /* Raise an error when a function parameter isn't read. */
93 | // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */
94 | // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */
95 | // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */
96 | // "noUncheckedIndexedAccess": true, /* Add 'undefined' to a type when accessed using an index. */
97 | // "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */
98 | // "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type. */
99 | // "allowUnusedLabels": true, /* Disable error reporting for unused labels. */
100 | // "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */
101 | /* Completeness */
102 | // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
103 | "skipLibCheck": true /* Skip type checking all .d.ts files. */
104 | },
105 | "include": [
106 | "src/**/*"
107 | ],
108 | "exclude": [
109 | "node_modules",
110 | "dist"
111 | ]
112 | }
```