Cooper

Project Url: danielceinos/Cooper
Introduction: Cool User agent interceptor for Okhttp3
More: Author   ReportBugs   
Tags:

This interceptor adds a useful User Agent header value.

Following this format:

User-Agent:Your awesome app name / 1.0.1(2830803); StandAloneInstall; (Google; Android SDK built for x86_64; SDK 28; Android 9)

AppName / VersionName(VersionCode); Installer package; (manufacturer; model; SDK version; Android version code)

Usage

val client = OkHttpClient.Builder()
client.addInterceptor(CooperInterceptor(context))

Install

Last release:

Add it in your root build.gradle at the end of repositories:

allprojects {
        repositories {
            ...
            maven { url 'https://jitpack.io' }
        }
    }

Add the dependency

dependencies {
            implementation 'com.github.danielceinos:Cooper:X.Y.Z'
}
Apps
About Me
Google+: Trinea trinea
GitHub: Trinea