sarlink-portal/lib/backend-types.ts
i701 aa18484475
Some checks failed
Build and Push Docker Images / Build and Push Docker Images (push) Failing after 13m55s
refactor: add tryCatch utility for error handling, update device-related components and types, and clean up unused code in payment actions
2025-04-05 16:07:11 +05:00

53 lines
822 B
TypeScript

export interface Links {
next_page: string | null;
previous_page: string | null;
}
export interface Meta {
total: number;
per_page: number;
current_page: number;
last_page: number;
}
export interface ApiResponse<T> {
meta: Meta;
links: Links;
data: T[];
}
export interface Atoll {
id: number;
islands: Island[];
name: string;
createdAt: string;
updatedAt: string;
}
export interface Island {
id: number;
name: string;
createdAt: string;
updatedAt: string;
}
export interface Device {
id: number;
name: string;
mac: string;
reason_for_blocking: string | null;
is_active: boolean;
registered: boolean;
blocked: boolean;
blocked_by: string;
expiry_date: string | null;
created_at: string;
updated_at: string;
user: number;
}
export interface Api400Error {
data: {
message: string;
};
}