xybu / onedrived-dev

A Microsoft OneDrive client for Linux, written in Python3.
https://github.com/xybu/onedrived-dev
MIT License
705 stars 78 forks source link

Support for OneDrive for Business #1

Open xybu opened 7 years ago

xybu commented 7 years ago

... can't do this yet because I don't have a set of client ID and client secret to test the program.

The biggest problem to support ODfB is that onedrived must be approved by the Office365 admin of the organization domain to obtain the client ID and secret...

gentakojima commented 7 years ago

I can't provide you with credentials, but I can test it with my own University account or even try to fix it. Where could I start? You are using the official OneDrive API, right? I think it should work out of the box.

xybu commented 7 years ago

First we need to get the app registered under some Office 365 domain (https://dev.onedrive.com/app-registration.htm#register-your-app-for-onedrive-for-business) to obtain client ID and secret, then need an account under that domain to run the program.

billhallsb commented 7 years ago

Hi Xybu, I may be able to assist as well, I'll shoot you an email.

ireuz commented 7 years ago

how was it going? did it work out with Onedrive for Business?

threepistons commented 7 years ago

"First we need to get the app registered under some Office 365 domain (https://dev.onedrive.com/app-registration.htm#register-your-app-for-onedrive-for-business) to obtain client ID and secret, then need an account under that domain to run the program."

I've registered the app with my workplace's Office365 domain. When I run "onedrived-pref account add -b", I just get a placeholder error message.

I have no experience with Python, but I will try to figure out what changes must be made to make this work for me. I would be grateful for any pointers though. In particular, you mention a client ID and a secret: where should I put them?

ajcollett commented 7 years ago

I may be able to help. I work in a Technical Position (CS graduate) at a Uni where we make use of Office 365. If you need testers and/or some other help, I am keen. I'm also not too bad with python.

dukechem commented 7 years ago

Tekki is able to authenticate against ODfB (business) with onedrive-perl at https://github.com/Tekki/onedrive-perl And he gives details on how ODfb is different at https://github.com/skilion/onedrive/issues/143#issuecomment-285936704

-Hope this helps... P.S. I'm also at a edu and looking for just a simple cli bulk-uploader for linux/mac. Maybe to put in a cronjob passed a list of updated/changed files. Does the authentication expire, and if so what's the timeout?

(P.P.S. The odrive folks have some cli python based utils btw)

felixleong commented 7 years ago

The Python API certainly already have OneDrive for Business support with brief documentations in the README.

A starting point would be to look into onedrived/od_auth.py and work from there.

derrix060 commented 7 years ago

I'm implementing the business account support. You can see my fork: https://github.com/derrix060/onedrived-dev

@xybu, I can also help you with is necessary.

derrix060 commented 7 years ago

I think I'm done to add business support. Who have an business account, please go to my project and do the tests, with my account is everything working.

@xybu What do you prefer: to keep this on separate repository or that I merge in another branch?

daviddavo commented 7 years ago

Giving that there is already a non-working business option which returns that "is not yet supported" it would be nice a merge

fgreinus commented 6 years ago

What's the status of this issue? It seems to me (when reading the comments), that it's only the pull request that is missing. Is there anything I can do to support? :+1:

derrix060 commented 6 years ago

Hello @fgreinus you can check my repo and test if it's working okay.

karolszk commented 5 years ago

Hi @derrix060 onedrive-client-perf account authenticated my OneDrive for Bussiness account without any problems. But onedrive-client-perf drive set is unable to recognise my drives and returns empty set. Here is a log:

karol@aasd34:~/onedrive$ bin/onedrive-client-pref drive set Reading drives information from OneDrive server...

All available Drives of authorized accounts:

Account Email Drive ID Type Quota Status


Please enter row number of the Drive to add or modify (CTRL+C to abort):

derrix060 commented 5 years ago

Hello @karolszk, please log these results in the project. There is an open issue for this case, and there is a problem with the OneDrive API.

karolszk commented 5 years ago

OK. But please tell me how to log / debug onedrive-client-pref drive set I don't see any -debug or -verbose option.

karolszk commented 5 years ago

Today I switched to https://www.maketecheasier.com/sync-onedrive-linux/

bmaupin commented 3 years ago

Today I switched to https://www.maketecheasier.com/sync-onedrive-linux/

The source repo is here: https://github.com/abraunegg/onedrive

bmaupin commented 3 years ago

Since it's good to have options, this looks like another promising alternative: https://rclone.org/onedrive/

It looks like it supports OneDrive Personal, OneDrive for Business, and Sharepoint Server. And it supports other backends as well.