def get_archive_link(self, archive_format, ref=github.GithubObject.NotSet):
assert isinstance(archive_format, (str, unicode)), archive_format<EOL>assert ref is github.GithubObject.NotSet or isinstance(ref, (str, unicode)), ref<EOL>url = self.url + "<STR_LIT:/>" + archive_format<EOL>if ref is not github.GithubObject.NotSet:<EOL><INDENT>url += "<STR_LIT:/>" + ref<EOL><DEDENT>headers, data = self._requester.requestJsonAndCheck(<EOL>"<STR_LIT:GET>",<EOL>url<EOL>)<EOL>return headers["<STR_LIT:location>"]<EOL>
:calls: `GET /repos/:owner/:repo/:archive_format/:ref <http://developer.github.com/v3/repos/contents>`_
:param archive_format: string
:param ref: string
:rtype: string