What is meant by “the server”?

Throughout the Office documentation, as well as this book, you may occasionally encounter sentences such as “after calling chart.getImage() and doing context.sync(), the server will populate the result object with the requested image”. What is meant by “the server” when you’re issuing a simple API request to Excel? Does this mean that even when you’re working on the Desktop, something is being processed by some remote Office 365 endpoint?

Don’t let the wording confuse you. In the context of an Office Add-in, by the server, what is really meant is the host application – that is, the Office application that contains your add-in, and which ultimately manipulates the document on the add-ins behalf. In the case of Office Online, this is in fact a remote Office 365 server. In case of Office on the Desktop or Mac or on iOS, however, it’s just the Excel/Word/etc. application. So, in all cases except Office Online, the operation is executed locally – no remote back-end server crunches the request. The reason it’s sometimes referred to as the server is that, from the running JavaScript’s perspective, it’s still a remote and unknown endpoint, somewhere beyond the JavaScript runtime’s application boundary… And so it’s still a “server” from that perspective, even if it’s often just a different process on the same machine.