SDK Download and Usage
Official SDKsβ
We provide official SDKs for multiple programming languages to help you easily integrate with the I Hate PPT API.
π Download SDKsPython SDKβ
Installationβ
pip install aippt-python
Quick Startβ
from aippt import AIPPTClient
# Initialize client
client = AIPPTClient(api_key="your_api_key")
# Generate PPT
result = client.generate_ppt(
topic="AI Development Trends",
mode="quick",
language="en"
)
print(f"PPT ID: {result.ppt_id}")
print(f"Download URL: {result.download_url}")
Advanced Usageβ
# Intelligent editing mode
result = client.generate_ppt(
topic="Product Launch",
mode="intelligent",
language="en",
options={
"audience": "investors",
"duration": 30,
"style": "professional"
}
)
# Document import
result = client.import_document(
file_path="presentation.docx",
options={
"extract_images": True,
"preserve_formatting": True
}
)
# Edit PPT
client.edit_ppt(
ppt_id=result.ppt_id,
instructions="Simplify the content on page 3 and add more data support"
)
JavaScript SDKβ
Installationβ
npm install aippt-js
Quick Startβ
import { AIPPTClient } from 'aippt-js';
// Initialize client
const client = new AIPPTClient('your_api_key');
// Generate PPT
const result = await client.generatePPT({
topic: 'AI Development Trends',
mode: 'quick',
language: 'en'
});
console.log(`PPT ID: ${result.pptId}`);
console.log(`Download URL: ${result.downloadUrl}`);
Advanced Usageβ
// Intelligent editing mode
const result = await client.generatePPT({
topic: 'Product Launch',
mode: 'intelligent',
language: 'en',
options: {
audience: 'investors',
duration: 30,
style: 'professional'
}
});
// Document import
const result = await client.importDocument({
file: fileInput.files[0],
options: {
extractImages: true,
preserveFormatting: true
}
});
// Edit PPT
await client.editPPT(result.pptId, {
instructions: 'Simplify the content on page 3 and add more data support'
});
Java SDKβ
Installationβ
<dependency>
<groupId>com.ihateppt</groupId>
<artifactId>aippt-java</artifactId>
<version>1.0.0</version>
</dependency>
Quick Startβ
import com.ihateppt.AIPPTClient;
import com.ihateppt.models.GeneratePPTRequest;
import com.ihateppt.models.GeneratePPTResponse;
// Initialize client
AIPPTClient client = new AIPPTClient("your_api_key");
// Generate PPT
GeneratePPTRequest request = GeneratePPTRequest.builder()
.topic("AI Development Trends")
.mode("quick")
.language("en")
.build();
GeneratePPTResponse response = client.generatePPT(request);
System.out.println("PPT ID: " + response.getPptId());
System.out.println("Download URL: " + response.getDownloadUrl());
Ready to integrate with your app?
Get started with our powerful API and SDK. Build amazing presentation features into your own applications.
View API DocsPHP SDKβ
Installationβ
composer require ihateppt/aippt-php
Quick Startβ
<?php
require_once 'vendor/autoload.php';
use IHatePPT\AIPPTClient;
// Initialize client
$client = new AIPPTClient('your_api_key');
// Generate PPT
$result = $client->generatePPT([
'topic' => 'AI Development Trends',
'mode' => 'quick',
'language' => 'en'
]);
echo "PPT ID: " . $result['ppt_id'] . "\n";
echo "Download URL: " . $result['download_url'] . "\n";
?>
Community SDKsβ
Go SDKβ
go get github.com/ihateppt/aippt-go
package main
import (
"fmt"
"github.com/ihateppt/aippt-go"
)
func main() {
client := aippt.NewClient("your_api_key")
result, err := client.GeneratePPT(aippt.GeneratePPTRequest{
Topic: "AI Development Trends",
Mode: "quick",
Language: "en",
})
if err != nil {
panic(err)
}
fmt.Printf("PPT ID: %s\n", result.PPTID)
fmt.Printf("Download URL: %s\n", result.DownloadURL)
}
Ruby SDKβ
gem install aippt-ruby
require 'aippt'
client = AIPPT::Client.new('your_api_key')
result = client.generate_ppt(
topic: 'AI Development Trends',
mode: 'quick',
language: 'en'
)
puts "PPT ID: #{result.ppt_id}"
puts "Download URL: #{result.download_url}"
SDK Featuresβ
Unified Interfaceβ
All SDKs provide a unified interface design, ensuring consistency across different languages.
Automatic Retryβ
Built-in automatic retry mechanism to handle network errors and temporary failures.
Type Safetyβ
Complete type definitions for compile-time type checking.
Async Supportβ
Support for asynchronous operations to improve application performance.
Error Handlingβ
Unified error handling mechanism for easier debugging and troubleshooting.
Configuration Optionsβ
Basic Configurationβ
client = AIPPTClient(
api_key="your_api_key",
base_url="https://api.ihateppt.com/v1", # Optional
timeout=30, # Request timeout in seconds
retry_count=3, # Number of retries
retry_delay=1 # Retry delay in seconds
)
Advanced Configurationβ
client = AIPPTClient(
api_key="your_api_key",
config={
"timeout": 30,
"retry_count": 3,
"retry_delay": 1,
"rate_limit": True,
"debug": False,
"user_agent": "MyApp/1.0"
}
)
Example Projectsβ
Complete Examplesβ
We provide complete example projects demonstrating SDK usage:
- Python Examples: GitHub Repository
- JavaScript Examples: GitHub Repository
- Java Examples: GitHub Repository
Integration Examplesβ
- Web Application Integration: Shows how to integrate SDK in web applications
- Mobile Application Integration: Shows how to integrate SDK in mobile applications
- Desktop Application Integration: Shows how to integrate SDK in desktop applications
Support and Helpβ
Documentation Resourcesβ
- API Reference - Complete API reference documentation
- Code Examples - Code examples and tutorials
- Best Practices - Development best practices
Technical Supportβ
- GitHub Issues: Report issues and feature requests
- Stack Overflow: Ask questions using the
ihateppttag - Community Forum: Exchange with other developers
- Email Support: sdk-support@ihateppt.com
Ready to integrate with your app?
Get started with our powerful API and SDK. Build amazing presentation features into your own applications.
View API DocsGet Started with SDK - Choose the SDK that fits your project and check out the corresponding documentation and examples.
Available API Endpointsβ
Authenticationβ
POST /v1/auth/api-keyPOST /v1/auth/oauth/tokenPOST /v1/auth/loginPOST /v1/auth/refresh
Pptβ
POST /v1/ppt/generatePOST /v1/ppt/{ppt_id}/editPOST /v1/ppt/importPOST /v1/ppt/batch-generate
Filesβ
POST /v1/files/uploadGET /v1/files/{file_id}/download
Webhooksβ
POST /v1/webhooksPOST /v1/webhooks/test
Usageβ
GET /v1/usage/stats