public async Task <GetDocumentByIdResponse> GetDocumentById(string language, int documentId) { var request = CreateRequest("GetDocumentById"); request.AddParameter("language", language); request.AddParameter("DocumentID", documentId); GetDocumentByIdResponse response = await this.ExecuteAsync <GetDocumentByIdResponse>(request).ConfigureAwait(false); return(response); }
public ActionResult Get(string permalink) { GetDocumentIdFromPermalinkResponse idResponse = _webServiceWrapper.GetDocumentIdFromPermalink(permalink).Result; if (idResponse != null) { GetDocumentByIdResponse documentResponse = _webServiceWrapper.GetDocumentById(idResponse.DocumentID).Result; if (documentResponse != null) { return(Rest(documentResponse)); } } return(Rest(null)); }
public async Task <GetDocumentByIdResponse> GetDocumentById(int documentId) { GetDocumentByIdResponse response = await GetDocumentById("no", documentId).ConfigureAwait(false); return(response); }