Manifest.xml¶
xlwings Server comes with a sample manifest under xlwings_server/templates/manifest.xml. It is a a Jinja2 template that will produce the correct manifest for all environments (dev, prod, …) when going to the manifest URL of the respective environment (e.g., https://your.domain.com/manifest/download).
Key concepts¶
The manifest template has been set up so that you can have the same add-in installed for various environments (dev, prod, …) without running into any conflicts:
Each environment uses a unique
Id(a UUID) that is stored inpyproject.toml. TheIds are created when runninguv run xlwings-server init.Except for the
prodenvironment, the ribbon tab shows the name of the environment in square brackets (e.g.,My Project [dev]).Except for the
prodenvironement, custom functions show the name of the environment at the end of the namespace (e.g.,MYPROJECT_DEV.MYFUNCTION()).If the downloaded manifest from
/manifest/downloadshows wrong URLs, set theXLWINGS_HOSTNAMEenvironment variable.
Editing the manifest template¶
You’ll have to edit the manifest template for the following reasons:
Adjust the infos towards the top of the file such as
Version,ProviderName, etc.Adjust URLs to icons
Change the groups and buttons etc. that you want to show on the ribbon
Change the ribbon location, see Ribbon location: Office tab vs. custom tab
You should not need to change anything regarding custom functions, as everything is handled via settings.
Ribbon location: Office tab vs. custom tab¶
The xlwings Server default ribbon has been set up as a custom tab in the ribbon. However, you can also integrate the add-in into an existing Excel tab, such as the Home tab, see OfficeTab. To find the id of a specific tab, see Find the IDs of built-in Office ribbon tabs.