WalletProvisioningRepository
public struct WalletProvisioningRepository : WalletProvisioningRepositoryProtocol
A concrete implementation of the WalletProvisioningRepositoryProtocol
that communicates with the network.
-
Initializes the
WalletProvisioningRepository
with the specified networking client.Declaration
Swift
public init(networkingClient: EPINetworkingClientProtocol)
Parameters
networkingClient
The networking client to use for network requests.
-
Creates a wallet provisioning for the specified wallet ID with the given payload.
Declaration
Swift
public func createWalletProvisioning( walletId: String, payload: CreateWalletProvisioningPayload ) -> AnyPublisher<Provisioning, NetworkError>
Parameters
walletId
The ID of the wallet for which to create the provisioning.
payload
The payload containing the details of the provisioning to create.
Return Value
A publisher that emits the created
Provisioning
or an error of typeNetworkError
. -
Retrieves the wallet provisioning with the specified IDs.
Declaration
Swift
public func fetchWalletProvisioning( walletId: String, provisioningId: String ) -> AnyPublisher<Provisioning, NetworkError>
Parameters
walletId
The ID of the wallet associated with the provisioning.
provisioningId
The ID of the provisioning to retrieve.
Return Value
A publisher that emits the retrieved
Provisioning
or an error of typeNetworkError
. -
Retrieves all wallet provisionings for the specified wallet ID.
Declaration
Swift
public func fetchWalletProvisionings(walletId: String) -> AnyPublisher<AllProvisioningsResponse, NetworkError>
Parameters
walletId
The ID of the wallet for which to retrieve the provisionings.
Return Value
A publisher that emits the retrieved
AllProvisioningsResponse
or an error of typeNetworkError
.