Ocamba SDK

  1. Open project level build.gradle and add following:
        repositories {
            maven {
                url "http://maven.delsystems.net/public"
            }
        }
    

  1. Open app level build.gradle and add dependecies debug (with logs) and release:

        debugImplementation 'com.ocamba:hoood—debug:{latest-version}'
    

    or

        releaseImplementation 'com.ocamba:hoood:{latest-version}'
    

  1. Create Application class and choose one of two ways to initilaize ocamba:

    • Add Ocampa Api Key to manifest:
      Open App module AndroidManifest.xml and add a new line in application tag:
        <meta-data android:name="com.ocamba.ApiKey" android:value=“API_KEY" /> 
    

    • Open application class and in onCreate method add following:
        OcambaHoood.init();
    

    • Or add Ocamba Api Key directly in init method:
        OcambaHoood.init("API_KEY");
    

  1. If you want to receive callback on initialization (use it if you work with push feature):
        OcambaHoood.push().setPushResponse(new OcambaResponseCallback() {
            @Override
            public void onFailure(Exception e) { }
            @Override
            public void onResponse(int code, String response) { }
        }).init();
    

NOTE: replace API_KEY with your app api key.

NOTE: our recommendation is add OcambaHoood.init() method inside onCreate() method of Application class.

On This Page