We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Knuckles-Team/archivebox-api'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
decorators.py•537 B
#!/usr/bin/python
# coding: utf-8
import functools
from archivebox_api.exceptions import LoginRequiredError
def require_auth(function):
"""
Wraps API calls in function that ensures headers are passed
with a token or API key
"""
@functools.wraps(function)
def wrapper(self, *args, **kwargs):
if not (
"Authorization" in self.headers or "X-ArchiveBox-API-Key" in self.headers
):
raise LoginRequiredError
return function(self, *args, **kwargs)
return wrapper