Skip to content

Commit 8513fd9

Browse files
Manu ChaudharyManu Chaudhary
authored andcommitted
better default values in sample app
1 parent c921e0b commit 8513fd9

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

sample/sample.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
sys.path.append("..")
55

66
# #### set your private_key public_key, url_endpoint, url ### ##
7-
private_key = ""
8-
public_key = ""
9-
url_endpoint = "https://ik.imagekit.io/pshbwfiho"
7+
private_key = "your_public_api_key"
8+
public_key = "your_private_api_key"
9+
url_endpoint = "https://ik.imagekit.io/your_imagekit_id/"
1010
# dummy image url
1111
url = "https://file-examples.com/wp-content/uploads/2017/10/file_example_JPG_100kB.jpg"
1212

@@ -23,7 +23,7 @@
2323
file_name="testing_upload_binary_signed_private.jpg",
2424
options={
2525
"response_fields": ["is_private_file", "tags"],
26-
"is_private_file": True,
26+
"is_private_file": False,
2727
"folder" : "/testing-python-folder/",
2828
"tags": ["abc", "def"]
2929
},
@@ -33,7 +33,7 @@
3333
print("Upload with binary")
3434
print("-------------------------------------")
3535
print(upload, end="\n\n")
36-
36+
3737
image_url = imagekit.url(
3838
{
3939
"path": upload['response']['filePath'],
@@ -143,7 +143,7 @@
143143
file_name="testing-url.jpg",
144144
options={
145145
"response_fields": ["is_private_file"],
146-
"is_private_file": True,
146+
"is_private_file": False,
147147
"tags": ["abc", "def"],
148148
},
149149
)
@@ -162,7 +162,7 @@
162162
file_name="testing-base64.jpg",
163163
options={
164164
"response_fields": ["is_private_file", "metadata", "tags"],
165-
"is_private_file": True,
165+
"is_private_file": False,
166166
"tags": ["abc", "def"],
167167
},
168168
)

sample/test.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
a = https://ik.imagekit.io/pshbwfiho/tr:h-300,w-400/testing-python-folder/testing_upload_binary_signed_private_D15-T6ji5.jpg?v=123&ik-sdk-version=python-2.2.4&ik-t=9999999999&ik-s=abef9e9f3115ad0b7fad82fba2c16ed6144c99c6
2+

0 commit comments

Comments
 (0)