{"id":20218000,"url":"https://github.com/matrix-org/matrix-android-sdk2-sample","last_synced_at":"2025-04-10T15:45:50.921Z","repository":{"id":42082508,"uuid":"303413091","full_name":"matrix-org/matrix-android-sdk2-sample","owner":"matrix-org","description":"Example project for using the android sdk","archived":false,"fork":false,"pushed_at":"2024-01-10T16:36:31.000Z","size":197,"stargazers_count":27,"open_issues_count":8,"forks_count":12,"subscribers_count":15,"default_branch":"main","last_synced_at":"2025-03-24T13:36:24.133Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/matrix-org.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2020-10-12T14:12:41.000Z","updated_at":"2025-01-22T03:07:19.000Z","dependencies_parsed_at":"2024-01-10T18:08:11.868Z","dependency_job_id":"9f41f5ed-38d9-4cec-a7f6-36f68abad841","html_url":"https://github.com/matrix-org/matrix-android-sdk2-sample","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matrix-org%2Fmatrix-android-sdk2-sample","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matrix-org%2Fmatrix-android-sdk2-sample/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matrix-org%2Fmatrix-android-sdk2-sample/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matrix-org%2Fmatrix-android-sdk2-sample/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/matrix-org","download_url":"https://codeload.github.com/matrix-org/matrix-android-sdk2-sample/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248243511,"owners_count":21071055,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-14T06:36:46.843Z","updated_at":"2025-04-10T15:45:50.894Z","avatar_url":"https://github.com/matrix-org.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# matrix-android-sdk2-sample\n\nThis is an example project for using the [matrix-android-sdk2](https://github.com/matrix-org/matrix-android-sdk2)\n\n\n## Gradle\n\nIn your top level build.gradle file, you should have at least:\n\n```gradle\nbuildscript {\n    ext.kotlin_version = \"1.6.0\"\n    repositories {\n        google()\n        jcenter()\n        maven { url 'https://oss.sonatype.org/content/repositories/snapshots/' }\n    }\n    dependencies {\n        classpath \"com.android.tools.build:gradle:7.0.3\"\n        classpath \"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version\"\n    }\n}\n\nallprojects {\n    repositories {\n        google()\n        jcenter()\n        maven { url 'https://jitpack.io' }\n    }\n}\n```\n\nAnd for your app module build.gradle you should at least include:\n\n```gradle\n implementation 'org.matrix.android:matrix-android-sdk2:x.y.z'\n```\n\nreplace `x.y.z` by the latest version: ![Latest version](https://img.shields.io/maven-central/v/org.matrix.android/matrix-android-sdk2)\n\n## AndroidManifest.xml file\n\nYour application should at least contains the provider \"InitializationProvider\" to remove initialiwation of the WorkManager as below\n\n```xml\n\u003capplication\n        android:allowBackup=\"true\"\n        android:icon=\"@mipmap/ic_launcher\"\n        android:name=\".SampleApp\"\n        android:label=\"@string/app_name\"\n        android:roundIcon=\"@mipmap/ic_launcher_round\"\n        android:supportsRtl=\"true\"\n        android:theme=\"@style/AppTheme\"\u003e\n\n        [...]\n\n        // This is required as the WorkManager is already initialized by the SDK\n        \u003cprovider\n            android:name=\"androidx.startup.InitializationProvider\"\n            android:authorities=\"${applicationId}.androidx-startup\"\n            android:exported=\"false\"\n            tools:ignore=\"MissingClass\"\n            tools:node=\"merge\"\u003e\n            \u003cmeta-data\n                android:name=\"androidx.work.WorkManagerInitializer\"\n                android:value=\"androidx.startup\"\n                tools:node=\"remove\" /\u003e\n        \u003c/provider\u003e\n\n    \u003c/application\u003e\n\n```\n\n## Code\n\nPlease have a look in the following files to know how to start using the sdk:\n\n[SampleApp](app/src/main/java/org/matrix/android/sdk/sample/SampleApp.kt)\n\n[Login](/app/src/main/java/org/matrix/android/sdk/sample/ui/SimpleLoginFragment.kt)\n\n[RoomList](/app/src/main/java/org/matrix/android/sdk/sample/ui/RoomListFragment.kt)\n\n[RoomDetail](/app/src/main/java/org/matrix/android/sdk/sample/ui/RoomDetailFragment.kt)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatrix-org%2Fmatrix-android-sdk2-sample","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmatrix-org%2Fmatrix-android-sdk2-sample","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatrix-org%2Fmatrix-android-sdk2-sample/lists"}