CredentialOrganization
Combined credential organization capabilities for wallets that support both collections and tagging.
Extends CredentialCollections and CredentialTagging so wallets can implement a single interface to provide both capabilities. Code that only needs one capability should prefer the narrower interface.
Example Usage:
val wallet: Wallet = createWallet()
// Use narrower interface when possible
if (wallet is CredentialCollections) {
val collectionId = wallet.createCollection("My Credentials", "Personal credentials")
wallet.addToCollection(credentialId, collectionId)
}
if (wallet is CredentialTagging) {
wallet.tagCredential(credentialId, setOf("important", "verified"))
wallet.addMetadata(credentialId, mapOf("source" to "issuer.com"))
}
// Or use CredentialOrganization for full access
if (wallet is CredentialOrganization) {
wallet.createCollection("My Credentials")
wallet.tagCredential(credentialId, setOf("important"))
}Content copied to clipboard
Functions
Link copied to clipboard
Link copied to clipboard
Add a credential to a collection.
Link copied to clipboard
Create a new credential collection.
Link copied to clipboard
Delete a collection.
Link copied to clipboard
Find credentials by tag.
Link copied to clipboard
Get all tags used in the wallet.
Link copied to clipboard
Get a collection by ID.
Link copied to clipboard
Get all credentials in a collection.
Link copied to clipboard
Get metadata for a credential.
Link copied to clipboard
List all collections.
Link copied to clipboard
Remove a credential from a collection.
Link copied to clipboard
Add tags to a credential.
Link copied to clipboard
Remove tags from a credential.
Link copied to clipboard
Update notes for a credential.