package com.vtrbtf.minibank;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

@RestController
public class Controller {
    private Map<String, Account> storage = new HashMap<>();

    @GetMapping("/account/{owner}")
    public Account GETOwner(@PathVariable String owner) {
        return storage.get(owner);
    }

    @PostMapping("/account")
    public Account POSTOwner(@RequestBody Account account) {
        return storage.put(account.getOwner(), account);
    }
}

@@ -538,11 +538,12 @@
 unt 
-GET
+load
 Owne
@@ -646,39 +646,293 @@
 ount
-%22)%0A    public Account POSTOwner
+/%7Bowner%7D/transaction%22)%0A    public Transaction addTransaction(@PathVariable String owner, @RequestBody Transaction transaction) %7B%0A        storage.get(owner).getTransactions().add(transaction);%0A        return transaction;%0A    %7D%0A%0A    @PostMapping(%22/account%22)%0A    public Account addAccount
 (@Re

Add transaction dummy endpoint