Good resource on complications. Resource also cover GRADLE building.
https://developer.android.com/codelabs/complications#0