This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from bs4 import BeautifulSoup | |
img = input("Enter the input image : ") | |
url = "https://ocr.asprise.com/api/v1/general" | |
files = {'file': open(img, 'rb')} | |
params = {"api_key": "TEST", "detect_table": "true", "filename": "img.jpg", "fileSize": 1000, "filetype":"image/jpeg"} | |
req = requests.post(url, params=params, files=files) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# copy this file to env and just use this api to upload files and get sharable link | |
# transfer.sh {path_of_file_to_upload} | |
# example : transfer ./test.pdf | |
curl http://transfer.sh --upload-file $1 | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
default_client_id=c9a6efb3d7932fd | |
client_id="${IMGUR_CLIENT_ID:=$default_client_id}" | |
# Function to output usage instructions | |
function usage { | |
echo "Usage: $(basename $0) [<filename|URL> [...]]" >&2 | |
echo | |
echo "Upload images to imgur and output their new URLs to stdout. Each one's" >&2 |