
Security News
MCP Community Begins Work on Official MCP Metaregistry
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
Is A Fast & Friendly Web Framework For Building Async APIs With Python 3.10+
📚 Full Documentation: PantherPy.GitHub.io
$ pip install panther
$ panther create
$ panther run --reload
* Panther uses Uvicorn as ASGI (Asynchronous Server Gateway Interface) but you can run the project with Granian, daphne or any ASGI server
$ panther monitor
$ panther shell
Create main.py
from datetime import datetime, timedelta
from panther import status, Panther
from panther.app import GenericAPI
from panther.response import Response
class FirstAPI(GenericAPI):
# Cache Response For 10 Seconds
cache = True
cache_exp_time = timedelta(seconds=10)
def get(self):
date_time = datetime.now().isoformat()
data = {'detail': f'Hello World | {date_time}'}
return Response(data=data, status_code=status.HTTP_202_ACCEPTED)
url_routing = {'': FirstAPI}
app = Panther(__name__, configs=__name__, urls=url_routing)
Run the project:
$ panther run --reload
Checkout the http://127.0.0.1:8000/
Create main.py
from panther import Panther
from panther.app import GenericAPI
from panther.response import HTMLResponse
from panther.websocket import GenericWebsocket
class FirstWebsocket(GenericWebsocket):
async def connect(self, **kwargs):
await self.accept()
async def receive(self, data: str | bytes):
await self.send(data)
class MainPage(GenericAPI):
def get(self):
template = """
<input type="text" id="messageInput">
<button id="sendButton">Send Message</button>
<ul id="messages"></ul>
<script>
var socket = new WebSocket('ws://127.0.0.1:8000/ws');
socket.addEventListener('message', function (event) {
var li = document.createElement('li');
document.getElementById('messages').appendChild(li).textContent = 'Server: ' + event.data;
});
function sendMessage() {
socket.send(document.getElementById('messageInput').value);
}
document.getElementById('sendButton').addEventListener('click', sendMessage);
</script>
"""
return HTMLResponse(template)
url_routing = {
'': MainPage,
'ws': FirstWebsocket,
}
app = Panther(__name__, configs=__name__, urls=url_routing)
Run the project:
$ panther run --reload
Go to http://127.0.0.1:8000/ and work with your websocket
Next Step: First CRUD
If you find this project useful, please give it a star ⭐️.
FAQs
Fast & Friendly, Web Framework For Building Async APIs
We found that panther demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
Research
Security News
Socket uncovers an npm Trojan stealing crypto wallets and BullX credentials via obfuscated code and Telegram exfiltration.
Research
Security News
Malicious npm packages posing as developer tools target macOS Cursor IDE users, stealing credentials and modifying files to gain persistent backdoor access.