Skip to content

Bank Accounts

José Antonio Córdoba Gómez edited this page Jan 8, 2021 · 3 revisions

Core Microservice: Accounts

POST /account

Postman Request-Response

0

Curl Request

curl --location --request POST 'http://127.0.0.1:3031/accounts/' \
--header 'Content-Type: application/json' \
--data-raw '{
    "id": "999f7f66abf88ee70243988",
    "swift": "BSCHESMMXXX",
    "iban": "ES32668805111122223334",
    "created_at": "2020-07-08T22:18:00",
    "status": true
}'
Server Side

Console log

cloudbanking-account    | INFO 2021-01-08 17:57:53.276: [POST] /account/ received -> add_accounts_handler
cloudbanking-account    | INFO 2021-01-08 17:57:53.276: Bank account added successfully

GET /account/{id}

Postman Request-Response

1

Curl Request

curl --location --request GET 'http://127.0.0.1:3031/accounts/999f7f66abf88ee70243988'
Server Side

Console log

cloudbanking-account    | INFO 2021-01-08 18:01:47.647: [Get] /account/:id received -> get_accounts_handler
cloudbanking-account    | INFO 2021-01-08 18:01:47.647: User returned successfully
cloudbanking-account    | ok

DELETE /account/{id}

Postman Request-Response

2

Curl Request

curl --location --request DELETE 'http://127.0.0.1:3031/accounts/999f7f66abf88ee70243988'
Server Side

Console log

cloudbanking-account    | INFO 2021-01-08 18:02:34.480: [DELETE] /account/ received -> delete_accounts_handler
cloudbanking-account    | INFO 2021-01-08 18:02:34.480: Bank account deleted successfully
Clone this wiki locally