Generate a Presentation
Creates a new presentation using AI by providing either plain text or previously uploaded document UUIDs. Customize the presentation with various parameters such as template, language, tone, verbosity, and branding options. The endpoint returns a task ID for asynchronous processing; poll the task status to retrieve the final presentation file.
Headers
Section titled “Headers”application/json
The API key to use for the request.
<YOUR_API_KEY>
Body Parameters
Section titled “Body Parameters”The topic to generate a presentation about.
The UUIDs of the uploaded documents to use for the presentation.
The number of slides.
The name of the template or the ID of a branded template. See the branded templates section for more information.
For options, see Get All Templates.
The language to use in the presentation.
Example: French
Whether to include stock images.
Whether to include images from the provided documents. If use_document_images
is true
, the document_uuids
parameter must be provided.
The tone to use for the text.
How verbose, or long, the text should be.
A custom instruction that should be followed when generating the presentation.
Whether to include the ‘cover’ slide.
Whether to include the ‘table of contents’ slides.
Whether to add speaker notes to the slides.
Whether to expand the content with related information, using general knowledge.
Whether to use wording very similar to the provided documents. If use_wording_from_document
is true
, the document_uuids
parameter must be provided.
Whether to include the ‘Brand Logo’ in the slides. The Brand Logo can be configured in SlideSpeak’s web app under Brand Settings.
Whether to apply the ‘Brand Fonts’ to the slides. The Brand Fonts can be configured in SlideSpeak’s web app under Brand Settings.
To properly view the presentation with the selected fonts, make sure the fonts are installed on your local machine.
Whether to apply the ‘Brand Color’ to the slides. The Brand Color can be configured in SlideSpeak’s web app under Brand Settings.
The URL of the brand logo to use in the slides. If both branding_logo
and use_branding_logo
are provided, branding_logo
will take precedence.
The object of brand fonts to use in the slides. If both branding_fonts
and use_branding_fonts
are provided, branding_fonts
will take precedence.
Object structure:
Font used for slide titles.
Font used for slide body content.
To properly view the presentation with the selected fonts, make sure the fonts are installed on your local machine.
The hex color code to use for the slides. If both branding_color
and use_branding_color
are provided, branding_color
will take precedence.
Example: #000000
Whether to run the task synchronously. If set to true
, the API will return the presentation as soon as it is ready.
If set to false
, the API will return a task ID and the presentation will be available at the task_result
URL.
See the Get Task Status endpoint for more information.
The file format of the generated presentation.
Code Examples
Section titled “Code Examples”curl -X POST "https://api.slidespeak.co/api/v1/presentation/generate" -H "Content-Type: application/json" -H "x-api-key: YOUR_API_KEY" -d '{ "plain_text": "Key moments in the French Revolution", "length": 6, "template": "default", "language": "ORIGINAL", "fetch_images": true, "tone": "default", "verbosity": "standard", "custom_user_instructions": "Make sure to mention the storming of the Bastille" }'
fetch('https://api.slidespeak.co/api/v1/presentation/generate', { method: 'POST', headers: { 'Content-Type': 'application/json', 'x-api-key': 'YOUR_API_KEY' }, body: JSON.stringify({ "plain_text": "Key moments in the French Revolution", "length": 6, "template": "default", "language": "ORIGINAL", "fetch_images": true, "tone": "default", "verbosity": "standard", "custom_user_instructions": "Make sure to mention the storming of the Bastille" }),}) .then(response => response.json()) .then(data => { console.log('Response:', data); }) .catch(error => { console.error('Error:', error); });
import requests
url = "https://api.slidespeak.co/api/v1/presentation/generate"headers = { "Content-Type": "application/json", "x-api-key": "YOUR_API_KEY"}payload = { "plain_text": "Key moments in the French Revolution", "length": 6, "template": "default", "language": "ORIGINAL", "fetch_images": True, "tone": "default", "verbosity": "standard", "custom_user_instructions": "Make sure to mention the storming of the Bastille"}
response = requests.post(url, headers=headers, json=payload)print(response.json())
<?phprequire 'vendor/autoload.php';
use GuzzleHttpClient;
$client = new Client();
$response = $client->post('https://api.slidespeak.co/api/v1/presentation/generate', [ 'headers' => [ 'Content-Type' => 'application/json', 'x-api-key' => 'YOUR_API_KEY' ], 'json' => [ 'plain_text' => 'Key moments in the French Revolution', 'length' => 6, 'template' => 'default', 'language' => 'ORIGINAL', 'fetch_images' => true, 'tone' => 'default', 'verbosity' => 'standard', 'custom_user_instructions' => 'Make sure to mention the storming of the Bastille' ]]);
$body = $response->getBody();$data = json_decode($body, true);
print_r($data);
Example body
Section titled “Example body”{ "plain_text": "Key moments in the French Revolution", "length": 6, "template": "default", "language": "ORIGINAL", "fetch_images": true, "tone": "default", "verbosity": "standard", "custom_user_instructions": "Make sure to mention the storming of the Bastille"}
Response
Section titled “Response”{ "task_id": "353509d6-8efe-401c-a8a9-53ca64b520a3"}
Example Task Result
Section titled “Example Task Result”{ "task_id": "353509d6-8efe-401c-a8a9-53ca64b520a3", "task_status": "SUCCESS", "task_result": { "url": "https://slidespeak-files.s3.us-east-2.amazonaws.com/24d89111-71a1-4c05-a909-2d84123c9ba9.pptx" }, "task_info": { "url": "https://slidespeak-files.s3.us-east-2.amazonaws.com/24d89111-71a1-4c05-a909-2d84123c9ba9.pptx" }}