Browse Source, or main file DailyMotionSample.java.
Prerequisites: install Java 7 or higher, git, and
Maven. You may need to set your JAVA_HOME
.
-
Check out the sample code:
git clone https://github.com/google/google-oauth-java-client.git cd google-oauth-java-client/samples/dailymotion-cmdline-sample
-
Edit the
OAuth2ClientCredentials.java
file with your credentials. To acquire credentials, go to the Dailymotion Developer Profile, click "Create New API Key" and specify "http://127.0.0.1:8080/Callback" as the "Callback URL". -
Run the sample:
mvn compile mvn -q exec:java