ScheduledTransactionService
public struct ScheduledTransactionService
Provides access to scheduled transaction operations
-
scheduledTransaction(budgetId:AsynchronoustransactionId: ) Returns a single scheduled transaction for a budget.
Declaration
Swift
public func scheduledTransaction( budgetId: String, transactionId: String ) async throws -> ScheduledTransactionDetailParameters
budgetIdThe id of the budget (last_used can also be used to specify the last used budget).
transactionIdId of the transaction.
Return Value
A single scheduled transaction
-
Returns all scheduled transactions for a budget.
Declaration
Swift
public func scheduledTransactions( budgetId: String, lastKnowledgeOfServer: ServerKnowledge? = nil ) async throws -> ([ScheduledTransactionDetail], ServerKnowledge)Parameters
budgetIdThe id of the budget (last_used can also be used to specify the last used budget).
lastKnowledgeOfServerThe starting server knowledge. If provided, only entities that have changed since
lastKnowledgeOfServerwill be included.Return Value
A tuple containing a list of scheduled transactions and server knowledge
-
createScheduledTransaction(budgetId:Asynchronoustransaction: ) Creates a new scheduled transaction.
Declaration
Swift
public func createScheduledTransaction( budgetId: String, transaction: SaveScheduledTransaction ) async throws -> ScheduledTransactionDetailParameters
budgetIdThe id of the budget (last_used can also be used to specify the last used budget)
transactionThe scheduled transaction data to create
Return Value
The created scheduled transaction
-
Updates an existing scheduled transaction.
Declaration
Swift
public func updateScheduledTransaction( budgetId: String, transactionId _: String, transaction: SaveScheduledTransaction ) async throws -> ScheduledTransactionDetailParameters
budgetIdThe id of the budget (last_used can also be used to specify the last used budget)
transactionIdThe id of the scheduled transaction to update
transactionThe updated scheduled transaction data
Return Value
The updated scheduled transaction
-
deleteScheduledTransaction(budgetId:AsynchronoustransactionId: ) Deletes a scheduled transaction.
Declaration
Swift
public func deleteScheduledTransaction( budgetId: String, transactionId: String ) async throws -> ScheduledTransactionDetailParameters
budgetIdThe id of the budget (last_used can also be used to specify the last used budget)
transactionIdThe id of the scheduled transaction to delete
Return Value
The deleted scheduled transaction
View on GitHub