ac-user-auth / app /utils /collection_utils.py
MukeshKapoor25's picture
first commit
4438ee0
raw
history blame contribute delete
298 Bytes
COLLECTION_MAPPING = {
"/api/v1/insightfy": "insightfy-bloom-users",
"/api/v1/book-my-service": "book-my-service-users",
}
def get_collection_from_prefix(prefix: str):
"""
Retrieve the collection name based on the API route prefix.
"""
return COLLECTION_MAPPING.get(prefix)