Seafile API : Create a user directory from admin account

Hi everyone,

I would like to know if it’s possible to create, by the Web API ( authenticated as an Admin), a directory in a user library with its repository id ?

I tried this route : POST /api2/repos/{repo_id}/dir/?p=path but it doesn’t seem to work if the repo_id is not the repository id of one of the admin’s librairies.

And I can’t seem to find another way to do it in the API documentation.

Thanks for your help.
Regards,
Andre.

Hi, you need a bit of a workaround

  1. Create a repo in user lib, get that id
  2. Then give your admin the rights to that repo with youradress/api/v2.1/admin/shares/
  3. Get an upload link (check Seafile Server)
  4. With that uploadlink, send files to that repo folder
    Create directories then repeat 3 and 4 to upload to those new directories