Activity Diagram for the ATM System

An activity diagram is a great way to visualize the flow of messages from one activity to the other in the system. There can be different activity diagrams that we can create for our ATM. In this lesson, we will create activity diagrams for the following two activities:

  • The cardholder performs ATM transactions.

  • Activity challenge: The cardholder performs an ATM cash withdrawal.

The cardholder performs ATM transactions

The followings are the states and actions that will be involved in this activity diagram.


Initial state: The cardholder inserts an ATM card.

Final state: There are two final states in this activity diagram as shown below:

  • The cardholder gets an error message for the wrong ATM PIN.

  • The cardholder performs a transaction successfully.


The cardholder approaches the ATM, inserts their card, and enters their PIN. If the PIN is correct, they are allowed to perform a transaction. If the PIN is incorrect, the ATM returns the card. The cardholder then has the option to select from four different transactions. After completing their chosen transaction, the cardholder receives their card back from the ATM.

Based on the order above, the activity diagram is given below.

Level up your interview prep. Join Educative to access 70+ hands-on prep courses.