public async Task <ActionResult <ApiSecretsApiDto> > GetSecrets(int id, int page = 1, int pageSize = 10) { var apiSecretsDto = await _apiResourceService.GetApiSecretsAsync(id, page, pageSize); var apiSecretsApiDto = apiSecretsDto.ToApiResourceApiModel <ApiSecretsApiDto>(); return(Ok(apiSecretsApiDto)); }
public async Task <IActionResult> ApiSecrets(int id, int?page) { if (id == 0) { return(NotFound()); } var apiSecrets = await _apiResourceService.GetApiSecretsAsync(id, page ?? 1); _apiResourceService.BuildApiSecretsViewModel(apiSecrets); return(View(apiSecrets)); }