cnpmcore
Version:
Private NPM Registry for Enterprise
25 lines (24 loc) • 1.59 kB
TypeScript
import type { Static } from '@eggjs/typebox-validate/typebox';
import { Context } from 'egg';
import type { UpdateRegistryCmd } from '../../core/service/RegistryManagerService.ts';
import { RegistryCreateOptions, RegistryCreateSyncOptions, type QueryPageOptions } from '../typebox.ts';
import { AbstractController } from './AbstractController.ts';
export declare class RegistryController extends AbstractController {
private readonly registryManagerService;
private readonly scopeManagerService;
listRegistries(pageSize: Static<typeof QueryPageOptions>['pageSize'], pageIndex: Static<typeof QueryPageOptions>['pageIndex']): Promise<import("../../core/util/EntityUtil.ts").PageResult<import("../../core/entity/Registry.ts").Registry>>;
showRegistry(id: string): Promise<import("../../core/entity/Registry.ts").Registry>;
showRegistryScopes(id: string, pageSize: Static<typeof QueryPageOptions>['pageSize'], pageIndex: Static<typeof QueryPageOptions>['pageIndex']): Promise<import("../../core/util/EntityUtil.ts").PageResult<import("../../core/entity/Scope.ts").Scope>>;
createRegistry(ctx: Context, registryOptions: Static<typeof RegistryCreateOptions>): Promise<{
ok: boolean;
}>;
createRegistrySyncTask(ctx: Context, id: string, registryOptions: Static<typeof RegistryCreateSyncOptions>): Promise<{
ok: boolean;
}>;
removeRegistry(ctx: Context, id: string): Promise<{
ok: boolean;
}>;
updateRegistry(ctx: Context, id: string, updateRegistryOptions: Partial<UpdateRegistryCmd>): Promise<{
ok: boolean;
}>;
}