SPB Git

spb/os-vault Public

Self-custody, multi-chain crypto wallet for macOS. One recovery phrase, six chain families, zero API keys — nothing leaves your Mac.

Swift 96% Shell 3.4% Makefile 0.6%
587 B · 24 lines swift
Raw Blame History
1import Foundation23public protocol TokenRepository {4    /// Get specific token.5    func get(address: String) async throws -> TokenMetadata?67    func get(addresses: [String]) async throws -> [String: TokenMetadata]89    /// Get all tokens10    func all() async throws -> [String: TokenMetadata]1112    /// Prepare function13    func setup() async throws1415    /// Method to reset service16    func reset() async throws17}1819public extension TokenRepository {20    func get(address: PublicKey) async throws -> TokenMetadata? {21        try await get(address: address.base58EncodedString)22    }23}24