is there a way to get section(unit) address
Do you mean the url to a particular section within a course?
Yes - https://www.yourmoodle.com/course/view.php?id=2#section-4
Where 2 is the course ID and 4 is the fourth section in that course.
Thank you