Skip to content

Commit d7bedd2

Browse files
committed
Updated sources
1 parent b328969 commit d7bedd2

File tree

192 files changed

+346
-288
lines changed

Some content is hidden

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

192 files changed

+346
-288
lines changed

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: 37 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,93 +1,60 @@
1-
![](https://img.shields.io/badge/api-v2.0-lightgrey) ![PyPI](https://img.shields.io/pypi/v/groupdocs-conversion-cloud) ![PyPI - Python Version](https://img.shields.io/pypi/pyversions/groupdocs-conversion-cloud) ![PyPI - Implementation](https://img.shields.io/pypi/implementation/groupdocs-conversion-cloud) ![PyPI - Wheel](https://img.shields.io/pypi/wheel/groupdocs-conversion-cloud) [![GitHub license](https://img.shields.io/github/license/groupdocs-conversion-cloud/groupdocs-conversion-cloud-python)](https://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-python/blob/master/LICENSE)
1+
# GroupDocs.Conversion Cloud Python SDK
2+
Python package for communicating with the GroupDocs.Conversion Cloud API
23

3-
# Python SDK to Convert Documents in the Cloud
4+
## Requirements
45

5-
[GroupDocs.Conversion Cloud SDK for Python](https://products.groupdocs.cloud/conversion/python) wraps GroupDocs.Conversion RESTful APIs so you may integrate **Document Conversion** features in your own apps with zero initial cost.
6+
Python 2.7 or 3.4+
67

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.
8-
9-
## Document Conversion REST API
10-
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.
23-
24-
Check out the [Developer's Guide](https://docs.groupdocs.cloud/conversion/developer-guide/) to know more about GroupDocs.Conversion REST API.
25-
26-
## Microsoft File Formats
27-
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 Python
50-
51-
First create an account at [GroupDocs for Cloud](https://dashboard.groupdocs.cloud/) and get your application information. Next, execute the following command.
8+
## Installation
9+
Install `groupdocs-conversion-cloud` with [PIP](https://pypi.org/project/pip/) from [PyPI](https://pypi.org/) by:
5210

5311
```sh
5412
pip install groupdocs-conversion-cloud
5513
```
5614

57-
Or clone this repository and install it via [Setuptools](http://pypi.python.org/pypi/setuptools).
15+
Or clone repository and install it via [Setuptools](http://pypi.python.org/pypi/setuptools):
5816

5917
```sh
6018
python setup.py install
6119
```
6220

63-
## Convert DOCX to PDF in the Cloud
21+
## Getting Started
22+
23+
Please follow the [installation procedure](#installation) and then run following:
6424

6525
```python
26+
# Import module
6627
import groupdocs_conversion_cloud
6728

68-
# Get Client Id and Client Secret from https://dashboard.groupdocs.cloud
69-
my_client_id = ""
70-
my_client_secret = ""
29+
# Get your app_sid and app_key at https://dashboard.groupdocs.cloud (free registration is required).
30+
app_sid = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
31+
app_key = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
7132

7233
# Create instance of the API
73-
configuration = groupdocs_conversion_cloud.Configuration(my_client_id, my_client_secret)
74-
apiInstance = groupdocs_conversion_cloud.ConvertApi.from_config(configuration)
75-
76-
# Prepare convert settings
77-
settings = groupdocs_conversion_cloud.ConvertSettings()
78-
settings.file_path = "WordProcessing/four-pages.docx"
79-
settings.format = "pdf"
80-
settings.output_path = "converted"
81-
82-
# Convert
83-
result = apiInstance.convert_document(groupdocs_conversion_cloud.ConvertDocumentRequest(settings))
34+
api = groupdocs_conversion_cloud.InfoApi.from_keys(app_sid, app_key)
35+
36+
try:
37+
# Retrieve supported conversion types
38+
request = groupdocs_conversion_cloud.GetSupportedConversionTypesRequest()
39+
response = api.get_supported_conversion_types(request)
40+
41+
# Print out supported conversion types
42+
print("Supported conversion types:")
43+
for format in response:
44+
print('{0} to [{1}]'.format(format.source_format, ', '.join(format.target_formats)))
45+
except groupdocs_conversion_cloud.ApiException as e:
46+
print("Exception when calling get_supported_conversion_types: {0}".format(e.message))
8447
```
8548

86-
## GroupDocs.Conversion Cloud SDKs in Popular Languages
49+
## Licensing
50+
GroupDocs.Conversion Cloud Python SDK licensed under [MIT License](http://github.com/groupdocs-conversion-cloud/groupdocs-conversion-cloud-python/LICENSE).
8751

88-
| .NET | Java | PHP | Python | Ruby | Node.js | Android |
89-
|---|---|---|---|---|---|---|
90-
| [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) |
91-
| [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) | |
52+
## Resources
53+
+ [**Website**](https://www.groupdocs.cloud)
54+
+ [**Product Home**](https://products.groupdocs.cloud/conversion)
55+
+ [**Documentation**](https://docs.groupdocs.cloud/display/conversioncloud/Home)
56+
+ [**Free Support Forum**](https://forum.groupdocs.cloud/c/conversion)
57+
+ [**Blog**](https://blog.groupdocs.cloud/category/conversion)
9258

93-
[Home](https://www.groupdocs.cloud/) | [Product Page](https://products.groupdocs.cloud/conversion/python) | [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-python-samples) | [Blog](https://blog.groupdocs.cloud/category/conversion/) | [Free Support](https://forum.groupdocs.cloud/c/conversion) | [Free Trial](https://dashboard.groupdocs.cloud)
59+
## Contact Us
60+
Your feedback is very important to us. Please feel free to contact us using our [Support Forums](https://forum.groupdocs.cloud/c/conversion).

groupdocs_conversion_cloud/api_client.py

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="api_client.py">
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
@@ -74,12 +74,12 @@ def __init__(self, configuration, header_name=None, header_value=None,
7474
self.configuration = configuration
7575
self.pool = None
7676
self.rest_client = rest.RESTClientObject(configuration)
77-
self.default_headers = {'x-groupdocs-client': 'python sdk', 'x-groupdocs-version': '20.11'}
77+
self.default_headers = {'x-groupdocs-client': 'python sdk', 'x-groupdocs-version': '21.4'}
7878
if header_name is not None:
7979
self.default_headers[header_name] = header_value
8080
self.cookie = cookie
8181
# Set default User-Agent.
82-
self.user_agent = 'python sdk 20.11'
82+
self.user_agent = 'python sdk 21.4'
8383

8484
def __del__(self):
8585
if self.pool is not None:

groupdocs_conversion_cloud/api_exception.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# coding: utf-8
22
# -----------------------------------------------------------------------------------
33
# <copyright company="Aspose Pty Ltd" file="api_exception.py">
4-
# Copyright (c) 2003-2020 Aspose Pty Ltd
4+
# Copyright (c) 2003-2021 Aspose Pty Ltd
55
# </copyright>
66
# <summary>
77
# Permission is hereby granted, free of charge, to any person obtaining a copy

groupdocs_conversion_cloud/apis/convert_api.py

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">
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
@@ -387,7 +387,7 @@ def __downcase_first_letter(self, s):
387387

388388
# --------------------------------------------------------------------------------
389389
# <copyright company="Aspose Pty Ltd" file="convert_document_request.py">
390-
# Copyright (c) 2003-2020 Aspose Pty Ltd
390+
# Copyright (c) 2003-2021 Aspose Pty Ltd
391391
# </copyright>
392392
# <summary>
393393
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -423,7 +423,7 @@ def __init__(self, convert_settings):
423423

424424
# --------------------------------------------------------------------------------
425425
# <copyright company="Aspose Pty Ltd" file="convert_document_direct_request.py">
426-
# Copyright (c) 2003-2020 Aspose Pty Ltd
426+
# Copyright (c) 2003-2021 Aspose Pty Ltd
427427
# </copyright>
428428
# <summary>
429429
# Permission is hereby granted, free of charge, to any person obtaining a copy

groupdocs_conversion_cloud/apis/file_api.py

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">
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
@@ -638,7 +638,7 @@ def __downcase_first_letter(self, s):
638638

639639
# --------------------------------------------------------------------------------
640640
# <copyright company="Aspose Pty Ltd" file="copy_file_request.py">
641-
# Copyright (c) 2003-2020 Aspose Pty Ltd
641+
# Copyright (c) 2003-2021 Aspose Pty Ltd
642642
# </copyright>
643643
# <summary>
644644
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -682,7 +682,7 @@ def __init__(self, src_path, dest_path, src_storage_name=None, dest_storage_name
682682

683683
# --------------------------------------------------------------------------------
684684
# <copyright company="Aspose Pty Ltd" file="delete_file_request.py">
685-
# Copyright (c) 2003-2020 Aspose Pty Ltd
685+
# Copyright (c) 2003-2021 Aspose Pty Ltd
686686
# </copyright>
687687
# <summary>
688688
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -722,7 +722,7 @@ def __init__(self, path, storage_name=None, version_id=None):
722722

723723
# --------------------------------------------------------------------------------
724724
# <copyright company="Aspose Pty Ltd" file="download_file_request.py">
725-
# Copyright (c) 2003-2020 Aspose Pty Ltd
725+
# Copyright (c) 2003-2021 Aspose Pty Ltd
726726
# </copyright>
727727
# <summary>
728728
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -762,7 +762,7 @@ def __init__(self, path, storage_name=None, version_id=None):
762762

763763
# --------------------------------------------------------------------------------
764764
# <copyright company="Aspose Pty Ltd" file="move_file_request.py">
765-
# Copyright (c) 2003-2020 Aspose Pty Ltd
765+
# Copyright (c) 2003-2021 Aspose Pty Ltd
766766
# </copyright>
767767
# <summary>
768768
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -806,7 +806,7 @@ def __init__(self, src_path, dest_path, src_storage_name=None, dest_storage_name
806806

807807
# --------------------------------------------------------------------------------
808808
# <copyright company="Aspose Pty Ltd" file="upload_file_request.py">
809-
# Copyright (c) 2003-2020 Aspose Pty Ltd
809+
# Copyright (c) 2003-2021 Aspose Pty Ltd
810810
# </copyright>
811811
# <summary>
812812
# Permission is hereby granted, free of charge, to any person obtaining a copy

groupdocs_conversion_cloud/apis/folder_api.py

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">
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
@@ -614,7 +614,7 @@ def __downcase_first_letter(self, s):
614614

615615
# --------------------------------------------------------------------------------
616616
# <copyright company="Aspose Pty Ltd" file="copy_folder_request.py">
617-
# Copyright (c) 2003-2020 Aspose Pty Ltd
617+
# Copyright (c) 2003-2021 Aspose Pty Ltd
618618
# </copyright>
619619
# <summary>
620620
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -656,7 +656,7 @@ def __init__(self, src_path, dest_path, src_storage_name=None, dest_storage_name
656656

657657
# --------------------------------------------------------------------------------
658658
# <copyright company="Aspose Pty Ltd" file="create_folder_request.py">
659-
# Copyright (c) 2003-2020 Aspose Pty Ltd
659+
# Copyright (c) 2003-2021 Aspose Pty Ltd
660660
# </copyright>
661661
# <summary>
662662
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -694,7 +694,7 @@ def __init__(self, path, storage_name=None):
694694

695695
# --------------------------------------------------------------------------------
696696
# <copyright company="Aspose Pty Ltd" file="delete_folder_request.py">
697-
# Copyright (c) 2003-2020 Aspose Pty Ltd
697+
# Copyright (c) 2003-2021 Aspose Pty Ltd
698698
# </copyright>
699699
# <summary>
700700
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -734,7 +734,7 @@ def __init__(self, path, storage_name=None, recursive=None):
734734

735735
# --------------------------------------------------------------------------------
736736
# <copyright company="Aspose Pty Ltd" file="get_files_list_request.py">
737-
# Copyright (c) 2003-2020 Aspose Pty Ltd
737+
# Copyright (c) 2003-2021 Aspose Pty Ltd
738738
# </copyright>
739739
# <summary>
740740
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -772,7 +772,7 @@ def __init__(self, path, storage_name=None):
772772

773773
# --------------------------------------------------------------------------------
774774
# <copyright company="Aspose Pty Ltd" file="move_folder_request.py">
775-
# Copyright (c) 2003-2020 Aspose Pty Ltd
775+
# Copyright (c) 2003-2021 Aspose Pty Ltd
776776
# </copyright>
777777
# <summary>
778778
# Permission is hereby granted, free of charge, to any person obtaining a copy

groupdocs_conversion_cloud/apis/info_api.py

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">
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
@@ -293,7 +293,7 @@ def __downcase_first_letter(self, s):
293293

294294
# --------------------------------------------------------------------------------
295295
# <copyright company="Aspose Pty Ltd" file="get_document_metadata_request.py">
296-
# Copyright (c) 2003-2020 Aspose Pty Ltd
296+
# Copyright (c) 2003-2021 Aspose Pty Ltd
297297
# </copyright>
298298
# <summary>
299299
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -331,7 +331,7 @@ def __init__(self, file_path=None, storage_name=None):
331331

332332
# --------------------------------------------------------------------------------
333333
# <copyright company="Aspose Pty Ltd" file="get_supported_conversion_types_request.py">
334-
# Copyright (c) 2003-2020 Aspose Pty Ltd
334+
# Copyright (c) 2003-2021 Aspose Pty Ltd
335335
# </copyright>
336336
# <summary>
337337
# Permission is hereby granted, free of charge, to any person obtaining a copy

groupdocs_conversion_cloud/apis/storage_api.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
# -----------------------------------------------------------------------------------
44
# <copyright company="Aspose Pty Ltd">
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
@@ -475,7 +475,7 @@ def __downcase_first_letter(self, s):
475475

476476
# --------------------------------------------------------------------------------
477477
# <copyright company="Aspose Pty Ltd" file="get_disc_usage_request.py">
478-
# Copyright (c) 2003-2020 Aspose Pty Ltd
478+
# Copyright (c) 2003-2021 Aspose Pty Ltd
479479
# </copyright>
480480
# <summary>
481481
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -511,7 +511,7 @@ def __init__(self, storage_name=None):
511511

512512
# --------------------------------------------------------------------------------
513513
# <copyright company="Aspose Pty Ltd" file="get_file_versions_request.py">
514-
# Copyright (c) 2003-2020 Aspose Pty Ltd
514+
# Copyright (c) 2003-2021 Aspose Pty Ltd
515515
# </copyright>
516516
# <summary>
517517
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -549,7 +549,7 @@ def __init__(self, path, storage_name=None):
549549

550550
# --------------------------------------------------------------------------------
551551
# <copyright company="Aspose Pty Ltd" file="object_exists_request.py">
552-
# Copyright (c) 2003-2020 Aspose Pty Ltd
552+
# Copyright (c) 2003-2021 Aspose Pty Ltd
553553
# </copyright>
554554
# <summary>
555555
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -589,7 +589,7 @@ def __init__(self, path, storage_name=None, version_id=None):
589589

590590
# --------------------------------------------------------------------------------
591591
# <copyright company="Aspose Pty Ltd" file="storage_exists_request.py">
592-
# Copyright (c) 2003-2020 Aspose Pty Ltd
592+
# Copyright (c) 2003-2021 Aspose Pty Ltd
593593
# </copyright>
594594
# <summary>
595595
# Permission is hereby granted, free of charge, to any person obtaining a copy

groupdocs_conversion_cloud/auth.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# coding: utf-8
22
# -----------------------------------------------------------------------------------
33
# <copyright company="Aspose Pty Ltd" file="auth.py">
4-
# Copyright (c) 2003-2020 Aspose Pty Ltd
4+
# Copyright (c) 2003-2021 Aspose Pty Ltd
55
# </copyright>
66
# <summary>
77
# Permission is hereby granted, free of charge, to any person obtaining a copy

0 commit comments

Comments
 (0)