feat: 搭建前后端可执行程序示例
This commit is contained in:
23
src/shared/api.ts
Normal file
23
src/shared/api.ts
Normal file
@@ -0,0 +1,23 @@
|
||||
export type RuntimeMode = "development" | "production" | "test";
|
||||
|
||||
export interface DemoResponse {
|
||||
message: string;
|
||||
runtime: {
|
||||
mode: RuntimeMode;
|
||||
bunVersion: string;
|
||||
platform: string;
|
||||
arch: string;
|
||||
timestamp: string;
|
||||
};
|
||||
}
|
||||
|
||||
export interface HealthResponse {
|
||||
ok: true;
|
||||
service: "gateway-checker";
|
||||
timestamp: string;
|
||||
}
|
||||
|
||||
export interface ApiErrorResponse {
|
||||
error: string;
|
||||
status: number;
|
||||
}
|
||||
Reference in New Issue
Block a user