Connect to Android app

https://docs.parseplatform.org/android/guide/#getting-started

Install Parse-SDK-Android

Open your project's build.gradle file (not the module file) and add this dependency,

allprojects {
	repositories {
		...
		maven { url "https://jitpack.io" }
	}
}
dependencies {
    implementation "com.github.parse-community.Parse-SDK-Android:parse:1.18.5"
}

Initialize Parse

Setup Parse using your server configuration:

MyApp.java
import com.parse.Parse;
import android.app.Application;

public class MyApp extends Application 
{
  @Override
  public void onCreate() 
  {
    super.onCreate();
    
    Parse.initialize(new Parse.Configuration.Builder(this)
      .applicationId("YOUR_APP_ID")
      .clientKey("YOUR_CLIENT_KEY")
      .server("https://xxxx.parse-symbyoz.com/parse/")
      .enableLocalDataStore()
      .build()); 
  }
}

The custom Application class must be registered in AndroidManifest.xml

AndroidManifest.xml
<application
   android:name=".MyApp"
   ...>
   ...
 </application>

Last updated