Hello Selassie,
The agreement is the only legal document that shows each party's responsibilities, rights, and entitlements. It is the only proof of the transaction and should not be seen as an option. It is a must, and kindly ensure that it is detailed enough to capture amongst other things;
- The developer's duties and responsibilities
- The cost of the job and a receipt showing that they have been fully paid for their services
- After sales support
- Caveat on trademark ownership and patenting
In addition to the legal document/contract, also ensure that they give you access to all back office (CPanel) files which will enable you to run updates, etc.
You do not want to have issues of claims in the future from the developers when your app becomes successful.
Good luck.