Send documents
Last updated
Was this helpful?
Was this helpful?
curl -X POST https://www.dashdoc.com/api/v4/documents/ \
-H "Authorization: Token your_api_token" \
-F "file=@weight_note.pdf" \
-F "type=Documents" \
-F "transport=1f527452-45f4-11eb-a722-0242ac140004"
import requests
url = "https://www.dashdoc.com/api/v4/transport-messages/"
headers = {
"Authorization": "Token your_api_token"
}
files = {
"file": ("weight_note.pdf", open("weight_note.pdf", "rb")),
}
data = {
"type": "documents",
"transport": "1f527452-45f4-11eb-a722-0242ac140004"
}
response = requests.post(url, headers=headers, files=files, data=data)
print(response.status_code, response.json()){"detail":"Multipart form parse error - Invalid boundary in multipart: None"}