Thought I would add to this since I've seen this question a couple of times. Even if you use only one specific function on a cheat, lets just say ESP, you still injected the cheat as a whole. As @

said above, if the cheat gets detected, it doesn't matter if you only used ESP, you will still get banned.
But even if the cheat you use (in theory) has never been or will be detected, it doesn't make you immune to getting banned. Blatant hacking vs ttv users, high K/D ratio, etc. will be red flags that could get you a manual ban.
Lastly, delay bans do exist. If you used a cheat for just one hour and never used it again, you could still be subject to a delayed ban that could come weeks to months (not sure exactly how long) later.