Introduction to NodeJS

[![Node.js Logo][1].

Aspose Cloud SDK for NodeJS

We are pleased to announce the release of [Aspose Cloud SDK][2] for Node.js as per Aspose Cloud 1.1.7.1. With this new release it is possible to create, read, manipulate and export features are greatly improved. You can extract sections, paragraphs, runs, page setup and fonts and update page setup and font in a Word document. read more

New Aspose.Words Methods

As per the latest version of Aspose Cloud 1.1.7.1, we’ve implemented the following functions to the Aspose Cloud Node.js SDK:

  • [Save Word documents as other formats][3] – This feature allows you to save Word documents as DOC, DOCX, DOCM, DOT, DOTX, DOTM, OOXML, HTML, HTMLFixed, WordML, MHTML, ODT, PDF, XPS, TIFF, EPUB, image and several other formats. Now this feature also supports export to XAML_FIXED format. You can use [saveAs][4] “Aspose.Cells Cloud”) resource and send a POST request (specifying save options in the request body) to convert to any supported format.
  • [Split Word documents][5] – This feature allows you to split all or specific pages of a Word document to many formats. This feature was already supported but now it supports split to XAML_FIXED format. You can use [splitDocument][6] resource and send a POST request to split to any supported format.
  • [Get all sections][7] – This feature allows you to get a list of all sections present in a Word document. You can use [sections][8] resource and send a GET request to get this list.
  • [Get a specific section][9] – This feature allows you to get any section from a Word document. You can use [section][10] resource and send a GET request to get a section.
  • [Get all paragraphs][11] – This feature allows you to get a list of all paragraphs present in a Word document. You can use [paragraphs][12] resource and send a GET request to get this list.
  • [Get a specific paragraph][13] – This feature allows you to get any paragraph from a Word document. You can use [paragraph][14] resource and send a GET request to get a paragraph.
  • [Get a specific run][15] – This feature allows you to get any run of any paragraph from a Word document. You can use [run][16] resource and send a GET request to get a run.
  • [Get font information][17] – This feature allows you to get font information from any run of a paragraph. You can use [font][18] resource and send a GET request for this purpose.
  • [Update a run’s font][19] – This feature allows you to update font of any run in a Word document. You can use [font][20] resource and send a POST request (specifying font options in the request body) to update font.
  • [Get page setup information][21] – This feature allows you to get page setup information from any section of a Word document. You can use [pageSetup][22] resource and send a GET request for this purpose.
  • [Update page setup][23] – This feature allows you to update page setup of any section in a Word document. You can use [pageSetup][24] resource and send a POST request (specifying page setup options in the request body) to update page setup.
  • [Get mustache field names][25] – This feature allows you to get mail merge and mustache field names. You can use [mailMergeFieldNames][26] resource and send a GET request (passing useNonMergeFields parameter in the request URI) to get all merge fields including mustache fields.

Code Snippets

Sample Code Aspose.Words - Get Sections

require 'asposecloud'
var AppSID = '****';
var AppKey = '****';

var BaseProductUri = 'http://api.aspose.com/v1.1/';


var config = {'appSID':AppSID,'appKey':AppKey,'baseURI':BaseProductUri};

var aspose = new AsposeCloud(config);

var stg = aspose.Storage();
stg.uploadFile('test_multi_pages.docx');

var words = aspose.Words();
words.getSections('test_multi_pages.docx', function(data){ console.log(data); }); 

Sample Code Aspose.Words - Get Paragraphs

require 'asposecloud'
var AppSID = '****';
var AppKey = '****';

var BaseProductUri = 'http://api.aspose.com/v1.1/';


var config = {'appSID':AppSID,'appKey':AppKey,'baseURI':BaseProductUri};

var aspose = new AsposeCloud(config);

var stg = aspose.Storage();
stg.uploadFile('test_multi_pages.docx');

var words = aspose.Words();
words.getParagraphs('test_multi_pages.docx', function(data){ console.log(data); }); 

Download and Install

Start a Free Trial Today

Start a free trial today - all you need is to [sign up][27] with Aspose Cloud service. Once you have signed up, you are ready to try powerful file processing features offered by Aspose Cloud.

[1]: https://blogs.asposeptyltd.com/cloudsite/wp-content/uploads/sites/15/2014/01/nodejs-logo-300x80.png “Node.js Logo”)](http://www.nodejs.org)Node.js is a JavaScript platform for building fast, scalable network applications. Node.js follows an event-driven, non-blocking I/O model which makes it efficient and lightweight. An ideal platform for data-intensive real-time applications. Node.js is server-side solution for JavaScript, and in particular for receiving and responding to HTTP requests. [Read more about Node.js](http://www.nodejs.org “Node.js” [2]: https://www.aspose.com/cloud/total-api.aspx “Aspose Cloud SDK” [3]: https://www.aspose.com/docs/display/wordscloud/Convert+Word+Documents+to+any+Format+with+Additional+Settings [4]: https://www.aspose.com/docs/display/wordscloud/saveAs+(Controller+resource [5]: https://www.aspose.com/docs/display/wordscloud/Working+with+Split+Resource [6]: https://www.aspose.com/docs/display/wordscloud/splitDocument+%28Controller+Resource%29 “Aspose.Cells Cloud” [7]: https://www.aspose.com/docs/display/wordscloud/Get+a+List+of+Sections+from+a+Word+Document [8]: https://www.aspose.com/docs/display/wordscloud/sections “Aspose.Cells Cloud” [9]: https://www.aspose.com/docs/display/wordscloud/Get+a+specific+Section+from+a+Word+Document [10]: https://www.aspose.com/docs/display/wordscloud/section “Aspose.Cells Cloud” [11]: https://www.aspose.com/docs/display/wordscloud/Get+a+List+of+Paragraphs+from+a+Word+Document [12]: https://www.aspose.com/docs/display/wordscloud/paragraphs “Aspose.Cells Cloud” [13]: https://www.aspose.com/docs/display/wordscloud/Get+a+Paragraph+from+a+Word+Document [14]: https://www.aspose.com/docs/display/wordscloud/paragraph “Aspose.Cells Cloud” [15]: https://www.aspose.com/docs/display/wordscloud/Get+a+specific+Run+of+a+Paragraph+from+a+Word+Document [16]: https://www.aspose.com/docs/display/wordscloud/run “Aspose.Cells Cloud” [17]: https://www.aspose.com/docs/display/wordscloud/Get+Font+Information+of+a+Run+from+a+Word+Document [18]: https://www.aspose.com/docs/display/wordscloud/font “Aspose.Cells Cloud” [19]: https://www.aspose.com/docs/display/wordscloud/Update+Font+of+a+Run+in+a+Word+Document [20]: https://www.aspose.com/docs/display/wordscloud/font “Aspose.Cells Cloud” [21]: https://www.aspose.com/docs/display/wordscloud/Extract+Page+Setup+Information+from+a+Word+Document [22]: https://www.aspose.com/docs/display/wordscloud/pageSetup “Aspose.Cells Cloud” [23]: https://www.aspose.com/docs/display/wordscloud/Update+Page+Setup+of+a+Section+in+a+Word+Document [24]: https://www.aspose.com/docs/display/wordscloud/pageSetup “Aspose.Cells Cloud” [25]: https://www.aspose.com/docs/display/wordscloud/Get+All+Merge+Field+Names+from+a+Word+Document [26]: https://www.aspose.com/docs/display/wordscloud/mailMergeFieldNames “Aspose.Cells Cloud” [27]: https://cloud.aspose.com/SignUp