-
Notifications
You must be signed in to change notification settings - Fork 86
Configuration for registry publishing #74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
hemanth
wants to merge
1
commit into
paypal:main
Choose a base branch
from
hemanth:paypal-mcp-server
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+202
−0
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
# PayPal MCP Server | ||
|
||
A Model Context Protocol (MCP) server that provides AI assistants with secure access to PayPal's payment processing, transaction management, and compliance services. | ||
|
||
## Features | ||
|
||
- **Secure Authentication**: OAuth Bearer token authentication | ||
- **SSE Transport**: Server-Sent Events for real-time communication | ||
- **Enterprise Ready**: Built for PayPal's internal development environment | ||
- **Payment Processing**: Tools for payment transactions and management | ||
- **Transaction Queries**: Access to transaction history and status | ||
- **Compliance Services**: PayPal compliance and regulatory tools | ||
|
||
## Connection Details | ||
|
||
- **Server URL**: `https://mcp.paypal.com/mcp` | ||
- **SSE Endpoint**: `https://mcp.paypal.com/sse` | ||
- **Transport**: Server-Sent Events (SSE) | ||
- **Authentication**: Bearer token in Authorization header | ||
|
||
## Setup | ||
|
||
1. Obtain PayPal OAuth credentials from your PayPal developer account | ||
2. Configure Bearer token authentication | ||
3. Connect to the SSE endpoint using your MCP client | ||
4. Ensure SSL certificate validation for PayPal's internal PKI | ||
|
||
## Usage with MCP Clients | ||
|
||
### Claude Desktop Configuration | ||
|
||
```json | ||
{ | ||
"mcpServers": { | ||
"paypal": { | ||
"command": "npx", | ||
"args": ["-y", "@modelcontextprotocol/server-everything"], | ||
"env": { | ||
"MCP_SERVER_URL": "https://mcp.paypal.com/sse", | ||
"MCP_AUTH_TOKEN": "your-paypal-oauth-token" | ||
} | ||
} | ||
} | ||
} | ||
``` | ||
|
||
### FastAgent Configuration | ||
|
||
```yaml | ||
mcp: | ||
servers: | ||
paypal_mcp: | ||
transport: sse | ||
url: https://mcp.paypal.com/sse | ||
headers: | ||
Authorization: Bearer YOUR_PAYPAL_TOKEN | ||
``` | ||
|
||
## Security | ||
|
||
- All connections require valid PayPal OAuth tokens | ||
- SSL/TLS encryption for all communications | ||
- Certificate validation against PayPal's PKI | ||
- Enterprise-grade security standards | ||
|
||
## Publishing to MCP Registry | ||
|
||
This server configuration is ready for publishing to the Model Context Protocol registry. The automated workflow will handle: | ||
|
||
1. JSON schema validation | ||
2. GitHub OIDC authentication | ||
3. Registry publication | ||
4. Verification | ||
|
||
## Support | ||
|
||
For support and documentation: | ||
- PayPal Developer Portal: https://developer.paypal.com/ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we use this ? |
||
- MCP Documentation: https://modelcontextprotocol.io/ | ||
|
||
## License | ||
|
||
MIT License - see LICENSE file for details. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
{ | ||
"$schema": "https://raw.githubusercontent.com/modelcontextprotocol/registry/main/schema/server.schema.json", | ||
"name": "paypal-mcp", | ||
"namespace": "com.paypal.mcp", | ||
"description": "PayPal Model Context Protocol server providing access to PayPal services and operations for AI assistants", | ||
"license": "MIT", | ||
"keywords": ["paypal", "payments", "financial", "api", "enterprise"], | ||
"homepage": "https://mcp.paypal.com", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/hemanth/agent-toolkit" | ||
}, | ||
"version": "1.0.0", | ||
"author": { | ||
"name": "PayPal", | ||
"email": "[email protected]" | ||
}, | ||
"deployment": { | ||
"remote": { | ||
"url": "https://mcp.paypal.com/mcp", | ||
"transport": "sse", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
"endpoints": { | ||
"sse": "https://mcp.paypal.com/sse" | ||
}, | ||
"auth": { | ||
"type": "bearer", | ||
"description": "Requires PayPal OAuth Bearer token in Authorization header" | ||
} | ||
} | ||
}, | ||
"capabilities": { | ||
"tools": true, | ||
"resources": true, | ||
"prompts": false | ||
}, | ||
"documentation": { | ||
"readme": "PayPal MCP Server provides AI assistants with secure access to PayPal's payment processing, transaction management, and compliance services through the Model Context Protocol.", | ||
"setup": "1. Obtain PayPal OAuth credentials\n2. Configure Bearer token authentication\n3. Connect to https://mcp.paypal.com/sse using SSE transport\n4. Use SSL certificate bundle for PayPal's internal PKI", | ||
"examples": [ | ||
{ | ||
"title": "Process Payment", | ||
"description": "Process a payment transaction through PayPal", | ||
"code": "// Connect to PayPal MCP server and use payment processing tools" | ||
}, | ||
{ | ||
"title": "Transaction Query", | ||
"description": "Query transaction history and status", | ||
"code": "// Use transaction query tools to retrieve payment information" | ||
} | ||
] | ||
}, | ||
"tags": ["enterprise", "payments", "secure", "oauth"], | ||
"maintainers": [ | ||
{ | ||
"name": "PayPal Developer Team", | ||
"email": "[email protected]" | ||
} | ||
] | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
#!/usr/bin/env python3 | ||
""" | ||
Validation script for PayPal MCP Server configuration | ||
""" | ||
|
||
import json | ||
import sys | ||
from pathlib import Path | ||
|
||
def validate_server_json(): | ||
"""Validate the server.json file structure and required fields""" | ||
try: | ||
server_json_path = Path(__file__).parent / "server.json" | ||
|
||
with open(server_json_path, 'r') as f: | ||
data = json.load(f) | ||
|
||
print('✅ server.json is valid JSON') | ||
|
||
# Check required fields | ||
required_fields = ['name', 'namespace', 'description', 'version', 'deployment'] | ||
missing = [field for field in required_fields if field not in data] | ||
|
||
if missing: | ||
print(f'❌ Missing required fields: {missing}') | ||
return False | ||
|
||
print('✅ All required fields present') | ||
|
||
# Check deployment structure | ||
if 'remote' in data['deployment']: | ||
remote = data['deployment']['remote'] | ||
if 'url' in remote and 'transport' in remote: | ||
print('✅ Remote deployment configuration valid') | ||
else: | ||
print('❌ Missing url or transport in remote deployment') | ||
return False | ||
|
||
# Validate PayPal-specific fields | ||
if data['name'] != 'paypal-mcp': | ||
print('❌ Server name should be "paypal-mcp"') | ||
return False | ||
|
||
if 'paypal' not in data['keywords']: | ||
print('❌ Missing "paypal" in keywords') | ||
return False | ||
|
||
print('✅ PayPal MCP server.json validation passed') | ||
return True | ||
|
||
except json.JSONDecodeError as e: | ||
print(f'❌ Invalid JSON: {e}') | ||
return False | ||
except Exception as e: | ||
print(f'❌ Validation error: {e}') | ||
return False | ||
|
||
if __name__ == "__main__": | ||
success = validate_server_json() | ||
sys.exit(0 if success else 1) |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can use
/mcp
too.