chore: 域名自动同步初步

This commit is contained in:
xiaojunnuo
2026-01-16 18:18:39 +08:00
parent 8685aa371a
commit be1a70299f
22 changed files with 248 additions and 10 deletions
@@ -78,4 +78,15 @@ export class DomainController extends CrudController<DomainService> {
return this.ok();
}
@Post('/sync/submit', { summary: Constants.per.authOnly })
async sync(@Body(ALL) body: any) {
const { dnsProviderType, dnsProviderAccessId } = body;
const req = {
dnsProviderType, dnsProviderAccessId, userId: this.getUserId(),
}
await this.service.syncFromProvider(req);
return this.ok();
}
}