chore: auto-generate protobuf files [skip ci]
This commit is contained in:
76
gen/admin/audit.ts
Normal file
76
gen/admin/audit.ts
Normal file
@@ -0,0 +1,76 @@
|
||||
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-ts_proto v2.11.6
|
||||
// protoc v4.25.9
|
||||
// source: admin/audit.proto
|
||||
|
||||
/* eslint-disable */
|
||||
import type { Metadata } from "@grpc/grpc-js";
|
||||
import { GrpcMethod, GrpcStreamMethod } from "@nestjs/microservices";
|
||||
import { Observable } from "rxjs";
|
||||
|
||||
export const protobufPackage = "audit.v1";
|
||||
|
||||
export interface GetAuditLogsRequest {
|
||||
accountId?: string | undefined;
|
||||
type?: string | undefined;
|
||||
action?:
|
||||
| string
|
||||
| undefined;
|
||||
/** ISO string */
|
||||
startDate?:
|
||||
| string
|
||||
| undefined;
|
||||
/** ISO string */
|
||||
endDate?: string | undefined;
|
||||
page: number;
|
||||
limit: number;
|
||||
}
|
||||
|
||||
export interface AuditLogItem {
|
||||
id: string;
|
||||
accountId: string;
|
||||
type: string;
|
||||
action: string;
|
||||
ipAddress: string;
|
||||
userAgent: string;
|
||||
detail: string;
|
||||
createdAt: string;
|
||||
}
|
||||
|
||||
export interface GetAuditLogsResponse {
|
||||
logs: AuditLogItem[];
|
||||
total: number;
|
||||
page: number;
|
||||
totalPages: number;
|
||||
}
|
||||
|
||||
export const AUDIT_V1_PACKAGE_NAME = "audit.v1";
|
||||
|
||||
export interface AuditServiceClient {
|
||||
getAuditLogs(request: GetAuditLogsRequest, metadata?: Metadata): Observable<GetAuditLogsResponse>;
|
||||
}
|
||||
|
||||
export interface AuditServiceController {
|
||||
getAuditLogs(
|
||||
request: GetAuditLogsRequest,
|
||||
metadata?: Metadata,
|
||||
): Promise<GetAuditLogsResponse> | Observable<GetAuditLogsResponse> | GetAuditLogsResponse;
|
||||
}
|
||||
|
||||
export function AuditServiceControllerMethods() {
|
||||
return function (constructor: Function) {
|
||||
const grpcMethods: string[] = ["getAuditLogs"];
|
||||
for (const method of grpcMethods) {
|
||||
const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
||||
GrpcMethod("AuditService", method)(constructor.prototype[method], method, descriptor);
|
||||
}
|
||||
const grpcStreamMethods: string[] = [];
|
||||
for (const method of grpcStreamMethods) {
|
||||
const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
||||
GrpcStreamMethod("AuditService", method)(constructor.prototype[method], method, descriptor);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
export const AUDIT_SERVICE_NAME = "AuditService";
|
||||
Reference in New Issue
Block a user