Function getRepositories