use API method to get directory name