feat: Basic setup with auth

This commit is contained in:
sauravdhakal12
2026-02-21 17:21:48 +05:45
parent f6bce78aee
commit f4c9174752
24 changed files with 418 additions and 18 deletions

1
common/http/index.ts Normal file
View File

@@ -0,0 +1 @@
export * from './response';

25
common/http/response.ts Normal file
View File

@@ -0,0 +1,25 @@
export class MessageResponse {
readonly success: boolean;
readonly message: string;
constructor(message?: string) {
this.success = true;
this.message = message ?? 'Success';
}
}
export class DataResponse<T> extends MessageResponse {
readonly data: T;
constructor(data: T, message?: string) {
super(message);
this.data = data;
}
}
// Skipped
export class GlobalErrorResponseDTO {
success: boolean;
message: string;
statusCode: number;
}