Convert your files in terminal using Vertopal API
Project description
Vertopal-CLI
Vertopal-CLI is a small yet powerful utility that allows you to convert digital files into various formats using the Vertopal public API.
You can use Vertopal-CLI by either terminal commands or importing as a Python package.
Installing Vertopal-CLI
Vertopal-CLI is available on PyPI:
python -m pip install vertopal
You can also download the most recent version of Vertopal-CLI binaries for macOS, Windows, and Linux from the releases page or the product page.
Installer
An automatic installer is available for each different platform. It will run an install script that downloads and copy Vertopal-CLI binaries to the correct location.
Using macOS Terminal:
curl https://run.vertopal.com/cli/macos | bash
On Windows using PowerShell:
(curl https://run.vertopal.com/cli/windows).Content | iex
If you are getting any UnauthorizedAccess error, then start Windows
PowerShell with the "Run as administrator" option and run
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope LocalMachine
.
Now re-run the above installation command. To change the
Execution Policies
to its default, you can run
Set-ExecutionPolicy -ExecutionPolicy Default -Scope LocalMachine
.
Using Linux Terminal:
curl https://run.vertopal.com/cli/linux | bash
Using Vertopal-CLI
To use Vertopal-CLI you need to obtain an App-ID and a Security Token.
Converting files using terminal commands are very simple:
vertopal convert document.ipynb --to pdf
To view full command-line help, execute vertopal --help
and vertopal convert --help
in terminal.
Setting App ID and Security Token
Before executing vertopal convert
commands in terminal, you need to set
your obtained App-ID and Security Token in global configuration file:
vertopal config --app "your-app-id" --token "your-security-token"
Importing as Python package
Importing vertopal as a Python package makes it easy to implement file conversions in your projects.
The following code illustrates GIF to APNG conversion using the Vertopal Python package.
import vertopal
converter = vertopal.Converter(
"MickeyMouse.gif",
app="your-app-id",
token="your-security-token",
)
converter.convert("apng")
converter.wait()
if converter.is_converted():
converter.download()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file vertopal-1.0.6.tar.gz
.
File metadata
- Download URL: vertopal-1.0.6.tar.gz
- Upload date:
- Size: 20.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 16e9dd98ffaa38043537eeb10c2925747e7211d94ab9bcdaab2d0f7ec8061755 |
|
MD5 | b3fe290eb9fa37b3456edbe5a0f38b11 |
|
BLAKE2b-256 | 0fee39843cb929f53e66c4b3ce73d59de7438dc62d844dd1f6b789f7b38d4aff |
File details
Details for the file vertopal-1.0.6-py3-none-any.whl
.
File metadata
- Download URL: vertopal-1.0.6-py3-none-any.whl
- Upload date:
- Size: 23.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8353a6fb9ac11fd7bf795822dc215776d60879aa32a2923d521087ac6b622b37 |
|
MD5 | a255053b3f08655eae57397741ae8ac5 |
|
BLAKE2b-256 | df2088d2f9e97518ab16d8f571cef45174fae398b97d8d511494fe6e5ff49d67 |