GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - groupdocs-viewer-cloud/groupdocs-viewer-cloud-python: Python SDK to communicate with GroupDocs.Viewer REST API. View Word, Excel, PowerPoint, CAD, Visio, PDF, OpenDocument, email & image formats.

BranchesTags
Open more actions menu

Latest commit

 

History

29 Commits
29 Commits

Folders and files

NameName
Last commit message
Last commit date
groupdocs_viewer_cloud
groupdocs_viewer_cloud
 
 
test
test
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
requirements.txt
requirements.txt
 
 
setup.py
setup.py
 
 
tox.ini
tox.ini
 
 

Repository files navigation

GroupDocs.Viewer Cloud Python SDK

Python package for communicating with the GroupDocs.Viewer Cloud API. This SDK allows you to work with GroupDocs.Viewer Cloud REST APIs in your python applications, which allows rendering a specific document in HTML, image or PDF format with the flexibility to render the whole document or custom range of pages.

Requirements

Python 3.4+

Installation

Install groupdocs-viewer-cloud with PIP from PyPI by:

pip install groupdocs-viewer-cloud

Or clone repository and install it via Setuptools:

python setup.py install

Getting Started

Please follow the installation procedure and then run following:

# Import module
import groupdocs_viewer_cloud

# Get your app_sid and app_key at https://dashboard.groupdocs.cloud (free registration is required).
client_id = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
client_secret = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"

apiInstance = groupdocs_viewer_cloud.ViewApi.from_keys(client_id, client_secret)

format = "jpg"      
file = File.open("myfile.txt", "r")

request = ConvertAndDownloadRequest.new format, file

response = apiInstance.convert_and_download(request)

Below is an example demonstrating how to upload the document, render it, and download the result using GroupDocs.Viewer Cloud SDK for Python.

# Import module
import groupdocs_viewer_cloud

# Get your app_sid and app_key at https://dashboard.groupdocs.cloud (free registration is required).
client_id = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
client_secret = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"

# Upload input file to cloud storage
fileApiInstance = groupdocs_viewer_cloud.FileApi.from_keys(client_id, client_secret)
request = groupdocs_viewer_cloud.UploadFileRequest("myfile.txt", "C:\\Data\\myfile.txt")
fileApiInstance.upload_file(request)

# Render to html format
apiInstance = groupdocs_viewer_cloud.ViewApi.from_keys(client_id, client_secret)
view_options = groupdocs_viewer_cloud.ViewOptions()
view_options.file_info = groupdocs_viewer_cloud.FileInfo()
view_options.file_info.file_path = "myfile.txt"
view_options.view_format = "HTML"
view_options.output_path = "myfile.html"

request = groupdocs_viewer_cloud.CreateViewRequest(view_options)
response = apiInstance.create_view(request)

# Download result
request = groupdocs_viewer_cloud.DownloadFileRequest("myfile.html")
response = fileApiInstance.download_file(request)

print("Expected response type is Stream: " + str(len(response)))

Licensing

GroupDocs.Viewer Cloud Python SDK licensed under MIT License.

Resources

  • Website
  • Product Home
  • Documentation
  • Free Support Forum
  • Blog

Contact Us

Your feedback is very important to us. Please feel free to contact us using our Support Forums.

About

Python SDK to communicate with GroupDocs.Viewer REST API. View Word, Excel, PowerPoint, CAD, Visio, PDF, OpenDocument, email & image formats.

products.groupdocs.cloud/viewer/python

Topics

cadexcelimagesopendocumentpdfpowerpointpypipythonrest-apirest-sdkrestful-apiviewerviewer-cloud-sdkvisioword

Resources

Readme
MIT license
Activity
Custom properties

Stars

4 stars

Watchers

4 watching

Forks

0 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.