Skip to content

Commit a5ac95c

Browse files
committed
readme fix
1 parent 38e50cc commit a5ac95c

File tree

1 file changed

+23
-22
lines changed

1 file changed

+23
-22
lines changed

README.md

+23-22
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
99
[![Twitter Follow](https://img.shields.io/twitter/follow/imagekitio?label=Follow&style=social)](https://twitter.com/ImagekitIo)
1010

11-
ImageKit Python SDK allows you to use [Image Resizing](https://docs.imagekit.io/features/image-transformations), [Optimization](https://docs.imagekit.io/features/image-optimization), [File Uploading](https://docs.imagekit.io/api-reference/upload-file-api) and
12-
other [ImageKit APIs](https://docs.imagekit.io/api-reference/api-introduction) from software written in the Python
13-
language.
11+
Python SDK for [ImageKit](https://imagekit.io/) implements the new APIs and interface for different file operations.
12+
13+
ImageKit is complete media storage, optimization, and transformation solution that comes with an [image and video CDN](https://imagekit.io/features/imagekit-infrastructure). It can be integrated with your existing infrastructure - storage like AWS S3, web servers, your CDN, and custom domain names, allowing you to deliver optimized images in minutes with minimal code changes.
1414

1515
Supported Python Versions: >=3.6
1616

@@ -91,7 +91,8 @@ endpoint(url_endpoint) you want to use to access the image. You can refer to the
9191
[here](https://docs.imagekit.io/integration/url-endpoints) to read more about URL endpoints
9292
in ImageKit and the section about [image origins](https://docs.imagekit.io/integration/configure-origin) to understand
9393
about paths with different kinds of origins.
94-
The File can be an image, video, or any other static file supported by ImageKit.
94+
95+
The file can be an image, video, or any other static file supported by ImageKit.
9596

9697
```python
9798
imagekit_url = imagekit.url({
@@ -173,7 +174,7 @@ Sample Result URL -
173174
https://ik.imagekit.io/your_imagekit_id/endpoint/default-image.jpg?tr=h-300%2Cw-400%3Art-90
174175
```
175176

176-
**2. Sharpening and contrast transform and a progressive JPG image**
177+
**2. Sharpening, contrast transform and progressive JPG image**
177178

178179
Add transformations like [Sharpening](https://docs.imagekit.io/features/image-transformations/image-enhancement-and-color-manipulation) to the URL with or without any other value. To use such transforms without specifying a value, set it as "-" in the transformation object. Otherwise, use the value that one wants to add to this transformation.
179180

@@ -192,7 +193,7 @@ image_url = imagekit.url({
192193
Sample Result URL -
193194

194195
```
195-
# Note that because `src` parameter is in effect, the transformation string gets added as a query parameter `tr`
196+
# Note that because the `src` parameter is in effect, the transformation string gets added as a query parameter `tr`
196197
197198
https://ik.imagekit.io/your_imagekit_id/endpoint/default-image.jpg?tr=f-jpg%2Cpr-true%2Ce-sharpen%2Ce-contrast-1
198199
```
@@ -595,7 +596,7 @@ print(result.response_metadata.raw)
595596

596597
Delete a file version as per
597598
the [API documentation here](https://docs.imagekit.io/api-reference/media-api/delete-file-version).
598-
The method accepts the `file_id` and particular version id of the File that has to be deleted.
599+
The method accepts the `file_id` and particular version id of the file that has to be deleted.
599600

600601
```python
601602
result = imagekit.delete_file_version(file_id="file_id", version_id="version_id")
@@ -631,7 +632,7 @@ print(result.successfully_deleted_file_ids[0])
631632
**12. Copy file**
632633

633634
Copy a file according to the [API documentation here](https://docs.imagekit.io/api-reference/media-api/copy-file).
634-
The method accepts `source_file_path`, `destination_path`, and `include_file_versions` of the File that has to be copied.
635+
The method accepts `source_file_path`, `destination_path`, and `include_file_versions` of the file that has to be copied.
635636

636637
```python
637638
from imagekitio.models.CopyFileRequestOptions import CopyFileRequestOptions
@@ -652,7 +653,7 @@ print(result.response_metadata.raw)
652653
**13. Move File**
653654

654655
Move a file as per the [API documentation here](https://docs.imagekit.io/api-reference/media-api/move-file).
655-
The method accepts `source_file_path` and `destination_path` of the File that has to be moved.
656+
The method accepts `source_file_path` and `destination_path` of the file that has to be moved.
656657

657658
```python
658659
from imagekitio.models.MoveFileRequestOptions import MoveFileRequestOptions
@@ -696,7 +697,7 @@ print(result.purge_request_id)
696697

697698
Restore a file as per
698699
the [API documentation here](https://docs.imagekit.io/api-reference/media-api/restore-file-version).
699-
The method accepts `file_id` and `version_id` of the File that has to be restored.
700+
The method accepts the `file_id` and `version_id` of the file that has to be restored.
700701

701702
```python
702703
result = imagekit.restore_file_version(file_id="file_id", version_id="version_id")
@@ -898,10 +899,10 @@ can be passed as it is with the correct values to get the results.
898899

899900
Check for the [allowed values in the schema](https://docs.imagekit.io/api-reference/custom-metadata-fields-api/create-custom-metadata-field#allowed-values-in-the-schema-object).
900901

901-
**example:**
902+
**Example:**
902903

903904
```python
904-
# Example for type number
905+
# Example for the type number
905906

906907
from imagekitio.models.CreateCustomMetadataFieldsRequestOptions import CreateCustomMetadataFieldsRequestOptions
907908
from imagekitio.models.CustomMetadataFieldsSchema import CustomMetadataFieldsSchema
@@ -997,7 +998,7 @@ print(result.schema.min_value)
997998

998999
**26. Get CustomMetaDataFields**
9991000

1000-
Accepts the `include_deleted` boolean as initial parameter and fetches the metadata as per
1001+
Accepts the `include_deleted` boolean as the initial parameter and fetches the metadata as per
10011002
the [API documentation here](https://docs.imagekit.io/api-reference/custom-metadata-fields-api/get-custom-metadata-field)
10021003
.
10031004

@@ -1035,7 +1036,7 @@ print(result.list[0].schema.default_value)
10351036

10361037
**27. Update CustomMetaDataFields**
10371038

1038-
Accepts an `field_id` and options for specifying the parameters to be used to edit custom metadata fields
1039+
Accepts a `field_id` and options for specifying the parameters to be used to edit custom metadata fields
10391040
as per
10401041
the [API documentation here](https://docs.imagekit.io/api-reference/custom-metadata-fields-api/update-custom-metadata-field)
10411042
.
@@ -1118,11 +1119,11 @@ value of an image in the response. You can use this value
11181119
to [find a duplicate or similar image](https://docs.imagekit.io/api-reference/metadata-api#using-phash-to-find-similar-or-duplicate-images)
11191120
by calculating the distance between the two images.
11201121

1121-
This SDK exposes `phash_distance` function to calculate the distance between two `pHash` values. It accepts two `pHash`
1122+
This SDK exposes the `phash_distance` function to calculate the distance between two `pHash` values. It accepts two `pHash`
11221123
hexadecimal
11231124
strings and returns a numeric value indicative of the difference between the two images.
11241125

1125-
```Python
1126+
```python
11261127
def calculate_distance():
11271128
# fetch metadata of two uploaded image files
11281129
...
@@ -1139,7 +1140,7 @@ def calculate_distance():
11391140

11401141
```Python
11411142
imagekit.phash_distance('f06830ca9f1e3e90', 'f06830ca9f1e3e90')
1142-
# output: 0 (ame image)
1143+
# output: 0 (same image)
11431144

11441145
imagekit.phash_distance('2d5ad3936d2e015b', '2d6ed293db36a4fb')
11451146
# output: 17 (similar images)
@@ -1168,7 +1169,7 @@ print(result.response_metadata.headers)
11681169

11691170
### Sample Code Instruction
11701171

1171-
To run `sample` code go to the code samples here are hosted on Github - https://github.com/imagekit-samples/quickstart/tree/master/python and run
1172+
To run `sample` code go to the code samples here are hosted on GitHub - https://github.com/imagekit-samples/quickstart/tree/master/python and run.
11721173

11731174
```shell
11741175
python sample.py
@@ -1254,11 +1255,11 @@ $ pip install -e .
12541255

12551256
#### Get samples
12561257

1257-
To integrate ImageKit Samples in the Python, the code samples covered here are hosted on Github - https://github.com/imagekit-samples/quickstart/tree/master/python.
1258+
To integrate ImageKit Samples in the Python, the code samples covered here are hosted on GitHub - https://github.com/imagekit-samples/quickstart/tree/master/python.
12581259

1259-
Open `python/sample.py` file and replace placeholder credentials with actual values. You can get the value of [URL-endpoint](https://imagekit.io/dashboard#url-endpoints) from your ImageKit dashboard. API keys can be obtained from the [developer](https://imagekit.io/dashboard/developer/api-keys) section in your ImageKit dashboard.
1260+
Open the `python/sample.py` file and replace placeholder credentials with actual values. You can get the value of [URL-endpoint](https://imagekit.io/dashboard#url-endpoints) from your ImageKit dashboard. API keys can be obtained from the [developer](https://imagekit.io/dashboard/developer/api-keys) section in your ImageKit dashboard.
12601261

1261-
In `python/sample.py` file, set the following parameters for authentication:
1262+
In the `python/sample.py` file, set the following parameters for authentication:
12621263

12631264
```python
12641265
from imagekitio import ImageKit
@@ -1269,7 +1270,7 @@ imagekit = ImageKit(
12691270
)
12701271
```
12711272

1272-
To install dependencies that are in the `python/requirements.txt` file can fire this command to install them:
1273+
To install dependencies that are in the `python/requirements.txt` file, can fire this command to install them:
12731274

12741275
```shell
12751276
pip install -r python/requirements.txt

0 commit comments

Comments
 (0)