Editing an existing PowerPoint
Learn how to edit an existing PowerPoint
Last updated
Learn how to edit an existing PowerPoint
Last updated
It is also possible to edit an existing PowerPoint using the SlideSpeak API. This will work for any PowerPoint.
Before editing a PowerPoint using the SlideSpeak API, you first have to edit the names of the placeholder fields inside the PowerPoint you want to edit.
Open your PowerPoint inside the desktop application and open the Selection Pane by clicking on Arrange -> Selection Pane
After that, select a text placeholder that you want to be editable and give it a unique name. This name must be unique across the presentation. A recommendation to make this easier is to include the slide number in the name.
Do this for all text that you want to be able to edit using the SlideSpeak API across the different slides.
After we have prepared our PowerPoint we can look at sending the API request in order to edit it. We are going to be sending a post request that includes the document, as well as a config. Let's first look at the config. Here is an example config that edits the presentation we just prepared.
To keep it simple, this config only changes the first slide and the Table of Contents. We can easily expand this by including replacements for the other slides. The "shape_name" must match the name of a given name of a shape in the PowerPoint. Each shape that matches that name will be replaced. For example, you might use the name "FOOTER" multiple times across different slides. If you use that shape name in your config you will see that every text box named FOOTER will have its text replaced to the provided text.
Prefer using Postman? Check out our Postman collection.
We are now ready to send the API request. Make a POST request to the following endpoint:
https://api.slidespeak.co/api/v1/presentation/edit
In this request, include the file and config as form-data. "pptx_file" for the file and "config" for the config. After a few seconds you will get a URL where you can download the edited PowerPoint. You should see that the text has been replaced. If you don't, make sure the shape name matches that of the name selected inside the Selection Pane exactly.
For more details about the edit, or any other endpoint, please view the API Reference page.
Below you can download the PowerPoint file used in this example.