VGS Show Android SDK allows you to securely reveal data for your users without having to have that data pass through your systems. It provides customizable UI elements for showing users' sensitive data securely on Android devices.
| Dependency | Version |
|---|---|
| Min SDK | 21 |
| Target SDK | 34 |
| org.jetbrains.kotlin:kotlin-gradle-plugin | 1.9.22 |
| androidx.appcompat:appcompat | 1.6.1 |
| com.squareup.okhttp3:okhttp | 4.12.0 |
- VGSShow SDK - provides an API for interacting with the VGS Vault
- app - sample application to act as the host app for testing the SDK during development
This repository ships a public AI skill at skills/vgs-show-android-guide/SKILL.md for teams integrating VGSShowSDK into Android applications.
Recommended: install the skill with skills.sh. This is the easiest way to give a compatible AI agent repository-specific guidance for VGSShowSDK integration work.
The installed skill bundle includes references/AGENTS.md, which is the canonical durable integration guide for this SDK.
What the skill is useful for:
- matching guidance to the installed
vgsshowversion when that version can be detected - steering integrations toward correct secure view setup (
VGSTextView,VGSPDFView,VGSImageView) and request/reveal flows - enforcing non-empty vault configuration and correct environment selection
- preserving redaction-safe logging and analytics toggling guidance
- following upgrade and testing rules in
references/AGENTS.md
Install the skill with skills.sh:
npx skills add https://github.com/verygoodsecurity/vgs-show-android --skill vgs-show-android-guideIf your AI tool does not support skills yet, load skills/vgs-show-android-guide/references/AGENTS.md directly.
You are an autonomous engineering agent integrating the VGS Show Android SDK into an existing Kotlin app.
Use skills/vgs-show-android-guide/references/AGENTS.md as the authoritative policy.
Constraints:
- Only public, non-deprecated APIs.
- No raw sensitive data in logs/tests.
- Securely display sensitive data.
Goals:
1. Add a secure VGSTextView to display sensitive data and a VGSImageView to display a sensitive image.
2. Add redacted logging for all revealed data.
3. Provide unit tests for revealing and displaying data.
Return: Modified Kotlin source files only, no secrets.
Task: Add a VGSTextView to display a credit card number with a custom redaction format.
Follow skills/vgs-show-android-guide/references/AGENTS.md.
Do not break existing secure views; add tests for redaction and display.
For integration you need to install the Android Studio and a JDK on your machine.
|
Integrate the VGS Show SDK to your project. If you are using Maven, add the following to your build.gradle file.
|
|
dependencies {
implementation "androidx.appcompat:appcompat:<version>"
implementation "com.google.android.material:material:<version>"
implementation "com.verygoodsecurity:vgsshow:<version>"
} |
|
Add secure views to R.layout.activity_main layout file .
|
|
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<com.verygoodsecurity.vgsshow.widget.VGSTextView
android:id="@+id/infoField"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:contentPath="<CONTENT_PATH>"
app:gravity="center"
app:textColor="@android:color/black"
app:textStyle="bold" >
</com.verygoodsecurity.vgsshow.widget.VGSTextView>
<com.verygoodsecurity.vgsshow.widget.VGSImageView
android:id="@+id/imageView"
android:layout_width="match_parent"
android:layout_height="200dp"
app:contentPath="<CONTENT_PATH_TO_IMAGE>" />
</LinearLayout> |
|
|
To initialize VGSShow you have to set your vault id and Environment type.
Use subscribe(VGSView) to attach secure views to VGSShow.
|
|
class MainActivity : AppCompatActivity() {
private lateinit var vgsShow: VGSShow
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
vgsShow = VGSShow(this, "<VAULT_ID>", VGSEnvironment.Sandbox())
val infoField = findViewById<VGSTextView>(R.id.infoField)
vgsShow.subscribe(infoField)
val imageView = findViewById<VGSImageView>(R.id.imageView)
vgsShow.subscribe(imageView)
}
} |
|
|
Revealing Sensitive Data. Call requestAsync to reveal and send data on VGS Server.
|
|
class MainActivity : AppCompatActivity() {
private lateinit var vgsShow: VGSShow
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
vgsShow = VGSShow(this, "<VAULT_ID>", VGSEnvironment.Sandbox())
vgsShow.subscribe(findViewById<VGSTextView>(R.id.infoField))
vgsShow.subscribe(findViewById<VGSImageView>(R.id.imageView))
findViewById<Button>(R.id.revealButton)?.setOnClickListener {
vgsShow.requestAsync("/post",
VGSHttpMethod.POST,
mapOf("<FIELD_NAME>" to "<REVEAL_ALIAS>")
)
}
}
} |
|
|
Receive responses.
To retrieve response you need to implement VGSOnResponseListener.
|
|
class MainActivity : AppCompatActivity() {
private lateinit var vgsShow: VGSShow
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
vgsShow = VGSShow(this, "<VAULT_ID>", VGSEnvironment.Sandbox())
vgsShow.subscribe(findViewById<VGSTextView>(R.id.infoField))
vgsShow.subscribe(findViewById<VGSImageView>(R.id.imageView))
findViewById<Button>(R.id.revealButton)?.setOnClickListener {
vgsShow.requestAsync("/post",
VGSHttpMethod.POST,
mapOf("<FIELD_NAME>" to "<REVEAL_ALIAS>")
)
}
vgsShow.addOnResponseListener(object : VGSOnResponseListener {
override fun onResponse(response: VGSResponse) {
when(response) {
is VGSResponse.Success -> {
val code = response.code
}
is VGSResponse.Error -> {
val code = response.code
val message = response.message
}
}
}
})
}
} |
To follow VGS Show SDK updates and changes check the releases page.
VGSShow Android SDK is released under the MIT license. See LICENSE for details.
