@Override
  public ProjectResultReport postRepositoryProject(
      RepositoryProjectExecutionRequest request, boolean async, HttpBasicAuth auth)
      throws ApiException {
    setAuthentication(auth);
    List<Pair> queryParams =
        buildQueryParameters(
            async, request.getTestCaseName(), request.getTestSuiteName(), request.getEnvironment());
    queryParams.add(new Pair("projectFileName", request.getProjectFileName()));
    if (request.getRepositoryName() != null) {
      queryParams.add(new Pair("repositoryName", request.getRepositoryName()));
    }

    return invokeAPI(
        ServerDefaults.SERVICE_BASE_PATH + "/executions/project",
        POST.name(),
        request.getCustomPropertiesMap().values(),
        "application/json",
        queryParams,
        null);
  }
 /**
  * @param environmentName (optional) Name of the environment (defined in project) if project has
  *     multiple environments defined and request is to execute for a particular environment
  * @return
  */
 public Builder forEnvironment(String environmentName) {
   projectExecutionRequest.environment = environmentName;
   return this;
 }
 /**
  * @param testCaseName (optional) Name of the test case if specific test case needs to be run.
  * @return
  */
 public Builder forTestCase(String testCaseName) {
   projectExecutionRequest.testCaseName = testCaseName;
   return this;
 }
 /**
  * @param repositoryName (optional) name of the repository on TestServer. Default repository
  *     will be used if repository name is not provided. TestServer will return with error code
  *     if rpository name is not provided and default repository doesn't exist.
  * @return Builder
  */
 public Builder fromRepository(String repositoryName) {
   projectExecutionRequest.repositoryName = repositoryName;
   return this;
 }
 /**
  * @param projectFileName (mandatory) name of the project file in repository
  * @return Builder
  */
 public Builder forProject(String projectFileName) {
   projectExecutionRequest.projectFileName = projectFileName;
   return this;
 }