This uses the Dropbox Java SDK to retrieve an existing shared link for /Testing/test.txt specifically:
ListSharedLinksResult listSharedLinksResult = client.sharing()
.listSharedLinksBuilder()
.withPath("/Testing/test.txt").withDirectOnly(true)
.start();
System.out.println(listSharedLinksResult.getLinks());