GroupDocs.Comparison for Cloud is a REST API that enables your Ruby applications to fetch two documents of supported file format, compare those same format documents and find differences between them. The SDK allows you to make a resultant file and enables you to accept or reject the retrieved changes. Our Document Comparison SDK allows easy integration into your existing Ruby applications, to empower your end-users to compare documents, spreadsheets, presentations, Microsoft Visio diagrams, emails, and files of many other formats.
An overview of the features supported by the document comparison Cloud API.
Document comparison Cloud API supported formats.
Supported Operating Systems and Frameworks
Using GroupDocs.Comparison Cloud API, you can compare documents and get the list of modifications in the form of images. Following piece of code shows how you can compare a source and a target DOCX files and fetch their differences in a result.DOCX file. Later you can get the resultant DOCX file as images using Ruby:
# TODO: Get your AppSID and AppKey at https://dashboard.groupdocs.cloud (free registration is required). # For complete examples and data files, please go to https://github.com/groupdocs-comparison-cloud/groupdocs-comparison-cloud-ruby # Returns images of document with the result of comparison # throws ApiException if the Api call fails def comparison_images @config = GroupDocsComparisonCloud::Configuration.new(Utils::APP_SID, Utils::APP_KEY) @config.api_base_url = Utils::API_BASE_URL @sourcefile = "source.docx" @targetfile = "target.docx" @outputfile= "result.docx" # Upload file to Cloud Storage upload_file(@sourcefile) upload_file(@targetfile) # Returns images of document with the result of comparison @comparison_api = GroupDocsComparisonCloud::ComparisonApi.from_config(@config) request = GroupDocsComparisonCloud::ComparisonImagesRequest.new(GetComparisonRequest(@sourcefile, @targetfile),@outputfile) response = @comparison_api.comparison_images(request) puts response puts 'completed' end