8000 Redo Consumer Workbench App (and deprecate standalone UI app) by jhaven-stytch · Pull Request #304 · stytchauth/stytch-android · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Redo Consumer Workbench App (and deprecate standalone UI app) #304

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
May 15, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions .github/workflows/autopublish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@ jobs:
cache: 'gradle'
- name: Get current version
id: version
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'
run: |
VERSION=$(./gradlew -q printVersion)
echo "Found version $VERSION"
Expand All @@ -55,9 +52,6 @@ jobs:
needs: check
if: needs.check.outputs.tag_exists == 'false'
runs-on: ubuntu-latest
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,7 @@ jobs:
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
run: |
echo "Run, Build Application using script"
./gradlew --no-daemon assemble
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'
./gradlew --no-daemon :source:sdk:assemble

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/dependency-submission.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ jobs:
build-scan-publish: true
build-scan-terms-of-use-url: "https://gradle.com/help/legal-terms-of-use"
build-scan-terms-of-use-agree: "yes"
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'

# Exclude all dependencies that originate solely in the following projects
DEPENDENCY_GRAPH_EXCLUDE_PROJECTS: ':workbench-apps:consumer-workbench|:workbench-apps:b2b-workbench|:workbench-apps:uiworkbench|:example-apps:stytchexampleapp'
3 changes: 0 additions & 3 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ jobs:
publish:
name: Release build and publish
runs-on: ubuntu-latest
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/runOnGithub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ jobs:
- uses: gradle/gradle-build-action@v2.4.2
with:
arguments: runOnGitHub
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'

- name: Add coverage to PR
id: jacoco
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/uiTests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,3 @@ jobs:
script: ./gradlew :source:sdk:connectedCheck
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'
3 changes: 0 additions & 3 deletions .github/workflows/versionedDocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@ jobs:
distribution: zulu
java-version: 17
- name: Generate docs
env:
GOOGLE_OAUTH_CLIENT_ID: 'abc123'
PASSKEYS_DOMAIN: 'abc123'
working-directory: main
run: ./gradlew dokkaHtmlMultiModule

Expand Down
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,11 +155,15 @@ This repository is organized in three main parts:
* **example-apps/** - These are two example apps (one in Kotlin, one in Java), demonstrating realistic use cases of the Stytch SDK, using both the Headless and Pre-Built UI implementations. Feel free to copy these projects and edit them to suit your needs
* **source/sdk/** - This is the actual source code of the Stytch Android SDK

If you wish to run any of the example or workbench apps from within this repository, you should add some, or all, of the following properties to your `local.properties` file:
* **GOOGLE_OAUTH_CLIENT_ID** - A Google OAuth client ID, created in your Google Console (linked to `com.stytch.exampleapp`) and added to your Stytch Dashboard, used in the consumer workbench app for testing Google One Tap
* **PASSKEYS_DOMAIN** - The domain where you host your `/.well-known/assetlinks.json` file, used in the consumer workbench app to test Passkeys flows

If you do not add these properties, the applications should still build, but will not function as expected.
For both the example apps and the workbench apps, you should consider them the same as if you were configuring your own custom app, and follow the setup instructions from above in regards to adding a string resource containing your `STYTCH_PUBLIC_TOKEN`. The `consumer-workbench` app also accepts the two following additional string resources:
1. `PASSKEYS_DOMAIN` - for associating the workbench app with a domain on which you host your `.well-known/assetlinks.json` file
2. `GOOGLE_CLIENT_ID` - for configuring Google OneTap

In order to run these example and workbench apps, you will need to set the following allowed Application IDs in your Stytch Dashboard:
* **example-apps/javademoapp:** `com.stytch.javademoapp`
* **example-apps/stytchexampleapp:** `com.stytch.stytchexampleapp`
* **workbench-apps/b2b-workbench:** `com.stytch.exampleapp.b2b`
* **workbench-apps/stytchexampleapp:** `com.stytch.exampleapp`

## Get Help And Join The Community
Join the discussion, ask questions, and suggest new features in our ​[Slack community](https://stytch.com/docs/resources/support/overview)!
Expand Down
21 changes: 0 additions & 21 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import java.util.Properties

buildscript {
dependencies {
classpath(libs.gradle)
Expand Down Expand Up @@ -93,22 +91,3 @@ tasks.register("runOnGitHub") {
tasks.dokkaHtmlMultiModule.configure {
outputDirectory.set(file("$projectDir/docs"))
}

// Create variables with empty default values
extra["GOOGLE_OAUTH_CLIENT_ID"] = ""
extra["PASSKEYS_DOMAIN"] = ""

val localProperties = project.rootProject.file("local.properties")
if (localProperties.exists()) {
val p = Properties()
localProperties.inputStream().use {
p.load(it)
}
p.forEach { name, value ->
extra[name as String] = value as String
}
} else {
// Use envvars
extra["GOOGLE_OAUTH_CLIENT_ID"] = System.getenv("GOOGLE_OAUTH_CLIENT_ID")
extra["PASSKEYS_DOMAIN"] = System.getenv("PASSKEYS_DOMAIN")
}
1 change: 0 additions & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ rootProject.name = "Stytch Android SDK"
include(":source:sdk")
include(":workbench-apps:consumer-workbench")
include(":workbench-apps:b2b-workbench")
include(":workbench-apps:uiworkbench")
include(":example-apps:stytchexampleapp")
include(":example-apps:javademoapp")

Expand Down
10 changes: 2 additions & 8 deletions workbench-apps/consumer-workbench/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ plugins {
alias(libs.plugins.androidApplication)
kotlin("android")
alias(libs.plugins.kotlinPluginCompose)
alias(libs.plugins.serialization)
}

android {
Expand All @@ -23,13 +24,6 @@ android {
}

buildTypes {
all {
val googleOAuthClientId = rootProject.ext["GOOGLE_OAUTH_CLIENT_ID"] as String
buildConfigField("String", "GOOGLE_OAUTH_CLIENT_ID", "\"$googleOAuthClientId\"")

val passkeysDomain = rootProject.ext["PASSKEYS_DOMAIN"] as String
buildConfigField("String", "PASSKEYS_DOMAIN", "\"$passkeysDomain\"")
}
release {
isMinifyEnabled = false
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro")
Expand Down Expand Up @@ -57,11 +51,11 @@ dependencies {
implementation(libs.biometric.ktx)
implementation(libs.core.ktx)
implementation(libs.appcompat)
implementation(libs.compose.material)
implementation(libs.play.services.auth.api.phone)
testImplementation(libs.junit)
androidTestImplementation(libs.androidx.junit)
androidTestImplementation(libs.androidx.espresso.core)
implementation(libs.serialization)

debugImplementation(libs.leakCanary)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@
<category android:name="android.intent.category.BROWSABLE" />
<data
android:scheme="app"
android:host="consumerworkbench"
android:pathPrefix="/" />
android:host="consumerworkbench" />
</intent-filter>
</activity>
</application>
Expand Down

This file was deleted.

Loading
Loading
0