mirror of
https://github.com/certd/certd.git
synced 2026-04-23 19:57:27 +08:00
chore: 域名自动同步初步
This commit is contained in:
@@ -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();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user