File size: 738 Bytes
81e13bb
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import requests

# Define the API endpoint
# url = "http://127.0.0.0:7860/api/home"

post_url = "http://localhost:7860/api/aadhar_ocr"
# response = requests.get(url)

# print()
# Define the file pathscd
files = {
    "aadhar_file": open("/home/javmulla/model_one/test_images_aadhar/test_two.jpg", "rb"),
    "pan_file": open("/home/javmulla/model_one/test_images_pan/6ea33087.jpeg", "rb"),
    "cheque_file": open("/home/javmulla/model_one/test_images_cheque/0f81678a.jpeg", "rb"),
    "gst_file": open("/home/javmulla/model_one/test_images_gst/0a52fbcb_page3_image_0.jpg", "rb"),
}

response = requests.post(post_url, files=files)

# # Print the response
print("Status Code:", response.status_code)
print("Response Text:", response.text)