Skip to content

Commit dff47c8

Browse files
kyoncalKyon Caldera
andauthored
Remove all mention of eks-mcp (#17)
* Remove all mention of eks-mcp * refactor(sigv4_helper.py): remove default service string refactor(sigv4_helper.py): change service string to Optional string and default to None * fix(sigv4_helper.py): make service a required argument --------- Co-authored-by: Kyon Caldera <kyonc@amazon.com>
1 parent 3a1a6cc commit dff47c8

6 files changed

Lines changed: 23 additions & 21 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Optional arguments you can add:
3737
- `--profile`: AWS profile to use (uses AWS_PROFILE environment variable if not provided)
3838
- `--read-only`: Disable tools which require write permissions. (tools which DO NOT require write permissions are annotated with [`readOnlyHint=true`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint))
3939

40-
NOTE: `remote-server-url` should be your remote mcp server's URL (including the `/mcp` part). `service-code` should be the service code for your own mcp service, such as `eks-mcp`.
40+
NOTE: `remote-server-url` should be your remote mcp server's URL (including the `/mcp` part). `service-code` should be the service code for the MCP to be connected.
4141

4242
Example with all options
4343
```json

aws_mcp_proxy/server.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,20 +74,20 @@ def parse_args():
7474
formatter_class=argparse.RawDescriptionHelpFormatter,
7575
epilog="""
7676
Examples:
77-
# Run with EKS MCP endpoint
78-
aws-mcp-proxy https://eks-mcp.us-west-2.api.aws
77+
# Run with your endpoint
78+
aws-mcp-proxy <SigV4 MCP endpoint URL>
7979
8080
# Run with custom service and profile
81-
aws-mcp-proxy https://eks-mcp.us-west-2.api.aws --service eks-mcp --profile default
81+
aws-mcp-proxy <SigV4 MCP endpoint URL> --service <aws-service> --profile default
8282
8383
# Run with write permissions enabled
84-
aws-mcp-proxy https://eks-mcp.us-west-2.api.aws --read-only
84+
aws-mcp-proxy <SigV4 MCP endpoint URL> --read-only
8585
""",
8686
)
8787

8888
parser.add_argument(
8989
'endpoint',
90-
help='MCP endpoint URL (e.g., https://eks-mcp.us-west-2.api.aws)',
90+
help='SigV4 MCP endpoint URL',
9191
)
9292

9393
parser.add_argument(

aws_mcp_proxy/sigv4_helper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ def create_sigv4_auth(
186186

187187

188188
def create_sigv4_client(
189-
service: str = 'eks-mcp',
189+
service: str,
190190
profile: Optional[str] = None,
191191
region: Optional[str] = None,
192192
headers: Optional[Dict[str, str]] = None,

tests/test_server.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ def test_create_sigv4_client_no_credentials(self, mock_session):
206206

207207
# Act & Assert
208208
with pytest.raises(ValueError) as exc_info:
209-
create_sigv4_client()
209+
create_sigv4_client(service='test-service')
210210
assert 'No AWS credentials found' in str(exc_info.value)
211211

212212
def test_main_module_execution(self):

tests/test_sigv4_helper.py

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -304,10 +304,10 @@ def test_create_sigv4_client_default(self, mock_client_class, mock_create_auth):
304304
mock_client_class.return_value = mock_client
305305

306306
# Test client creation
307-
result = create_sigv4_client()
307+
result = create_sigv4_client(service='test-service')
308308

309309
# Verify client was created correctly
310-
mock_create_auth.assert_called_once_with('eks-mcp', None, None)
310+
mock_create_auth.assert_called_once_with('test-service', None, None)
311311

312312
# Check that AsyncClient was called with correct parameters
313313
call_args = mock_client_class.call_args
@@ -330,7 +330,7 @@ def test_create_sigv4_client_with_custom_headers(self, mock_client_class, mock_c
330330

331331
# Test client creation with custom headers
332332
custom_headers = {'Custom-Header': 'custom-value'}
333-
result = create_sigv4_client(headers=custom_headers)
333+
result = create_sigv4_client(service='test-service', headers=custom_headers)
334334

335335
# Verify client was created with merged headers
336336
call_args = mock_client_class.call_args
@@ -373,7 +373,9 @@ def test_create_sigv4_client_with_kwargs(self, mock_client_class, mock_create_au
373373
mock_client_class.return_value = mock_client
374374

375375
# Test client creation with additional kwargs
376-
result = create_sigv4_client(verify=False, proxies={'http': 'http://proxy:8080'})
376+
result = create_sigv4_client(
377+
service='test-service', verify=False, proxies={'http': 'http://proxy:8080'}
378+
)
377379

378380
# Verify client was created with additional kwargs
379381
call_args = mock_client_class.call_args
@@ -403,11 +405,11 @@ def test_create_sigv4_client_with_prompt_context(self, mock_client_class, mock_c
403405
}
404406

405407
result = create_sigv4_client(
406-
service='eks-mcp', headers=prompt_context_headers, region='us-west-2'
408+
service='test-service', headers=prompt_context_headers, region='us-west-2'
407409
)
408410

409411
# Verify client was created correctly with prompt context
410-
mock_create_auth.assert_called_once_with('eks-mcp', None, 'us-west-2')
412+
mock_create_auth.assert_called_once_with('test-service', None, 'us-west-2')
411413

412414
# Check that AsyncClient was called with correct parameters including prompt headers
413415
call_args = mock_client_class.call_args

tests/test_utils.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ def test_create_transport_with_sigv4(self, mock_create_sigv4_client):
3232
mock_client = MagicMock()
3333
mock_create_sigv4_client.return_value = mock_client
3434

35-
url = 'https://eks-mcp.us-west-2.api.aws/mcp'
36-
service = 'eks-mcp'
35+
url = 'https://test-service.us-west-2.api.aws/mcp'
36+
service = 'test-service'
3737
profile = 'test-profile'
3838

3939
result = create_transport_with_sigv4(url, service, profile)
@@ -65,8 +65,8 @@ def test_create_transport_with_sigv4(self, mock_create_sigv4_client):
6565
@patch('aws_mcp_proxy.utils.create_sigv4_client')
6666
def test_create_transport_with_sigv4_no_profile(self, mock_create_sigv4_client):
6767
"""Test creating transport without profile."""
68-
url = 'https://eks-mcp.us-west-2.api.aws/mcp'
69-
service = 'eks-mcp'
68+
url = 'https://test-service.us-west-2.api.aws/mcp'
69+
service = 'test-service'
7070

7171
result = create_transport_with_sigv4(url, service)
7272

@@ -89,7 +89,7 @@ class TestValidateRequiredArgs:
8989

9090
def test_validate_service_name_with_service(self):
9191
"""Test validation when service is provided."""
92-
endpoint = 'https://eks-mcp.us-west-2.api.aws'
92+
endpoint = 'https://test-service.us-west-2.api.aws'
9393
service = 'custom-service'
9494

9595
result = determine_service_name(endpoint, service)
@@ -98,8 +98,8 @@ def test_validate_service_name_with_service(self):
9898

9999
def test_validate_service_name_without_service_success(self):
100100
"""Test validation when service is not provided but can be parsed."""
101-
endpoint = 'https://eks-mcp.us-west-2.api.aws'
102-
expected_service = 'eks-mcp'
101+
endpoint = 'https://test-service.us-west-2.api.aws'
102+
expected_service = 'test-service'
103103

104104
result = determine_service_name(endpoint)
105105

0 commit comments

Comments
 (0)