Code Monkey home page Code Monkey logo

atmapi's Introduction

ATM (Automatated Teller Machine) API

ATM API is a backend service API for ATM which can used to perform different banking transactions. It uses H2 database with its default credentials as Username: "sa" and password = ""

This API can be used to perform following functionalities:

  1. Create accounts (Accept sufficient attributes required to create the user account)
  2. Cash deposits (Based on user account details users can deposit amounts from their bank account)
  3. Cash withdrawals (Based on user account details users can withdraw amounts from their bank account)
  4. Balance enquiry (Check Balance)

Creating an Account

To create an account, the following URL and sample JSON object can be used. Make sure to follow certain rules while creating an account (Minimum balance: 1000, Pin should be 4 digit).

URL : https://localhost:8080/atm/createaccount
JSON Object : {"accountNumber":"105", "accountName":"icici", "pin":"1234","balance":"1500"}

Generating an OTP

To perform any of those functionalities (except Account Creation), the user will have to generate a one time password. This can be done by using following sample URL:

https://localhost:8080/atm/getotp and following sample JSON object:

{ "accountNumber":"105", "accountName":"icici", "pin":"1234" }

Performing other Functionalities

Once an OTP is generated (let it be 9815 for instance), the user can perform following functionalities using URLS mentioned besides them:

  1. Cash deposits : https://localhost:8080/atm/deposit/9815/105/200 in the form of - "/deposit/{otp}/{accountnumber}/{amount}"
  2. Cash withdrawals : https://localhost:8080/atm/withdraw/9815/105/200 in the form of - "/withdraw/{otp}/{accountnumber}/{amount}"
  3. Balance enquiry : https://localhost:8080/atm/checkbalance/9815/105 in the form of - "/checkbalance/{otp}/{accountnumber}"

atmapi's People

Contributors

pankushkapoor avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.