Upload document to dust (https://eu.dust.tt) using API
05:40 27 Feb 2026

I am trying to upload a document to dust (https://eu.dust.tt) and cannot get it to work.

Here is what I have tried and the responses I get:

First I tried to list documents already uploaded. I used:

curl --request GET --url https://eu.dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_sources/{dsId}/documents --header 'accept: application/json' --header 'Authorization: Bearer {APIKey}'

With my values of {wId}, {spaceId}, {dsId} and {APIKey} substituted in. This gave the result:

200 OK

   "total" : 3,
   "documents" : []

Now to upload a file, I have tried the following:

curl --request POST --url https://eu.dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_sources/{dsId}/documents --header "Authorization: Bearer {APIKey}" -F "file=@File1.csv"

Where File1.csv exists in the folder from where I run the curl command. I get the message:

{"error":{"type":"method_not_supported_error","message":"The method passed is not supported, GET is expected."}}

This suggests that I am doing something fundamentally wrong but from the docs (https://docs.dust.tt/reference/post_api-v1-w-wid-spaces-spaceid-data-sources-dsid-documents-documentid) I cannot see what!

What curl command do I need to upload (Upsert) a document?

curl