add admins

This commit is contained in:
2025-11-11 19:03:48 -03:00
parent 39aedac972
commit fa87cf3e07
14 changed files with 219 additions and 12 deletions

View File

@@ -2,16 +2,15 @@ from aws_lambda_powertools.event_handler.api_gateway import Router
from layercake.dynamodb import DynamoDBPersistenceLayer, PartitionKey
from boto3clients import dynamodb_client
from config import COURSE_TABLE, USER_TABLE
from config import COURSE_TABLE
router = Router()
dyn = DynamoDBPersistenceLayer(USER_TABLE, dynamodb_client)
dyn = DynamoDBPersistenceLayer(COURSE_TABLE, dynamodb_client)
@router.get('/<org_id>/custompricing')
@router.get('/<org_id>/custom-pricing')
def get_custom_pricing(org_id: str):
return dyn.collection.query(
PartitionKey(f'CUSTOM_PRICING#ORG#{org_id}'),
table_name=COURSE_TABLE,
limit=100,
)