-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Description
Hi,
I'm trying to upload a PDF file to the API.
What is the correct format for the file field?
I tried using:
--form "file=@C:/TestA/Fact2.pdf"
but it doesn't work for me.
Here is the full request I'm making:
bash
Copia
Modifica
curl -X POST
--header "Authorization: Bearer ak-A-w--XXXXxxxxxXXXXXxxxxxxXXXXXxxxxxXXXXXXX"
--header "UploadType: single_doc"
--form "package_type=elite"
--form "file=@C:/TestA/Fact2.pdf"
And this is the response I get:
json
Copia
Modifica
{
"code": 2,
"data": [
{
"type": "missing",
"loc": ["body", "file"],
"msg": "Field required",
"input": null
}
],
"detail": [
{
"type": "missing",
"loc": ["body", "file"],
"msg": "Field required",
"input": null
}
]
}
Any ideas on what I might be doing wrong?
Thanks a lot!
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels