Update api.py
Browse files
api.py
CHANGED
|
@@ -3,11 +3,11 @@ from fastapi import FastAPI, HTTPException
|
|
| 3 |
app = FastAPI()
|
| 4 |
|
| 5 |
@app.post("/uploadfile/")
|
| 6 |
-
async def create_upload_file(base64_data
|
| 7 |
try:
|
| 8 |
-
# Base64 veriyi bytes'a decode et
|
| 9 |
-
file_content = base64.b64decode(base64_data)
|
| 10 |
print(base64_data)
|
|
|
|
|
|
|
| 11 |
|
| 12 |
# OCR işlemini gerçekleştir
|
| 13 |
result = "SUCCESS"
|
|
|
|
| 3 |
app = FastAPI()
|
| 4 |
|
| 5 |
@app.post("/uploadfile/")
|
| 6 |
+
async def create_upload_file(base64_data):
|
| 7 |
try:
|
|
|
|
|
|
|
| 8 |
print(base64_data)
|
| 9 |
+
file_content = base64.b64decode(base64_data)
|
| 10 |
+
|
| 11 |
|
| 12 |
# OCR işlemini gerçekleştir
|
| 13 |
result = "SUCCESS"
|