code: async function getRepos(token, endpoint) {
    logger.debug(`getRepos(${endpoint})`);
    const opts = hostRules.find({ platform }, { token, endpoint });
    // istanbul ignore next
    if (!opts.token) {
      throw new Error('No token found for getRepos');
    }
    hostRules.update({ ...opts, platform, default: true });
    try {
      const repos = await utils.accumulateValues(
        `./rest/api/1.0/repos?permission=REPO_WRITE&state=AVAILABLE`
      );
      const result = repos.map(r => `${r.project.key.toLowerCase()}/${r.slug}`);
      logger.debug({ result }, 'result of getRepos()');
      return result;
    } catch (err) /* istanbul ignore next */ {
      logger.error({ err }, `bitbucket getRepos error`);
      throw err;
    }
  }
docs: Get all repositories that the user has access to