Skip to content

Commit fbe7c95

Browse files
committed
Updated sources
1 parent 5df7f47 commit fbe7c95

192 files changed

Lines changed: 377 additions & 298 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

LICENSE

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2003-2020 Aspose Pty Ltd
3+
Copyright (c) 2003-2018 Aspose Pty Ltd
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1818
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1919
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2020
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21-
SOFTWARE.
21+
SOFTWARE.

README.md

Lines changed: 53 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -1,64 +1,26 @@
1-
![](https://img.shields.io/badge/api-v2.0-lightgrey) ![Packagist Version](https://img.shields.io/packagist/v/groupdocscloud/groupdocs-conversion-cloud) ![Packagist PHP Version Support](https://img.shields.io/packagist/php-v/groupdocscloud/groupdocs-conversion-cloud) [![GitHub license](https://img.shields.io/github/license/groupdocs-conversion-cloud/groupdocs-conversion-cloud-php)](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-php/blob/master/LICENSE)
1+
# GroupDocs.Conversion Cloud SDK for PHP
22

3-
# PHP SDK to Convert Documents in the Cloud
3+
This repository contains GroupDocs.Conversion Cloud SDK for PHP source code. This SDK allows you to work with GroupDocs.Conversion Cloud REST APIs in your PHP applications.
44

5-
[GroupDocs.Conversion Cloud SDK for PHP](https://products.groupdocs.cloud/conversion/php) wraps GroupDocs.Conversion RESTful APIs so you may integrate **Document Conversion** features in your own apps with zero initial cost.
5+
## Dependencies
66

7-
GroupDocs.Conversion Cloud API allows the developers to convert between 50+ file formats including Word documents, Excel spreadsheets, PowerPoint presentations, PDF, OpenDocument files, images & more.
7+
- PHP 5.5 or later
88

9-
## Document Conversion REST API
9+
## Authorization
1010

11-
- Convert the whole document to the desired target format.
12-
- Convert specific document page(s) or a page range.
13-
- Auto-detect source document format without requiring the file extension.
14-
- Load source document with extended options, such as specify password for password-protected documents.
15-
- Load specific part of the document.
16-
- Show or hide document comments.
17-
- Obtain all supported conversion formats list.
18-
- Replace missing fonts with any other font.
19-
- Add text or image watermarks to any page.
20-
- Specify resolution and quality for resultant images.
21-
- Extract metadata & basic information about the source document.
22-
- Integrated storage API.
11+
To use SDK you need AppSID and AppKey authorization keys. You can get your AppSID and AppKey at <https://dashboard.groupdocs.cloud> (free registration is required).
2312

24-
Check out the [Developer's Guide](https://docs.groupdocs.cloud/conversion/developer-guide/) to know more about GroupDocs.Conversion REST API.
13+
## Installation & Usage
2514

26-
## Microsoft File Formats
15+
### Composer
2716

28-
**Microsoft Word:** DOC, DOCM, DOCX, DOT, DOTM, DOTX\
29-
**Microsoft Excel:** XLS, XLSX, XLSB, XLSM\
30-
**Microsoft PowerPoint:** PPT, PPTX, PPS, PPSX\
31-
**Microsoft Project:** MPP, MPT\
32-
**Microsoft Outlook:** MSG, EML\
33-
**Microsoft Visio:** VSD, VDX, VSS, VSX, VST, VTX, VSDX, VDW, VSSX, VSTX, VSDM, VSTM, VSSM\
34-
**Microsoft OneNote:** ONE
35-
36-
## Other Formats
37-
38-
**Page Layout Formats:** PDF, XPS\
39-
**OpenDocument:** ODT, OTT, ODS, ODP, OTP, OTS, ODG\
40-
**CAD:** DXF, DWG, IFC, STL\
41-
**Images:** DCM, BMP, GIF, JPG, PNG, TIFF, WebP, DjVu, SVG, DNG, ICO\
42-
**Web:** HTML, MHT, MHTML\
43-
**Emails:** EML, EMLX\
44-
**eBooks:** EPUB, MOBI\
45-
**Metafile:** WMF, EMF\
46-
**LaTeX:** TEX\
47-
**Others:** TXT, RTF, CSV, TSV, XML
48-
49-
## Get Started with GroupDocs.Conversion Cloud SDK for PHP
50-
51-
First create an account at [GroupDocs for Cloud](https://dashboard.groupdocs.cloud/) and get your application information. Next, follow the installation steps as given below.
52-
53-
### Install via Composer
54-
55-
The package is available at [Packagist](https://packagist.org/) and it can be installed via [Composer](http://getcomposer.org/) by executing following command.
17+
The package is available at [Packagist](https://packagist.org/) and it can be installed via [Composer](http://getcomposer.org/) by executing following command:
5618

5719
```shell
5820
composer require groupdocscloud/groupdocs-conversion-cloud
5921
```
6022

61-
You can also install the package directly from this repository. Add the following to `composer.json`, then run `composer install`.
23+
Or you can install SDK via [Composer](http://getcomposer.org/) directly from this repository, add the following to `composer.json`:
6224

6325
```javascript
6426
{
@@ -74,54 +36,67 @@ You can also install the package directly from this repository. Add the followin
7436
}
7537
```
7638

77-
### Install Manually
39+
Then run `composer install`
40+
41+
### Manual Installation
7842

79-
Clone or download this repository, then run `composer install` in the root directory to install dependencies and include `autoload.php` into your code file.
43+
Clone or download this repository, then run `composer install` in the root directory to install dependencies and include `autoload.php` into your code file:
8044

8145
```php
8246
require_once('/path/to/groupdocs-conversion-cloud-php/vendor/autoload.php');
8347
```
8448

85-
### Tests
49+
## Tests
8650

87-
Set your application information in [json.config](tests/GroupDocs/Conversion/config.json) and execute the following command to run the unit tests.
51+
To run the unit tests set your AppSID and AppKey in [json.config](tests/GroupDocs/Conversion/config.json) and execute following commands:
8852

8953
```shell
9054
php composer.phar install ./vendor/bin/phpunit
9155
```
9256

93-
## Convert DOCX to PDF in the Cloud
57+
## Getting Started
58+
59+
Please follow the [installation procedure](#installation--usage) and then run the following:
9460

9561
```php
96-
// Get application information from https://dashboard.groupdocs.cloud
97-
use GroupDocs\Conversion\Model;
98-
use GroupDocs\Conversion\Model\Requests;
62+
<?php
9963

100-
//Get Client Id and Client Secret from https://dashboard.groupdocs.cloud
101-
$myClientId = "";
102-
$myClientSecret = "";
64+
require_once(__DIR__ . '/vendor/autoload.php');
10365

104-
// Create instance of the API
66+
//TODO: Get your AppSID and AppKey at https://dashboard.groupdocs.cloud (free registration is required).
10567
$configuration = new GroupDocs\Conversion\Configuration();
106-
$configuration->setAppSid($myClientId);
107-
$configuration->setAppKey($myClientSecret);
108-
$apiInstance = new GroupDocs\Conversion\ConvertApi($configuration);
109-
110-
// Prepare convert settings
111-
$settings = new Model\ConvertSettings();
112-
$settings->setFilePath("WordProcessing/four-pages.docx");
113-
$settings->setFormat("pdf");
114-
$settings->setOutputPath("converted");
115-
116-
// Convert
117-
$result = $apiInstance->convertDocument(new Requests\ConvertDocumentRequest($settings));
68+
$configuration->setAppSid("XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX");
69+
$configuration->setAppKey("XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX");
70+
71+
$api = new GroupDocs\Conversion\InfoApi($configuration);
72+
73+
try {
74+
$request = new GroupDocs\Conversion\Model\Requests\GetSupportedConversionTypesRequest();
75+
$response = $api->getSupportedConversionTypes($request);
76+
77+
foreach($response as $key => $format) {
78+
echo $format->getSourceFormat();
79+
}
80+
} catch (Exception $e) {
81+
echo "Something went wrong: ", $e->getMessage(), "\n";
82+
PHP_EOL;
83+
}
84+
85+
?>
11886
```
11987

120-
## GroupDocs.Conversion Cloud SDKs in Popular Languages
88+
## Licensing
89+
90+
GroupDocs.Conversion Cloud SDK for PHP is licensed under [MIT License](LICENSE).
91+
92+
## Resources
93+
94+
+[**Website**](https://www.groupdocs.cloud)
95+
+[**Product Home**](https://products.groupdocs.cloud/conversion)
96+
+[**Documentation**](https://docs.groupdocs.cloud/conversion)
97+
+[**Free Support Forum**](https://forum.groupdocs.cloud/c/conversion)
98+
+[**Blog**](https://blog.groupdocs.cloud/category/conversion)
12199

122-
| .NET | Java | PHP | Python | Ruby | Node.js | Android |
123-
|---|---|---|---|---|---|---|
124-
| [GitHub](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-dotnet) | [GitHub](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-java) | [GitHub](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-php) | [GitHub](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-python) | [GitHub](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-ruby) | [GitHub](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-node) | [GitHub](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-android) |
125-
| [NuGet](https://www.nuget.org/packages/GroupDocs.Conversion-Cloud/) | [Maven](https://repository.groupdocs.cloud/webapp/#/artifacts/browse/tree/General/repo/com/groupdocs/groupdocs-conversion-cloud) | [Composer](https://packagist.org/packages/groupdocscloud/groupdocs-conversion-cloud) | [PIP](https://pypi.org/project/groupdocs-conversion-cloud/) | [GEM](https://rubygems.org/gems/groupdocs_conversion_cloud) | [NPM](https://www.npmjs.com/package/groupdocs-conversion-cloud) | |
100+
## Contact Us
126101

127-
[Home](https://www.groupdocs.cloud/) | [Product Page](https://products.groupdocs.cloud/conversion/php) | [Documentation](https://docs.groupdocs.cloud/conversion/) | [Live Demo](https://products.groupdocs.app/conversion/total) | [API Reference](https://apireference.groupdocs.cloud/conversion/) | [Code Samples](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-php-samples) | [Blog](https://blog.groupdocs.cloud/category/conversion/) | [Free Support](https://forum.groupdocs.cloud/c/conversion) | [Free Trial](https://dashboard.groupdocs.cloud)
102+
Your feedback is very important to us. Please feel free to contact us using our [Support Forums](https://forum.groupdocs.cloud/c/conversion).

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"description": "This repository contains GroupDocs.Conversion Cloud SDK for PHP source code.",
33
"name": "groupdocscloud/groupdocs-conversion-cloud",
4-
"version": "20.11",
4+
"version": "21.4",
55
"license": "MIT",
66
"type": "library",
77
"keywords": [

composer.lock

Lines changed: 5 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/GroupDocs/Conversion/ApiException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* --------------------------------------------------------------------------------------------------------------------
44
* <copyright company="Aspose Pty Ltd" file="ApiException.php">
5-
* Copyright (c) 2003-2020 Aspose Pty Ltd
5+
* Copyright (c) 2003-2021 Aspose Pty Ltd
66
* </copyright>
77
* <summary>
88
* Permission is hereby granted, free of charge, to any person obtaining a copy

src/GroupDocs/Conversion/Configuration.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
* --------------------------------------------------------------------------------------------------------------------
44
* <copyright company="Aspose Pty Ltd" file="Configuration.php">
5-
* Copyright (c) 2003-2020 Aspose Pty Ltd
5+
* Copyright (c) 2003-2021 Aspose Pty Ltd
66
* </copyright>
77
* <summary>
88
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -95,7 +95,7 @@ class Configuration
9595
* Version of client SDK
9696
*
9797
*/
98-
protected $clientVersion = '20.11';
98+
protected $clientVersion = '21.4';
9999

100100
/*
101101
* Constructor
@@ -290,7 +290,7 @@ public function getClientName()
290290
}
291291

292292
/*
293-
* Gets client version, default value is '20.11'
293+
* Gets client version, default value is '21.4'
294294
*
295295
*/
296296
public function getClientVersion()
@@ -308,7 +308,7 @@ public static function toDebugReport()
308308
$report = 'PHP SDK (GroupDocs\Conversion) Debug Report:' . PHP_EOL;
309309
$report .= ' OS: ' . php_uname() . PHP_EOL;
310310
$report .= ' PHP Version: ' . PHP_VERSION . PHP_EOL;
311-
$report .= ' SDK Package Version: 20.11' . PHP_EOL;
311+
$report .= ' SDK Package Version: 21.4' . PHP_EOL;
312312
$report .= ' Temp Folder Path: ' . self::getDefaultConfiguration()->getTempFolderPath() . PHP_EOL;
313313

314314
return $report;

src/GroupDocs/Conversion/ConvertApi.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
* --------------------------------------------------------------------------------------------------------------------
44
* <copyright company="Aspose Pty Ltd" file="ConvertApi.php">
5-
* Copyright (c) 2003-2020 Aspose Pty Ltd
5+
* Copyright (c) 2003-2021 Aspose Pty Ltd
66
* </copyright>
77
* <summary>
88
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -1036,7 +1036,7 @@ private function _requestToken()
10361036
/*
10371037
* --------------------------------------------------------------------------------------------------------------------
10381038
* <copyright company="Aspose Pty Ltd" file="convertDocumentRequest.php">
1039-
* Copyright (c) 2003-2020 Aspose Pty Ltd
1039+
* Copyright (c) 2003-2021 Aspose Pty Ltd
10401040
* </copyright>
10411041
* <summary>
10421042
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -1085,7 +1085,7 @@ public function __construct($convertSettings)
10851085
/*
10861086
* --------------------------------------------------------------------------------------------------------------------
10871087
* <copyright company="Aspose Pty Ltd" file="convertDocumentDirectRequest.php">
1088-
* Copyright (c) 2003-2020 Aspose Pty Ltd
1088+
* Copyright (c) 2003-2021 Aspose Pty Ltd
10891089
* </copyright>
10901090
* <summary>
10911091
* Permission is hereby granted, free of charge, to any person obtaining a copy

src/GroupDocs/Conversion/FileApi.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
* --------------------------------------------------------------------------------------------------------------------
44
* <copyright company="Aspose Pty Ltd" file="FileApi.php">
5-
* Copyright (c) 2003-2020 Aspose Pty Ltd
5+
* Copyright (c) 2003-2021 Aspose Pty Ltd
66
* </copyright>
77
* <summary>
88
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -1557,7 +1557,7 @@ private function _requestToken()
15571557
/*
15581558
* --------------------------------------------------------------------------------------------------------------------
15591559
* <copyright company="Aspose Pty Ltd" file="copyFileRequest.php">
1560-
* Copyright (c) 2003-2020 Aspose Pty Ltd
1560+
* Copyright (c) 2003-2021 Aspose Pty Ltd
15611561
* </copyright>
15621562
* <summary>
15631563
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -1634,7 +1634,7 @@ public function __construct($srcPath, $destPath, $srcStorageName = null, $destSt
16341634
/*
16351635
* --------------------------------------------------------------------------------------------------------------------
16361636
* <copyright company="Aspose Pty Ltd" file="deleteFileRequest.php">
1637-
* Copyright (c) 2003-2020 Aspose Pty Ltd
1637+
* Copyright (c) 2003-2021 Aspose Pty Ltd
16381638
* </copyright>
16391639
* <summary>
16401640
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -1697,7 +1697,7 @@ public function __construct($path, $storageName = null, $versionId = null)
16971697
/*
16981698
* --------------------------------------------------------------------------------------------------------------------
16991699
* <copyright company="Aspose Pty Ltd" file="downloadFileRequest.php">
1700-
* Copyright (c) 2003-2020 Aspose Pty Ltd
1700+
* Copyright (c) 2003-2021 Aspose Pty Ltd
17011701
* </copyright>
17021702
* <summary>
17031703
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -1760,7 +1760,7 @@ public function __construct($path, $storageName = null, $versionId = null)
17601760
/*
17611761
* --------------------------------------------------------------------------------------------------------------------
17621762
* <copyright company="Aspose Pty Ltd" file="moveFileRequest.php">
1763-
* Copyright (c) 2003-2020 Aspose Pty Ltd
1763+
* Copyright (c) 2003-2021 Aspose Pty Ltd
17641764
* </copyright>
17651765
* <summary>
17661766
* Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -1837,7 +1837,7 @@ public function __construct($srcPath, $destPath, $srcStorageName = null, $destSt
18371837
/*
18381838
* --------------------------------------------------------------------------------------------------------------------
18391839
* <copyright company="Aspose Pty Ltd" file="uploadFileRequest.php">
1840-
* Copyright (c) 2003-2020 Aspose Pty Ltd
1840+
* Copyright (c) 2003-2021 Aspose Pty Ltd
18411841
* </copyright>
18421842
* <summary>
18431843
* Permission is hereby granted, free of charge, to any person obtaining a copy

0 commit comments

Comments
 (0)