Developer SDK

Kotlin examples

Install the SDK · View source on GitHub ↗

Kotlin SDK installation

Kotlin/JVM consumes sdk/java; sdk/kotlin/Makefile delegates to it. Android uses gomobile. There is no separate Kotlin/Native or Kotlin Multiplatform runtime.

Publication status: new package coordinates below describe the intended public release. They are not yet all published. Build the local package while publication is being prepared.

Install with the native package manager

implementation("io.ur:urnetwork-sdk:<version>")

For Android use implementation("io.ur:urnetwork-sdk-android:"). Add mavenCentral() to Gradle repositories. Desktop Java and Kotlin share one JAR.

Supported platforms

JVM and Android support follows the Java guide. Run blocking socket calls on Dispatchers.IO, and close the socket to cancel an in-progress native read.

GitHub and local builds

Clone sdk and run make -C sdk/kotlin (desktop) or make -C sdk/kotlin package-android (already-built AAR). Consume the staged Maven artifacts locally.

Examples

  • Integration: service provisioning, scoped client credentials and Device lifecycle.
  • Sockets: TCP/UDP, TLS/DTLS and HTTP client adapters.
  • Messages: live peer discovery and interoperable text/ACK exchange.

Apps use URNETWORK_CLIENT_JWT and a persisted URNETWORK_INSTANCE_ID; only the service backend holds URNETWORK_ROOT_JWT. See the shared contract and official networking research.

Use an SDK release containing the required APIs. The package plan records package names, build outputs and publication gates.

References