Office.js is the set of Office JavaScript APIs that Microsoft provides for Office Add-ins. An Office Add-in is a web application, built with HTML, CSS and JavaScript, that runs inside Outlook, Excel, Word, PowerPoint, OneNote or Project on Windows, Mac, iPad and in a browser. Office.js is the layer through which the add-in's code reads and changes the open document.
An add-in has two parts: an app package, a zip file with a manifest that says how the add-in appears in Office and which permissions it needs, and a web app hosted on any web server. The add-in can add ribbon buttons, open a task pane (a web view beside the document) and react to document events. Office.js has a common API shared by the Office applications and richer application-specific models. In Excel, code works with workbooks, worksheets, tables, charts and Range objects; a range is one cell or a block of cells whose values, formulas and formats the code reads or writes.
The API is part of Office; the downloaded pages state no separate price. Add-ins are published to an organization by its admin or to Microsoft Marketplace.