One decision
A unit test checks one small piece of code in isolation. An integration test checks that two or more parts work together, like route plus database query, or service plus payment client wrapper.
The point is not to write the most tests. The point is to choose the cheapest test that gives real confidence.
Use unit when
Pick a unit test when the behaviour lives inside one function, class, or module. Good examples are price calculation, input validation, sorting, formatting, permission checks, and date logic.