<?php
require_once(__DIR__ . '/vendor/autoload.php');
$apiKey = 'myApiKey';
$client = new Webpractik\OcfConverter\Sdk\OcfClient($apiKey);
$filePath = '/path/to/file/to/convert.png';
$extensionToConvertTo = 'pdf';
try {
$task = $client->uploadFile($filePath, $extensionToConvertTo);
$result = $task->waitForConversion();
if ($result->isSuccess()) {
$resultUrl = $result->getResultingFileUrl();
$resultFileName = basename($resultUrl);
if (file_put_contents($resultFileName, file_get_contents($resultUrl))) {
$result->deleteFile();
}
}
} catch (Exception $e) {
echo 'Exception: ', $e->getMessage(), PHP_EOL;
}
API 사용의 이점
GIF 파일을 MP4 비디오로 쉽게 변환할 수 있는 다용도 GIF to MP4 API를 사용해 보세요. 플랫폼 간 호환성과 원활한 변환을 즐기세요. 다용도 솔루션으로 파일 변환 요구를 간편하게 해결하세요.
사용자는 어떤 크기의 파일도 제한 없이 변환할 수 있어 다양한 데이터로 작업할 때 편리하고 유연하게 사용할 수 있습니다.
변환 프로세스에 시간 제한이 없으므로 프로세스가 완료될 때까지 기다릴 필요 없이 크고 복잡한 파일도 처리할 수 있습니다.
사용자는 여러 파일을 동시에 변환할 수 있어 대량의 데이터로 작업할 때 효율성을 높이고 시간을 절약할 수 있습니다.
What our customers say
Questions? We'll be your guide
Contact Sales