Skip to content

Commit e2b15a6

Browse files
committed
docs: Add some things
1 parent a8e1647 commit e2b15a6

File tree

1 file changed

+17
-7
lines changed

1 file changed

+17
-7
lines changed

pypi.md

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,23 @@
11
# Tinify
22

3-
**Tinify** is the official Python client for the [TinyPNG](https://tinypng.com) and [TinyJPG](https://tinyjpg.com) image compression API, enabling developers to optimize PNG, JPEG, and WebP images programmatically.
3+
**Tinify** is the official Python client for the [TinyPNG](https://tinypng.com) and [TinyJPG](https://tinyjpg.com/) image compression API, enabling developers to intelligently compress, resize, convert and optimize PNG, APNG, JPEG, WebP and AVIF images programmatically. Read more at [https://tinify.com](https://tinify.com/developers).
44

55
[![PyPI version](https://badge.fury.io/py/tinify.svg)](https://badge.fury.io/py/tinify)
66
[![Build Status](https://github.com/tinify/tinify-python/actions/workflows/ci-cd.yml/badge.svg)](https://github.com/tinify/tinify-python/)
7+
78
## Features
89

9-
- Compress images, reducing file size by 50-80% while preserving visual quality
10+
- Compress and optimize images, reducing file size by 50-80% while preserving visual quality
1011
- Resize and crop images with smart compression
11-
- Convert between PNG, JPEG, and WebP formats
12+
- Convert between PNG, JPEG, WebP and AVIF formats
1213
- Preserve metadata (optional)
14+
- Upload to storage providers like Amazon S3, Google cloud storage.
1315
- Apply visual transformations with the Tinify API
14-
- Supports asynchronous operations
1516
- Comprehensive error handling
1617

1718
## Installation
1819

19-
```python
20+
```bash
2021
pip install tinify
2122
```
2223

@@ -75,6 +76,15 @@ tinify.from_file("image.png").convert(
7576
).to_file("image.webp")
7677
```
7778

79+
```python
80+
# Convert to smallest format
81+
converted = tinify.from_file("image.png").convert(
82+
type=["image/webp", "image/webp"]
83+
)
84+
extension = converted.result().extension
85+
converted.to_file("image." + extension)
86+
```
87+
7888
### Compression Count Monitoring
7989

8090
```python
@@ -111,7 +121,7 @@ except Exception as e:
111121

112122
## Requirements
113123

114-
- Python 3.6+
124+
- Python 2.7+
115125
- Requests library
116126

117127
## Documentation
@@ -124,4 +134,4 @@ This software is licensed under the MIT License. See [LICENSE](https://github.co
124134

125135
## Support
126136

127-
For issues and feature requests, please use our [GitHub Issues](https://github.com/tinify/tinify-python/issues) page.
137+
For issues and feature requests, please use our [GitHub Issues](https://github.com/tinify/tinify-python/issues) page or contact us at [support@tinify.com](mailto:support@tinify.com)

0 commit comments

Comments
 (0)