async def get_image_manifest(self, image, tag):
        """
        Checks whether the image exists in the registry.

        If the container repository doesn't exist create the repository.

        The container repository name may not be the same as the BinderHub image name.

        E.g. Oracle Container Registry (OCIR) has the form:
        OCIR_NAMESPACE/OCIR_REPOSITORY_NAME:TAG

        These extra components are handled automatically by the registry helper
        so BinderHub repository names such as OCIR_NAMESPACE/OCIR_REPOSITORY_NAME
        can be used directly, it is not necessary to remove the extra components.

        Returns the image manifest if the image exists, otherwise None
        """

        repo_url = f"/repo/{image}"
        self.log.debug(f"Checking whether repository exists: {repo_url}")
        try:
            repo_json = await self._request(repo_url)
        except httpclient.HTTPError as e:
            if e.code == 404:
                repo_json = None
            else:
                raise

        if repo_json:
            return await self._get_image(image, tag)
        else:
            self.log.debug(f"Creating repository: {repo_url}")
            await self._request(repo_url, method="POST", body="")
            return None

        Checks whether the image exists in the registry.

        If the container repository doesn't exist create the repository.

        The container repository name may not be the same as the BinderHub image name.

        E.g. Oracle Container Registry (OCIR) has the form:
        OCIR_NAMESPACE/OCIR_REPOSITORY_NAME:TAG

        These extra components are handled automatically by the registry helper
        so BinderHub repository names such as OCIR_NAMESPACE/OCIR_REPOSITORY_NAME
        can be used directly, it is not necessary to remove the extra components.

        Returns the image manifest if the image exists, otherwise None
        
binderhub/registry.py