Repository: hub4j/github-api
Pull request #1403 (2022-03-13 19:17:37)

- added 'RolePermission' to allow specifying custom roles
better fix for #1377, tests after this is ok-ed.

@bitwiseman didn't there used to be some way to format the code through maven? 

bitwiseman: Build output says it:

```
Error: 

Error: @@ -1162,7 +1163,7 @@ 

Error: ... (8 more lines that didn't fit) 

Error: Violations also present in: 

Error: src/main/java/org/kohsuke/github/GHTeam.java 

Error: Run 'mvn spotless:apply' to fix these violations.
````
bitwiseman: Could send a link to the documentation for the endpoint and maybe any blog post announcing the change? It would help me understand the new behavior vs the old.  

jgangemi: basically instead of just having the pre-defined roles like before, you can create your own custom role that has additional permissions. for example, i created a `developer` role at the day job that grants ppl access to dependabot alerts.

i'm trying to find the documentation for the endpoint, but i know it's listed there.
jgangemi: https://docs.github.com/en/rest/reference/teams#add-or-update-team-repository-permissions--parameters

this allows for the "custom" role to be defined and also provides the "pre-canned".
codecov[bot]: # [Codecov](https://codecov.io/gh/hub4j/github-api/pull/1403?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j) Report
> Merging [#1403](https://codecov.io/gh/hub4j/github-api/pull/1403?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j) (0f8464d) into [main](https://codecov.io/gh/hub4j/github-api/commit/583a49b30b6796d210717499e9e2636fc1a2aae0?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j) (583a49b) will **decrease** coverage by `0.04%`.
> The diff coverage is `53.57%`.

```diff
@@             Coverage Diff              @@
##               main    #1403      +/-   ##
============================================
- Coverage     78.21%   78.17%   -0.05%     
- Complexity     2071     2072       +1     
============================================
  Files           201      201              
  Lines          6339     6359      +20     
  Branches        357      359       +2     
============================================
+ Hits           4958     4971      +13     
- Misses         1172     1179       +7     
  Partials        209      209              
```


| [Impacted Files](https://codecov.io/gh/hub4j/github-api/pull/1403?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j) | Coverage Δ | |
|---|---|---|
| [src/main/java/org/kohsuke/github/GHRepository.java](https://codecov.io/gh/hub4j/github-api/pull/1403/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j#diff-c3JjL21haW4vamF2YS9vcmcva29oc3VrZS9naXRodWIvR0hSZXBvc2l0b3J5LmphdmE=) | `66.87% <33.33%> (-1.17%)` | :arrow_down: |
| [src/main/java/org/kohsuke/github/GHTeam.java](https://codecov.io/gh/hub4j/github-api/pull/1403/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j#diff-c3JjL21haW4vamF2YS9vcmcva29oc3VrZS9naXRodWIvR0hUZWFtLmphdmE=) | `69.04% <57.14%> (+6.08%)` | :arrow_up: |
| [...c/main/java/org/kohsuke/github/GHOrganization.java](https://codecov.io/gh/hub4j/github-api/pull/1403/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j#diff-c3JjL21haW4vamF2YS9vcmcva29oc3VrZS9naXRodWIvR0hPcmdhbml6YXRpb24uamF2YQ==) | `66.20% <100.00%> (+1.45%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/hub4j/github-api/pull/1403?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/hub4j/github-api/pull/1403?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j). Last update [583a49b...0f8464d](https://codecov.io/gh/hub4j/github-api/pull/1403?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=hub4j).

jgangemi: @bitwiseman do you want me to work those coverage numbers up or is this good to go?
jgangemi: @bitwiseman ping :)

Patch:
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 47e969ded..5192c47bb 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -1,5 +1,15 @@
 # Contributing
 
+## Make sure it's spotless
+
+Run `mvn spotless:apply` to fix any formatting, etc issues.
+
+## Make sure you pass CI
+
+If the following does not succeed, you will not pass the pull request checks.
+
+`mvn -D enable-ci clean install site` 
+
 ## Using WireMock and Snapshots
 
 This project has started converting to using WireMock to stub out http responses instead of use live data.
diff --git a/src/main/java/org/kohsuke/github/GHOrganization.java b/src/main/java/org/kohsuke/github/GHOrganization.java
index d69028570..90d0bba0c 100644
--- a/src/main/java/org/kohsuke/github/GHOrganization.java
+++ b/src/main/java/org/kohsuke/github/GHOrganization.java
@@ -86,7 +86,6 @@ public class GHOrganization extends GHPerson {
 
     /**
      * Starts a builder that creates a new repository.
-     *
      * <p>
      * You use the returned builder to set various properties, then call {@link GHCreateRepositoryBuilder#create()} to
      * finally create a repository.
@@ -135,7 +134,6 @@ public class GHOrganization extends GHPerson {
      * @return the team
      * @throws IOException
      *             the io exception
-     *
      * @deprecated Use {@link GHOrganization#getTeam(long)}
      */
     @Deprecated
@@ -151,7 +149,6 @@ public class GHOrganization extends GHPerson {
      * @return the team
      * @throws IOException
      *             the io exception
-     *
      * @see <a href= "https://developer.github.com/v3/teams/#get-team-by-name">documentation</a>
      */
     public GHTeam getTeam(long teamId) throws IOException {
@@ -449,11 +446,37 @@ public class GHOrganization extends GHPerson {
 
     /**
      * The enum Permission.
+     *
+     * @see RepositoryRole
      */
     public enum Permission {
         ADMIN, MAINTAIN, PUSH, TRIAGE, PULL
     }
 
+    /**
+     * Repository permissions (roles) for teams and collaborators.
+     */
+    public static class RepositoryRole {
+        private final String permission;
+
+        private RepositoryRole(String permission) {
+            this.permission = permission;
+        }
+
+        public static RepositoryRole custom(String permission) {
+            return new RepositoryRole(permission);
+        }
+
+        public static RepositoryRole from(Permission permission) {
+            return custom(permission.toString().toLowerCase());
+        }
+
+        @Override
+        public String toString() {
+            return permission;
+        }
+    }
+
     /**
      * Creates a new team and assigns the repositories.
      *
@@ -542,7 +565,6 @@ public class GHOrganization extends GHPerson {
 
     /**
      * Starts a builder that creates a new team.
-     *
      * <p>
      * You use the returned builder to set various properties, then call {@link GHTeamBuilder#create()} to finally
      * create a team.
@@ -604,9 +626,8 @@ public class GHOrganization extends GHPerson {
      * Lists up all the repositories using the specified page size.
      *
      * @param pageSize
-     *            size for each page of items returned by GitHub. Maximum page size is 100.
-     *
-     *            Unlike {@link #getRepositories()}, this does not wait until all the repositories are returned.
+     *            size for each page of items returned by GitHub. Maximum page size is 100. Unlike
+     *            {@link #getRepositories()}, this does not wait until all the repositories are returned.
      */
     @Override
     public PagedIterable<GHRepository> listRepositories(final int pageSize) {
diff --git a/src/main/java/org/kohsuke/github/GHRepository.java b/src/main/java/org/kohsuke/github/GHRepository.java
index b97143dfb..fd38253a0 100644
--- a/src/main/java/org/kohsuke/github/GHRepository.java
+++ b/src/main/java/org/kohsuke/github/GHRepository.java
@@ -1060,14 +1060,31 @@ public class GHRepository extends GHObject {
     /**
      * Add collaborators.
      *
+     * @param permission
+     *            the permission level
      * @param users
      *            the users
+     * @throws IOException
+     *             the io exception
+     * @deprecated #addCollaborators(GHOrganization.RolePermission, GHUser)
+     */
+    @Deprecated
+    public void addCollaborators(GHOrganization.Permission permission, GHUser... users) throws IOException {
+        addCollaborators(asList(users), permission);
+    }
+
+    /**
+     * Add collaborators.
+     *
      * @param permission
      *            the permission level
+     * @param users
+     *            the users
+     *
      * @throws IOException
      *             the io exception
      */
-    public void addCollaborators(GHOrganization.Permission permission, GHUser... users) throws IOException {
+    public void addCollaborators(GHOrganization.RepositoryRole permission, GHUser... users) throws IOException {
         addCollaborators(asList(users), permission);
     }
 
@@ -1104,8 +1121,25 @@ public class GHRepository extends GHObject {
      *            the permission level
      * @throws IOException
      *             the io exception
+     * @deprecated #addCollaborators(Collection, GHOrganization.RolePermission)
      */
+    @Deprecated
     public void addCollaborators(Collection<GHUser> users, GHOrganization.Permission permission) throws IOException {
+        modifyCollaborators(users, "PUT", GHOrganization.RepositoryRole.from(permission));
+    }
+
+    /**
+     * Add collaborators.
+     *
+     * @param users
+     *            the users
+     * @param permission
+     *            the permission level
+     * @throws IOException
+     *             the io exception
+     */
+    public void addCollaborators(Collection<GHUser> users, GHOrganization.RepositoryRole permission)
+            throws IOException {
         modifyCollaborators(users, "PUT", permission);
     }
 
@@ -1135,14 +1169,14 @@ public class GHRepository extends GHObject {
 
     private void modifyCollaborators(@NonNull Collection<GHUser> users,
             @NonNull String method,
-            @CheckForNull GHOrganization.Permission permission) throws IOException {
+            @CheckForNull GHOrganization.RepositoryRole permission) throws IOException {
         Requester requester = root().createRequest().method(method);
         if (permission != null) {
-            requester = requester.with("permission", permission).inBody();
+            requester = requester.with("permission", permission.toString()).inBody();
         }
 
         // Make sure that the users collection doesn't have any duplicates
-        for (GHUser user : new LinkedHashSet<GHUser>(users)) {
+        for (GHUser user : new LinkedHashSet<>(users)) {
             requester.withUrlPath(getApiTailUrl("collaborators/" + user.getLogin())).send();
         }
     }
@@ -1156,7 +1190,7 @@ public class GHRepository extends GHObject {
      *             the io exception
      */
     public void setEmailServiceHook(String address) throws IOException {
-        Map<String, String> config = new HashMap<String, String>();
+        Map<String, String> config = new HashMap<>();
         config.put("address", address);
         root().createRequest()
                 .method("POST")
diff --git a/src/main/java/org/kohsuke/github/GHTeam.java b/src/main/java/org/kohsuke/github/GHTeam.java
index 143f63312..054889ce4 100644
--- a/src/main/java/org/kohsuke/github/GHTeam.java
+++ b/src/main/java/org/kohsuke/github/GHTeam.java
@@ -7,6 +7,7 @@ import java.io.IOException;
 import java.net.URL;
 import java.util.Map;
 import java.util.Objects;
+import java.util.Optional;
 import java.util.Set;
 import java.util.TreeMap;
 
@@ -214,7 +215,7 @@ public class GHTeam extends GHObject implements Refreshable {
         try {
             root().createRequest().withUrlPath(api("/memberships/" + user.getLogin())).send();
             return true;
-        } catch (IOException ignore) {
+        } catch (@SuppressWarnings("unused") IOException ignore) {
             return false;
         }
     }
@@ -227,7 +228,7 @@ public class GHTeam extends GHObject implements Refreshable {
      *             the io exception
      */
     public Map<String, GHRepository> getRepositories() throws IOException {
-        Map<String, GHRepository> m = new TreeMap<String, GHRepository>();
+        Map<String, GHRepository> m = new TreeMap<>();
         for (GHRepository r : listRepositories()) {
             m.put(r.getName(), r);
         }
@@ -299,11 +300,11 @@ public class GHTeam extends GHObject implements Refreshable {
      *             the io exception
      */
     public void add(GHRepository r) throws IOException {
-        add(r, null);
+        add(r, (GHOrganization.RepositoryRole) null);
     }
 
     /**
-     * Add.
+     * * Add.
      *
      * @param r
      *            the r
@@ -311,11 +312,28 @@ public class GHTeam extends GHObject implements Refreshable {
      *            the permission
      * @throws IOException
      *             the io exception
+     * @deprecated use {@link GHTeam#add(GHRepository, org.kohsuke.github.GHOrganization.RepositoryRole)}
      */
+    @Deprecated
     public void add(GHRepository r, GHOrganization.Permission permission) throws IOException {
+        add(r, GHOrganization.RepositoryRole.from(permission));
+    }
+
+    /**
+     * Add.
+     *
+     * @param r
+     *            the r
+     * @param permission
+     *            the permission
+     * @throws IOException
+     *             the io exception
+     */
+    public void add(GHRepository r, GHOrganization.RepositoryRole permission) throws IOException {
         root().createRequest()
                 .method("PUT")
-                .with("permission", permission)
+                .with("permission",
+                        Optional.ofNullable(permission).map(GHOrganization.RepositoryRole::toString).orElse(null))
                 .withUrlPath(api("/repos/" + r.getOwnerName() + '/' + r.getName()))
                 .send();
     }


Test patch:
diff --git a/src/test/java/org/kohsuke/github/GHOrganizationTest.java b/src/test/java/org/kohsuke/github/GHOrganizationTest.java
index e7c48d714..38b7f8e96 100644
--- a/src/test/java/org/kohsuke/github/GHOrganizationTest.java
+++ b/src/test/java/org/kohsuke/github/GHOrganizationTest.java
@@ -4,6 +4,7 @@ import org.junit.After;
 import org.junit.Before;
 import org.junit.Test;
 import org.kohsuke.github.GHOrganization.Permission;
+import org.kohsuke.github.GHOrganization.RepositoryRole;
 
 import java.io.IOException;
 import java.util.List;
@@ -196,6 +197,75 @@ public class GHOrganizationTest extends AbstractGitHubWireMockTest {
         assertThat(team.getPermission(), equalTo(Permission.PUSH.toString().toLowerCase()));
     }
 
+    @Test
+    public void testCreateTeamWithNullPerm() throws Exception {
+        String REPO_NAME = "github-api";
+
+        GHOrganization org = gitHub.getOrganization(GITHUB_API_TEST_ORG);
+        GHRepository repo = org.getRepository(REPO_NAME);
+
+        // Create team with access to repository. Check access was granted.
+        GHTeam team = org.createTeam(TEAM_NAME_CREATE).create();
+
+        team.add(repo);
+
+        assertThat(
+                repo.getTeams()
+                        .stream()
+                        .filter(t -> TEAM_NAME_CREATE.equals(t.getName()))
+                        .findFirst()
+                        .get()
+                        .getPermission(),
+                equalTo(Permission.PULL.toString().toLowerCase()));
+    }
+
+    @Test
+    public void testCreateTeamWithRepoPerm() throws Exception {
+        String REPO_NAME = "github-api";
+
+        GHOrganization org = gitHub.getOrganization(GITHUB_API_TEST_ORG);
+        GHRepository repo = org.getRepository(REPO_NAME);
+
+        // Create team with access to repository. Check access was granted.
+        GHTeam team = org.createTeam(TEAM_NAME_CREATE).create();
+
+        team.add(repo, GHOrganization.Permission.PUSH);
+
+        assertThat(
+                repo.getTeams()
+                        .stream()
+                        .filter(t -> TEAM_NAME_CREATE.equals(t.getName()))
+                        .findFirst()
+                        .get()
+                        .getPermission(),
+                equalTo(Permission.PUSH.toString().toLowerCase()));
+
+    }
+
+    @Test
+    public void testCreateTeamWithRepoRole() throws IOException {
+        String REPO_NAME = "github-api";
+
+        GHOrganization org = gitHub.getOrganization(GITHUB_API_TEST_ORG);
+        GHRepository repo = org.getRepository(REPO_NAME);
+
+        // Create team with access to repository. Check access was granted.
+        GHTeam team = org.createTeam(TEAM_NAME_CREATE).create();
+
+        RepositoryRole role = RepositoryRole.from(GHOrganization.Permission.TRIAGE);
+        team.add(repo, role);
+
+        // 'getPermission' does not return triage even though the UI shows that value
+        // assertThat(
+        // repo.getTeams()
+        // .stream()
+        // .filter(t -> TEAM_NAME_CREATE.equals(t.getName()))
+        // .findFirst()
+        // .get()
+        // .getPermission(),
+        // equalTo(role.toString()));
+    }
+
     @Test
     public void testCreateTeam() throws IOException {
         String REPO_NAME = "github-api";
diff --git a/src/test/java/org/kohsuke/github/GHRepositoryTest.java b/src/test/java/org/kohsuke/github/GHRepositoryTest.java
index b214999c8..a1e3833be 100644
--- a/src/test/java/org/kohsuke/github/GHRepositoryTest.java
+++ b/src/test/java/org/kohsuke/github/GHRepositoryTest.java
@@ -4,6 +4,7 @@ import com.fasterxml.jackson.databind.JsonMappingException;
 import org.apache.commons.io.IOUtils;
 import org.junit.Test;
 import org.kohsuke.github.GHCheckRun.Conclusion;
+import org.kohsuke.github.GHOrganization.RepositoryRole;
 import org.kohsuke.github.GHRepository.Visibility;
 
 import java.io.ByteArrayInputStream;
@@ -340,19 +341,32 @@ public class GHRepositoryTest extends AbstractGitHubWireMockTest {
     public void addCollaborators() throws Exception {
         GHRepository repo = getRepository();
         GHUser user = getUser();
-        List<GHUser> users = new ArrayList<GHUser>();
+        List<GHUser> users = new ArrayList<>();
 
         users.add(user);
         users.add(gitHub.getUser("jimmysombrero2"));
         repo.addCollaborators(users, GHOrganization.Permission.PUSH);
 
         GHPersonSet<GHUser> collabs = repo.getCollaborators();
-
         GHUser colabUser = collabs.byLogin("jimmysombrero");
 
         assertThat(user.getName(), equalTo(colabUser.getName()));
     }
 
+    @Test
+    public void addCollaboratorsRepoPerm() throws Exception {
+        GHRepository repo = getRepository();
+        GHUser user = getUser();
+
+        RepositoryRole role = RepositoryRole.from(GHOrganization.Permission.PULL);
+        repo.addCollaborators(role, user);
+
+        GHPersonSet<GHUser> collabs = repo.getCollaborators();
+        GHUser colabUser = collabs.byLogin("jgangemi");
+
+        assertThat(user.getName(), equalTo(colabUser.getName()));
+    }
+
     @Test
     public void LatestRepositoryNotExist() {
         try {
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..162ceb1c7
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/orgs_hub4j-test-org-2.json
@@ -0,0 +1,55 @@
+{
+  "login": "hub4j-test-org",
+  "id": 7544739,
+  "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+  "url": "https://api.github.com/orgs/hub4j-test-org",
+  "repos_url": "https://api.github.com/orgs/hub4j-test-org/repos",
+  "events_url": "https://api.github.com/orgs/hub4j-test-org/events",
+  "hooks_url": "https://api.github.com/orgs/hub4j-test-org/hooks",
+  "issues_url": "https://api.github.com/orgs/hub4j-test-org/issues",
+  "members_url": "https://api.github.com/orgs/hub4j-test-org/members{/member}",
+  "public_members_url": "https://api.github.com/orgs/hub4j-test-org/public_members{/member}",
+  "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+  "description": "Hub4j Test Org Description (this could be null or blank too)",
+  "name": "Hub4j Test Org Name (this could be null or blank too)",
+  "company": null,
+  "blog": "https://hub4j.url.io/could/be/null",
+  "location": "Hub4j Test Org Location (this could be null or blank too)",
+  "email": "hub4jtestorgemail@could.be.null.com",
+  "twitter_username": null,
+  "is_verified": false,
+  "has_organization_projects": true,
+  "has_repository_projects": true,
+  "public_repos": 49,
+  "public_gists": 0,
+  "followers": 0,
+  "following": 0,
+  "html_url": "https://github.com/hub4j-test-org",
+  "created_at": "2014-05-10T19:39:11Z",
+  "updated_at": "2020-06-04T05:56:10Z",
+  "type": "Organization",
+  "total_private_repos": 3,
+  "owned_private_repos": 3,
+  "private_gists": 0,
+  "disk_usage": 11979,
+  "collaborators": 0,
+  "billing_email": "kk@kohsuke.org",
+  "default_repository_permission": "none",
+  "members_can_create_repositories": false,
+  "two_factor_requirement_enabled": false,
+  "members_allowed_repository_creation_type": "none",
+  "members_can_create_public_repositories": false,
+  "members_can_create_private_repositories": false,
+  "members_can_create_internal_repositories": false,
+  "members_can_create_pages": true,
+  "members_can_fork_private_repositories": false,
+  "members_can_create_public_pages": true,
+  "members_can_create_private_pages": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "private_repos": 10000,
+    "filled_seats": 35,
+    "seats": 3
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/orgs_hub4j-test-org_teams-4.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/orgs_hub4j-test-org_teams-4.json
new file mode 100644
index 000000000..86647e7f7
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/orgs_hub4j-test-org_teams-4.json
@@ -0,0 +1,49 @@
+{
+  "name": "create-team-test",
+  "id": 5898310,
+  "node_id": "T_kwDOAHMfo84AWgBG",
+  "slug": "create-team-test",
+  "description": null,
+  "privacy": "secret",
+  "url": "https://api.github.com/organizations/7544739/team/5898310",
+  "html_url": "https://github.com/orgs/hub4j-test-org/teams/create-team-test",
+  "members_url": "https://api.github.com/organizations/7544739/team/5898310/members{/member}",
+  "repositories_url": "https://api.github.com/organizations/7544739/team/5898310/repos",
+  "permission": "pull",
+  "parent": null,
+  "created_at": "2022-04-06T13:29:41Z",
+  "updated_at": "2022-04-06T13:29:41Z",
+  "members_count": 1,
+  "repos_count": 0,
+  "organization": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "url": "https://api.github.com/orgs/hub4j-test-org",
+    "repos_url": "https://api.github.com/orgs/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/orgs/hub4j-test-org/events",
+    "hooks_url": "https://api.github.com/orgs/hub4j-test-org/hooks",
+    "issues_url": "https://api.github.com/orgs/hub4j-test-org/issues",
+    "members_url": "https://api.github.com/orgs/hub4j-test-org/members{/member}",
+    "public_members_url": "https://api.github.com/orgs/hub4j-test-org/public_members{/member}",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "description": "Hub4j Test Org Description (this could be null or blank too)",
+    "name": "Hub4j Test Org Name (this could be null or blank too)",
+    "company": null,
+    "blog": "https://hub4j.url.io/could/be/null",
+    "location": "Hub4j Test Org Location (this could be null or blank too)",
+    "email": "hub4jtestorgemail@could.be.null.com",
+    "twitter_username": null,
+    "is_verified": false,
+    "has_organization_projects": true,
+    "has_repository_projects": true,
+    "public_repos": 49,
+    "public_gists": 0,
+    "followers": 0,
+    "following": 0,
+    "html_url": "https://github.com/hub4j-test-org",
+    "created_at": "2014-05-10T19:39:11Z",
+    "updated_at": "2020-06-04T05:56:10Z",
+    "type": "Organization"
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..286c9b38a
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,364 @@
+{
+  "id": 206888201,
+  "node_id": "MDEwOlJlcG9zaXRvcnkyMDY4ODgyMDE=",
+  "name": "github-api",
+  "full_name": "hub4j-test-org/github-api",
+  "private": false,
+  "owner": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "html_url": "https://github.com/hub4j-test-org/github-api",
+  "description": "Tricky",
+  "fork": true,
+  "url": "https://api.github.com/repos/hub4j-test-org/github-api",
+  "forks_url": "https://api.github.com/repos/hub4j-test-org/github-api/forks",
+  "keys_url": "https://api.github.com/repos/hub4j-test-org/github-api/keys{/key_id}",
+  "collaborators_url": "https://api.github.com/repos/hub4j-test-org/github-api/collaborators{/collaborator}",
+  "teams_url": "https://api.github.com/repos/hub4j-test-org/github-api/teams",
+  "hooks_url": "https://api.github.com/repos/hub4j-test-org/github-api/hooks",
+  "issue_events_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/events{/number}",
+  "events_url": "https://api.github.com/repos/hub4j-test-org/github-api/events",
+  "assignees_url": "https://api.github.com/repos/hub4j-test-org/github-api/assignees{/user}",
+  "branches_url": "https://api.github.com/repos/hub4j-test-org/github-api/branches{/branch}",
+  "tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/tags",
+  "blobs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/blobs{/sha}",
+  "git_tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/tags{/sha}",
+  "git_refs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/refs{/sha}",
+  "trees_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/trees{/sha}",
+  "statuses_url": "https://api.github.com/repos/hub4j-test-org/github-api/statuses/{sha}",
+  "languages_url": "https://api.github.com/repos/hub4j-test-org/github-api/languages",
+  "stargazers_url": "https://api.github.com/repos/hub4j-test-org/github-api/stargazers",
+  "contributors_url": "https://api.github.com/repos/hub4j-test-org/github-api/contributors",
+  "subscribers_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscribers",
+  "subscription_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscription",
+  "commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/commits{/sha}",
+  "git_commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/commits{/sha}",
+  "comments_url": "https://api.github.com/repos/hub4j-test-org/github-api/comments{/number}",
+  "issue_comment_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/comments{/number}",
+  "contents_url": "https://api.github.com/repos/hub4j-test-org/github-api/contents/{+path}",
+  "compare_url": "https://api.github.com/repos/hub4j-test-org/github-api/compare/{base}...{head}",
+  "merges_url": "https://api.github.com/repos/hub4j-test-org/github-api/merges",
+  "archive_url": "https://api.github.com/repos/hub4j-test-org/github-api/{archive_format}{/ref}",
+  "downloads_url": "https://api.github.com/repos/hub4j-test-org/github-api/downloads",
+  "issues_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues{/number}",
+  "pulls_url": "https://api.github.com/repos/hub4j-test-org/github-api/pulls{/number}",
+  "milestones_url": "https://api.github.com/repos/hub4j-test-org/github-api/milestones{/number}",
+  "notifications_url": "https://api.github.com/repos/hub4j-test-org/github-api/notifications{?since,all,participating}",
+  "labels_url": "https://api.github.com/repos/hub4j-test-org/github-api/labels{/name}",
+  "releases_url": "https://api.github.com/repos/hub4j-test-org/github-api/releases{/id}",
+  "deployments_url": "https://api.github.com/repos/hub4j-test-org/github-api/deployments",
+  "created_at": "2019-09-06T23:26:04Z",
+  "updated_at": "2021-11-09T20:13:29Z",
+  "pushed_at": "2022-03-04T11:02:08Z",
+  "git_url": "git://github.com/hub4j-test-org/github-api.git",
+  "ssh_url": "git@github.com:hub4j-test-org/github-api.git",
+  "clone_url": "https://github.com/hub4j-test-org/github-api.git",
+  "svn_url": "https://github.com/hub4j-test-org/github-api",
+  "homepage": "http://github-api.kohsuke.org/",
+  "size": 19045,
+  "stargazers_count": 0,
+  "watchers_count": 0,
+  "language": "Java",
+  "has_issues": true,
+  "has_projects": true,
+  "has_downloads": true,
+  "has_wiki": true,
+  "has_pages": false,
+  "forks_count": 0,
+  "mirror_url": null,
+  "archived": false,
+  "disabled": false,
+  "open_issues_count": 7,
+  "license": {
+    "key": "mit",
+    "name": "MIT License",
+    "spdx_id": "MIT",
+    "url": "https://api.github.com/licenses/mit",
+    "node_id": "MDc6TGljZW5zZTEz"
+  },
+  "allow_forking": true,
+  "is_template": false,
+  "topics": [],
+  "visibility": "public",
+  "forks": 0,
+  "open_issues": 7,
+  "watchers": 0,
+  "default_branch": "main",
+  "permissions": {
+    "admin": true,
+    "maintain": true,
+    "push": true,
+    "triage": true,
+    "pull": true
+  },
+  "temp_clone_token": "",
+  "allow_squash_merge": true,
+  "allow_merge_commit": true,
+  "allow_rebase_merge": true,
+  "allow_auto_merge": false,
+  "delete_branch_on_merge": false,
+  "allow_update_branch": false,
+  "organization": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "parent": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-04-05T15:53:55Z",
+    "pushed_at": "2022-04-06T13:21:45Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39832,
+    "stargazers_count": 878,
+    "watchers_count": 878,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 601,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 101,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 601,
+    "open_issues": 101,
+    "watchers": 878,
+    "default_branch": "main"
+  },
+  "source": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-04-05T15:53:55Z",
+    "pushed_at": "2022-04-06T13:21:45Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39832,
+    "stargazers_count": 878,
+    "watchers_count": 878,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 601,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 101,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 601,
+    "open_issues": 101,
+    "watchers": 878,
+    "default_branch": "main"
+  },
+  "network_count": 601,
+  "subscribers_count": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/repos_hub4j-test-org_github-api_teams-6.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/repos_hub4j-test-org_github-api_teams-6.json
new file mode 100644
index 000000000..3c5dd713a
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/repos_hub4j-test-org_github-api_teams-6.json
@@ -0,0 +1,86 @@
+[
+  {
+    "name": "Contributors",
+    "id": 4882699,
+    "node_id": "MDQ6VGVhbTQ4ODI2OTk=",
+    "slug": "contributors",
+    "description": "",
+    "privacy": "closed",
+    "url": "https://api.github.com/organizations/7544739/team/4882699",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/contributors",
+    "members_url": "https://api.github.com/organizations/7544739/team/4882699/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/4882699/repos",
+    "permission": "admin",
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "parent": null
+  },
+  {
+    "name": "create-team-test",
+    "id": 5898310,
+    "node_id": "T_kwDOAHMfo84AWgBG",
+    "slug": "create-team-test",
+    "description": null,
+    "privacy": "secret",
+    "url": "https://api.github.com/organizations/7544739/team/5898310",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/create-team-test",
+    "members_url": "https://api.github.com/organizations/7544739/team/5898310/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/5898310/repos",
+    "permission": "pull",
+    "permissions": {
+      "admin": false,
+      "maintain": false,
+      "push": false,
+      "triage": false,
+      "pull": true
+    },
+    "parent": null
+  },
+  {
+    "name": "dummy-team",
+    "id": 3451996,
+    "node_id": "MDQ6VGVhbTM0NTE5OTY=",
+    "slug": "dummy-team",
+    "description": "Updated by API TestModified",
+    "privacy": "closed",
+    "url": "https://api.github.com/organizations/7544739/team/3451996",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/dummy-team",
+    "members_url": "https://api.github.com/organizations/7544739/team/3451996/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/3451996/repos",
+    "permission": "push",
+    "permissions": {
+      "admin": false,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "parent": null
+  },
+  {
+    "name": "tricky-team",
+    "id": 3454508,
+    "node_id": "MDQ6VGVhbTM0NTQ1MDg=",
+    "slug": "tricky-team",
+    "description": "",
+    "privacy": "secret",
+    "url": "https://api.github.com/organizations/7544739/team/3454508",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/tricky-team",
+    "members_url": "https://api.github.com/organizations/7544739/team/3454508/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/3454508/repos",
+    "permission": "push",
+    "permissions": {
+      "admin": false,
+      "maintain": false,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "parent": null
+  }
+]
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/user-1.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/user-1.json
new file mode 100644
index 000000000..cfe0f3a0c
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/__files/user-1.json
@@ -0,0 +1,46 @@
+{
+  "login": "jgangemi",
+  "id": 1831839,
+  "node_id": "MDQ6VXNlcjE4MzE4Mzk=",
+  "avatar_url": "https://avatars.githubusercontent.com/u/1831839?v=4",
+  "gravatar_id": "",
+  "url": "https://api.github.com/users/jgangemi",
+  "html_url": "https://github.com/jgangemi",
+  "followers_url": "https://api.github.com/users/jgangemi/followers",
+  "following_url": "https://api.github.com/users/jgangemi/following{/other_user}",
+  "gists_url": "https://api.github.com/users/jgangemi/gists{/gist_id}",
+  "starred_url": "https://api.github.com/users/jgangemi/starred{/owner}{/repo}",
+  "subscriptions_url": "https://api.github.com/users/jgangemi/subscriptions",
+  "organizations_url": "https://api.github.com/users/jgangemi/orgs",
+  "repos_url": "https://api.github.com/users/jgangemi/repos",
+  "events_url": "https://api.github.com/users/jgangemi/events{/privacy}",
+  "received_events_url": "https://api.github.com/users/jgangemi/received_events",
+  "type": "User",
+  "site_admin": false,
+  "name": "Jae Gangemi",
+  "company": null,
+  "blog": "",
+  "location": null,
+  "email": null,
+  "hireable": null,
+  "bio": null,
+  "twitter_username": null,
+  "public_repos": 39,
+  "public_gists": 1,
+  "followers": 1,
+  "following": 0,
+  "created_at": "2012-06-08T19:54:02Z",
+  "updated_at": "2022-03-09T12:59:44Z",
+  "private_gists": 0,
+  "total_private_repos": 9,
+  "owned_private_repos": 9,
+  "disk_usage": 16623,
+  "collaborators": 0,
+  "two_factor_authentication": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "collaborators": 0,
+    "private_repos": 10000
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/organizations_7544739_team_5898310_repos_hub4j-test-org_github-api-5.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/organizations_7544739_team_5898310_repos_hub4j-test-org_github-api-5.json
new file mode 100644
index 000000000..96ef708e4
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/organizations_7544739_team_5898310_repos_hub4j-test-org_github-api-5.json
@@ -0,0 +1,47 @@
+{
+  "id": "dcb7a2b8-ec53-4dc9-8f53-472ac3f5fc4f",
+  "name": "organizations_7544739_team_5898310_repos_hub4j-test-org_github-api",
+  "request": {
+    "url": "/organizations/7544739/team/5898310/repos/hub4j-test-org/github-api",
+    "method": "PUT",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 204,
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:29:42 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, read:org, repo, user, write:org",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4965",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "35",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "Vary": "Accept-Encoding, Accept, X-Requested-With",
+      "X-GitHub-Request-Id": "C149:5A29:1184F01:205315A:624D95C6"
+    }
+  },
+  "uuid": "dcb7a2b8-ec53-4dc9-8f53-472ac3f5fc4f",
+  "persistent": true,
+  "insertionIndex": 5
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..4229ec863
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/orgs_hub4j-test-org-2.json
@@ -0,0 +1,48 @@
+{
+  "id": "7a68190a-3581-42f6-b990-5648ff704212",
+  "name": "orgs_hub4j-test-org",
+  "request": {
+    "url": "/orgs/hub4j-test-org",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "orgs_hub4j-test-org-2.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:29:40 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"9c48b6d97946cc9cca7a7eba9df130c47c977fea9e3ed36222d79a378e2ff6c8\"",
+      "Last-Modified": "Thu, 04 Jun 2020 05:56:10 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, read:org, repo, user, write:org",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4968",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "32",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "C144:0B54:FD88A8:1ED6A36:624D95C4"
+    }
+  },
+  "uuid": "7a68190a-3581-42f6-b990-5648ff704212",
+  "persistent": true,
+  "insertionIndex": 2
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/orgs_hub4j-test-org_teams-4.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/orgs_hub4j-test-org_teams-4.json
new file mode 100644
index 000000000..af7c93acb
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/orgs_hub4j-test-org_teams-4.json
@@ -0,0 +1,55 @@
+{
+  "id": "3ffa4da9-2cec-422d-aa3e-11c1ab5c59db",
+  "name": "orgs_hub4j-test-org_teams",
+  "request": {
+    "url": "/orgs/hub4j-test-org/teams",
+    "method": "POST",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"name\":\"create-team-test\"}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 201,
+    "bodyFileName": "orgs_hub4j-test-org_teams-4.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:29:41 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "\"c55b8f7b2a21e5ce24b0a46f885f959dd9d7ffa88197ceabe76128307779cb4a\"",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, repo",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4966",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "34",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "C148:4D1B:D01588:22CF75B:624D95C5",
+      "Location": "https://api.github.com/organizations/7544739/team/5898310"
+    }
+  },
+  "uuid": "3ffa4da9-2cec-422d-aa3e-11c1ab5c59db",
+  "persistent": true,
+  "insertionIndex": 4
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..bdd771251
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,48 @@
+{
+  "id": "dc5d6a77-89fc-4179-8ad9-f0482c251b90",
+  "name": "repos_hub4j-test-org_github-api",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repos_hub4j-test-org_github-api-3.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:29:41 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"f659ce60400fb1f0bd592ef4533029ee2aca8f3785088fc086eb3c10b2548f0f\"",
+      "Last-Modified": "Tue, 09 Nov 2021 20:13:29 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "repo",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4967",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "33",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "C147:6347:FCF879:1F165D4:624D95C4"
+    }
+  },
+  "uuid": "dc5d6a77-89fc-4179-8ad9-f0482c251b90",
+  "persistent": true,
+  "insertionIndex": 3
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/repos_hub4j-test-org_github-api_teams-6.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/repos_hub4j-test-org_github-api_teams-6.json
new file mode 100644
index 000000000..b94c470d7
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/repos_hub4j-test-org_github-api_teams-6.json
@@ -0,0 +1,47 @@
+{
+  "id": "beab6b95-c5a0-4e0d-965f-7303beebc45c",
+  "name": "repos_hub4j-test-org_github-api_teams",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api/teams",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repos_hub4j-test-org_github-api_teams-6.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:29:42 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"54dcceb0bb517b6a007876b4702f6b5fd08e302dc9b2fdb3147c4c7e1dd09cb3\"",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4964",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "36",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "C14A:54E4:10C3191:22E3B54:624D95C6"
+    }
+  },
+  "uuid": "beab6b95-c5a0-4e0d-965f-7303beebc45c",
+  "persistent": true,
+  "insertionIndex": 6
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/user-1.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/user-1.json
new file mode 100644
index 000000000..c0e368656
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithNullPerm/mappings/user-1.json
@@ -0,0 +1,48 @@
+{
+  "id": "8a923dcb-86b8-40d6-b636-5501420fbe02",
+  "name": "user",
+  "request": {
+    "url": "/user",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "user-1.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:29:38 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"65ac0e73527e3adc4df6bbbde94bb21480926587df8832f0bab8a5fc1bc746c9\"",
+      "Last-Modified": "Wed, 09 Mar 2022 12:59:44 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4973",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "27",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "C139:7D4A:F0B9DC:1DA06D1:624D95C2"
+    }
+  },
+  "uuid": "8a923dcb-86b8-40d6-b636-5501420fbe02",
+  "persistent": true,
+  "insertionIndex": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..162ceb1c7
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/orgs_hub4j-test-org-2.json
@@ -0,0 +1,55 @@
+{
+  "login": "hub4j-test-org",
+  "id": 7544739,
+  "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+  "url": "https://api.github.com/orgs/hub4j-test-org",
+  "repos_url": "https://api.github.com/orgs/hub4j-test-org/repos",
+  "events_url": "https://api.github.com/orgs/hub4j-test-org/events",
+  "hooks_url": "https://api.github.com/orgs/hub4j-test-org/hooks",
+  "issues_url": "https://api.github.com/orgs/hub4j-test-org/issues",
+  "members_url": "https://api.github.com/orgs/hub4j-test-org/members{/member}",
+  "public_members_url": "https://api.github.com/orgs/hub4j-test-org/public_members{/member}",
+  "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+  "description": "Hub4j Test Org Description (this could be null or blank too)",
+  "name": "Hub4j Test Org Name (this could be null or blank too)",
+  "company": null,
+  "blog": "https://hub4j.url.io/could/be/null",
+  "location": "Hub4j Test Org Location (this could be null or blank too)",
+  "email": "hub4jtestorgemail@could.be.null.com",
+  "twitter_username": null,
+  "is_verified": false,
+  "has_organization_projects": true,
+  "has_repository_projects": true,
+  "public_repos": 49,
+  "public_gists": 0,
+  "followers": 0,
+  "following": 0,
+  "html_url": "https://github.com/hub4j-test-org",
+  "created_at": "2014-05-10T19:39:11Z",
+  "updated_at": "2020-06-04T05:56:10Z",
+  "type": "Organization",
+  "total_private_repos": 3,
+  "owned_private_repos": 3,
+  "private_gists": 0,
+  "disk_usage": 11979,
+  "collaborators": 0,
+  "billing_email": "kk@kohsuke.org",
+  "default_repository_permission": "none",
+  "members_can_create_repositories": false,
+  "two_factor_requirement_enabled": false,
+  "members_allowed_repository_creation_type": "none",
+  "members_can_create_public_repositories": false,
+  "members_can_create_private_repositories": false,
+  "members_can_create_internal_repositories": false,
+  "members_can_create_pages": true,
+  "members_can_fork_private_repositories": false,
+  "members_can_create_public_pages": true,
+  "members_can_create_private_pages": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "private_repos": 10000,
+    "filled_seats": 35,
+    "seats": 3
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/orgs_hub4j-test-org_teams-4.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/orgs_hub4j-test-org_teams-4.json
new file mode 100644
index 000000000..78c71cfa6
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/orgs_hub4j-test-org_teams-4.json
@@ -0,0 +1,49 @@
+{
+  "name": "create-team-test",
+  "id": 5898252,
+  "node_id": "T_kwDOAHMfo84AWgAM",
+  "slug": "create-team-test",
+  "description": null,
+  "privacy": "secret",
+  "url": "https://api.github.com/organizations/7544739/team/5898252",
+  "html_url": "https://github.com/orgs/hub4j-test-org/teams/create-team-test",
+  "members_url": "https://api.github.com/organizations/7544739/team/5898252/members{/member}",
+  "repositories_url": "https://api.github.com/organizations/7544739/team/5898252/repos",
+  "permission": "pull",
+  "parent": null,
+  "created_at": "2022-04-06T13:19:47Z",
+  "updated_at": "2022-04-06T13:19:47Z",
+  "members_count": 1,
+  "repos_count": 0,
+  "organization": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "url": "https://api.github.com/orgs/hub4j-test-org",
+    "repos_url": "https://api.github.com/orgs/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/orgs/hub4j-test-org/events",
+    "hooks_url": "https://api.github.com/orgs/hub4j-test-org/hooks",
+    "issues_url": "https://api.github.com/orgs/hub4j-test-org/issues",
+    "members_url": "https://api.github.com/orgs/hub4j-test-org/members{/member}",
+    "public_members_url": "https://api.github.com/orgs/hub4j-test-org/public_members{/member}",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "description": "Hub4j Test Org Description (this could be null or blank too)",
+    "name": "Hub4j Test Org Name (this could be null or blank too)",
+    "company": null,
+    "blog": "https://hub4j.url.io/could/be/null",
+    "location": "Hub4j Test Org Location (this could be null or blank too)",
+    "email": "hub4jtestorgemail@could.be.null.com",
+    "twitter_username": null,
+    "is_verified": false,
+    "has_organization_projects": true,
+    "has_repository_projects": true,
+    "public_repos": 49,
+    "public_gists": 0,
+    "followers": 0,
+    "following": 0,
+    "html_url": "https://github.com/hub4j-test-org",
+    "created_at": "2014-05-10T19:39:11Z",
+    "updated_at": "2020-06-04T05:56:10Z",
+    "type": "Organization"
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..418d292cb
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,364 @@
+{
+  "id": 206888201,
+  "node_id": "MDEwOlJlcG9zaXRvcnkyMDY4ODgyMDE=",
+  "name": "github-api",
+  "full_name": "hub4j-test-org/github-api",
+  "private": false,
+  "owner": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "html_url": "https://github.com/hub4j-test-org/github-api",
+  "description": "Tricky",
+  "fork": true,
+  "url": "https://api.github.com/repos/hub4j-test-org/github-api",
+  "forks_url": "https://api.github.com/repos/hub4j-test-org/github-api/forks",
+  "keys_url": "https://api.github.com/repos/hub4j-test-org/github-api/keys{/key_id}",
+  "collaborators_url": "https://api.github.com/repos/hub4j-test-org/github-api/collaborators{/collaborator}",
+  "teams_url": "https://api.github.com/repos/hub4j-test-org/github-api/teams",
+  "hooks_url": "https://api.github.com/repos/hub4j-test-org/github-api/hooks",
+  "issue_events_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/events{/number}",
+  "events_url": "https://api.github.com/repos/hub4j-test-org/github-api/events",
+  "assignees_url": "https://api.github.com/repos/hub4j-test-org/github-api/assignees{/user}",
+  "branches_url": "https://api.github.com/repos/hub4j-test-org/github-api/branches{/branch}",
+  "tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/tags",
+  "blobs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/blobs{/sha}",
+  "git_tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/tags{/sha}",
+  "git_refs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/refs{/sha}",
+  "trees_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/trees{/sha}",
+  "statuses_url": "https://api.github.com/repos/hub4j-test-org/github-api/statuses/{sha}",
+  "languages_url": "https://api.github.com/repos/hub4j-test-org/github-api/languages",
+  "stargazers_url": "https://api.github.com/repos/hub4j-test-org/github-api/stargazers",
+  "contributors_url": "https://api.github.com/repos/hub4j-test-org/github-api/contributors",
+  "subscribers_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscribers",
+  "subscription_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscription",
+  "commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/commits{/sha}",
+  "git_commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/commits{/sha}",
+  "comments_url": "https://api.github.com/repos/hub4j-test-org/github-api/comments{/number}",
+  "issue_comment_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/comments{/number}",
+  "contents_url": "https://api.github.com/repos/hub4j-test-org/github-api/contents/{+path}",
+  "compare_url": "https://api.github.com/repos/hub4j-test-org/github-api/compare/{base}...{head}",
+  "merges_url": "https://api.github.com/repos/hub4j-test-org/github-api/merges",
+  "archive_url": "https://api.github.com/repos/hub4j-test-org/github-api/{archive_format}{/ref}",
+  "downloads_url": "https://api.github.com/repos/hub4j-test-org/github-api/downloads",
+  "issues_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues{/number}",
+  "pulls_url": "https://api.github.com/repos/hub4j-test-org/github-api/pulls{/number}",
+  "milestones_url": "https://api.github.com/repos/hub4j-test-org/github-api/milestones{/number}",
+  "notifications_url": "https://api.github.com/repos/hub4j-test-org/github-api/notifications{?since,all,participating}",
+  "labels_url": "https://api.github.com/repos/hub4j-test-org/github-api/labels{/name}",
+  "releases_url": "https://api.github.com/repos/hub4j-test-org/github-api/releases{/id}",
+  "deployments_url": "https://api.github.com/repos/hub4j-test-org/github-api/deployments",
+  "created_at": "2019-09-06T23:26:04Z",
+  "updated_at": "2021-11-09T20:13:29Z",
+  "pushed_at": "2022-03-04T11:02:08Z",
+  "git_url": "git://github.com/hub4j-test-org/github-api.git",
+  "ssh_url": "git@github.com:hub4j-test-org/github-api.git",
+  "clone_url": "https://github.com/hub4j-test-org/github-api.git",
+  "svn_url": "https://github.com/hub4j-test-org/github-api",
+  "homepage": "http://github-api.kohsuke.org/",
+  "size": 19045,
+  "stargazers_count": 0,
+  "watchers_count": 0,
+  "language": "Java",
+  "has_issues": true,
+  "has_projects": true,
+  "has_downloads": true,
+  "has_wiki": true,
+  "has_pages": false,
+  "forks_count": 0,
+  "mirror_url": null,
+  "archived": false,
+  "disabled": false,
+  "open_issues_count": 7,
+  "license": {
+    "key": "mit",
+    "name": "MIT License",
+    "spdx_id": "MIT",
+    "url": "https://api.github.com/licenses/mit",
+    "node_id": "MDc6TGljZW5zZTEz"
+  },
+  "allow_forking": true,
+  "is_template": false,
+  "topics": [],
+  "visibility": "public",
+  "forks": 0,
+  "open_issues": 7,
+  "watchers": 0,
+  "default_branch": "main",
+  "permissions": {
+    "admin": true,
+    "maintain": true,
+    "push": true,
+    "triage": true,
+    "pull": true
+  },
+  "temp_clone_token": "",
+  "allow_squash_merge": true,
+  "allow_merge_commit": true,
+  "allow_rebase_merge": true,
+  "allow_auto_merge": false,
+  "delete_branch_on_merge": false,
+  "allow_update_branch": false,
+  "organization": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "parent": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-04-05T15:53:55Z",
+    "pushed_at": "2022-04-05T05:40:16Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39832,
+    "stargazers_count": 878,
+    "watchers_count": 878,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 601,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 101,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 601,
+    "open_issues": 101,
+    "watchers": 878,
+    "default_branch": "main"
+  },
+  "source": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-04-05T15:53:55Z",
+    "pushed_at": "2022-04-05T05:40:16Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39832,
+    "stargazers_count": 878,
+    "watchers_count": 878,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 601,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 101,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 601,
+    "open_issues": 101,
+    "watchers": 878,
+    "default_branch": "main"
+  },
+  "network_count": 601,
+  "subscribers_count": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/repos_hub4j-test-org_github-api_teams-6.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/repos_hub4j-test-org_github-api_teams-6.json
new file mode 100644
index 000000000..5886a2746
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/repos_hub4j-test-org_github-api_teams-6.json
@@ -0,0 +1,86 @@
+[
+  {
+    "name": "Contributors",
+    "id": 4882699,
+    "node_id": "MDQ6VGVhbTQ4ODI2OTk=",
+    "slug": "contributors",
+    "description": "",
+    "privacy": "closed",
+    "url": "https://api.github.com/organizations/7544739/team/4882699",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/contributors",
+    "members_url": "https://api.github.com/organizations/7544739/team/4882699/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/4882699/repos",
+    "permission": "admin",
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "parent": null
+  },
+  {
+    "name": "create-team-test",
+    "id": 5898252,
+    "node_id": "T_kwDOAHMfo84AWgAM",
+    "slug": "create-team-test",
+    "description": null,
+    "privacy": "secret",
+    "url": "https://api.github.com/organizations/7544739/team/5898252",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/create-team-test",
+    "members_url": "https://api.github.com/organizations/7544739/team/5898252/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/5898252/repos",
+    "permission": "push",
+    "permissions": {
+      "admin": false,
+      "maintain": false,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "parent": null
+  },
+  {
+    "name": "dummy-team",
+    "id": 3451996,
+    "node_id": "MDQ6VGVhbTM0NTE5OTY=",
+    "slug": "dummy-team",
+    "description": "Updated by API TestModified",
+    "privacy": "closed",
+    "url": "https://api.github.com/organizations/7544739/team/3451996",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/dummy-team",
+    "members_url": "https://api.github.com/organizations/7544739/team/3451996/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/3451996/repos",
+    "permission": "push",
+    "permissions": {
+      "admin": false,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "parent": null
+  },
+  {
+    "name": "tricky-team",
+    "id": 3454508,
+    "node_id": "MDQ6VGVhbTM0NTQ1MDg=",
+    "slug": "tricky-team",
+    "description": "",
+    "privacy": "secret",
+    "url": "https://api.github.com/organizations/7544739/team/3454508",
+    "html_url": "https://github.com/orgs/hub4j-test-org/teams/tricky-team",
+    "members_url": "https://api.github.com/organizations/7544739/team/3454508/members{/member}",
+    "repositories_url": "https://api.github.com/organizations/7544739/team/3454508/repos",
+    "permission": "push",
+    "permissions": {
+      "admin": false,
+      "maintain": false,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "parent": null
+  }
+]
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/user-1.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/user-1.json
new file mode 100644
index 000000000..cfe0f3a0c
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/__files/user-1.json
@@ -0,0 +1,46 @@
+{
+  "login": "jgangemi",
+  "id": 1831839,
+  "node_id": "MDQ6VXNlcjE4MzE4Mzk=",
+  "avatar_url": "https://avatars.githubusercontent.com/u/1831839?v=4",
+  "gravatar_id": "",
+  "url": "https://api.github.com/users/jgangemi",
+  "html_url": "https://github.com/jgangemi",
+  "followers_url": "https://api.github.com/users/jgangemi/followers",
+  "following_url": "https://api.github.com/users/jgangemi/following{/other_user}",
+  "gists_url": "https://api.github.com/users/jgangemi/gists{/gist_id}",
+  "starred_url": "https://api.github.com/users/jgangemi/starred{/owner}{/repo}",
+  "subscriptions_url": "https://api.github.com/users/jgangemi/subscriptions",
+  "organizations_url": "https://api.github.com/users/jgangemi/orgs",
+  "repos_url": "https://api.github.com/users/jgangemi/repos",
+  "events_url": "https://api.github.com/users/jgangemi/events{/privacy}",
+  "received_events_url": "https://api.github.com/users/jgangemi/received_events",
+  "type": "User",
+  "site_admin": false,
+  "name": "Jae Gangemi",
+  "company": null,
+  "blog": "",
+  "location": null,
+  "email": null,
+  "hireable": null,
+  "bio": null,
+  "twitter_username": null,
+  "public_repos": 39,
+  "public_gists": 1,
+  "followers": 1,
+  "following": 0,
+  "created_at": "2012-06-08T19:54:02Z",
+  "updated_at": "2022-03-09T12:59:44Z",
+  "private_gists": 0,
+  "total_private_repos": 9,
+  "owned_private_repos": 9,
+  "disk_usage": 16623,
+  "collaborators": 0,
+  "two_factor_authentication": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "collaborators": 0,
+    "private_repos": 10000
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/organizations_7544739_team_5898252_repos_hub4j-test-org_github-api-5.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/organizations_7544739_team_5898252_repos_hub4j-test-org_github-api-5.json
new file mode 100644
index 000000000..c9ac00f2f
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/organizations_7544739_team_5898252_repos_hub4j-test-org_github-api-5.json
@@ -0,0 +1,47 @@
+{
+  "id": "dc4155d3-69b0-4b94-8b18-6259ae79dff7",
+  "name": "organizations_7544739_team_5898252_repos_hub4j-test-org_github-api",
+  "request": {
+    "url": "/organizations/7544739/team/5898252/repos/hub4j-test-org/github-api",
+    "method": "PUT",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"permission\":\"push\"}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 204,
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:19:47 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, read:org, repo, user, write:org",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4978",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "22",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "Vary": "Accept-Encoding, Accept, X-Requested-With",
+      "X-GitHub-Request-Id": "F72C:1B85:D1A03D:2972A6A:624D9373"
+    }
+  },
+  "uuid": "dc4155d3-69b0-4b94-8b18-6259ae79dff7",
+  "persistent": true,
+  "insertionIndex": 5
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..889b20d7c
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/orgs_hub4j-test-org-2.json
@@ -0,0 +1,48 @@
+{
+  "id": "f38d985a-47ef-4abb-8555-e10dd3b398f1",
+  "name": "orgs_hub4j-test-org",
+  "request": {
+    "url": "/orgs/hub4j-test-org",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "orgs_hub4j-test-org-2.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:19:46 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"9c48b6d97946cc9cca7a7eba9df130c47c977fea9e3ed36222d79a378e2ff6c8\"",
+      "Last-Modified": "Thu, 04 Jun 2020 05:56:10 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, read:org, repo, user, write:org",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4981",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "19",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F729:0DD6:B2D800:2174337:624D9371"
+    }
+  },
+  "uuid": "f38d985a-47ef-4abb-8555-e10dd3b398f1",
+  "persistent": true,
+  "insertionIndex": 2
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/orgs_hub4j-test-org_teams-4.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/orgs_hub4j-test-org_teams-4.json
new file mode 100644
index 000000000..2bd16c4c6
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/orgs_hub4j-test-org_teams-4.json
@@ -0,0 +1,55 @@
+{
+  "id": "1a8285bb-47f1-4fcc-ba89-5561a234e341",
+  "name": "orgs_hub4j-test-org_teams",
+  "request": {
+    "url": "/orgs/hub4j-test-org/teams",
+    "method": "POST",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"name\":\"create-team-test\"}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 201,
+    "bodyFileName": "orgs_hub4j-test-org_teams-4.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:19:47 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "\"246d7c8dfe769b8421f517f58d96f26b3e98841edd53107a9d3efe8b6a09ee41\"",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, repo",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4979",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "21",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F72B:8348:D8205D:2794AFE:624D9372",
+      "Location": "https://api.github.com/organizations/7544739/team/5898252"
+    }
+  },
+  "uuid": "1a8285bb-47f1-4fcc-ba89-5561a234e341",
+  "persistent": true,
+  "insertionIndex": 4
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..750fde2bf
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,48 @@
+{
+  "id": "102f424b-4c0b-4545-b5d3-90ff7c66ed10",
+  "name": "repos_hub4j-test-org_github-api",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repos_hub4j-test-org_github-api-3.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:19:46 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"f659ce60400fb1f0bd592ef4533029ee2aca8f3785088fc086eb3c10b2548f0f\"",
+      "Last-Modified": "Tue, 09 Nov 2021 20:13:29 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "repo",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4980",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "20",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F72A:27B5:28BC3D:8EBEFF:624D9372"
+    }
+  },
+  "uuid": "102f424b-4c0b-4545-b5d3-90ff7c66ed10",
+  "persistent": true,
+  "insertionIndex": 3
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/repos_hub4j-test-org_github-api_teams-6.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/repos_hub4j-test-org_github-api_teams-6.json
new file mode 100644
index 000000000..f8b7581e3
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/repos_hub4j-test-org_github-api_teams-6.json
@@ -0,0 +1,47 @@
+{
+  "id": "6fee3f98-4eab-406f-bb72-b4ec59a61353",
+  "name": "repos_hub4j-test-org_github-api_teams",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api/teams",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repos_hub4j-test-org_github-api_teams-6.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:19:48 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"bbb7dfb47509650a485809a1b671e6a145fcdb01e4c2ae4b1e279aba283970c3\"",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4977",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "23",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F72D:08CD:C36DCD:23BE34E:624D9374"
+    }
+  },
+  "uuid": "6fee3f98-4eab-406f-bb72-b4ec59a61353",
+  "persistent": true,
+  "insertionIndex": 6
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/user-1.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/user-1.json
new file mode 100644
index 000000000..16d5b8b9f
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoPerm/mappings/user-1.json
@@ -0,0 +1,48 @@
+{
+  "id": "1e877c4a-980d-4d3d-ab86-7525f99558ef",
+  "name": "user",
+  "request": {
+    "url": "/user",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "user-1.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:19:44 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"65ac0e73527e3adc4df6bbbde94bb21480926587df8832f0bab8a5fc1bc746c9\"",
+      "Last-Modified": "Wed, 09 Mar 2022 12:59:44 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4986",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "14",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F727:8122:1167F00:208AC47:624D936F"
+    }
+  },
+  "uuid": "1e877c4a-980d-4d3d-ab86-7525f99558ef",
+  "persistent": true,
+  "insertionIndex": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..ed712b6a4
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/orgs_hub4j-test-org-2.json
@@ -0,0 +1,55 @@
+{
+  "login": "hub4j-test-org",
+  "id": 7544739,
+  "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+  "url": "https://api.github.com/orgs/hub4j-test-org",
+  "repos_url": "https://api.github.com/orgs/hub4j-test-org/repos",
+  "events_url": "https://api.github.com/orgs/hub4j-test-org/events",
+  "hooks_url": "https://api.github.com/orgs/hub4j-test-org/hooks",
+  "issues_url": "https://api.github.com/orgs/hub4j-test-org/issues",
+  "members_url": "https://api.github.com/orgs/hub4j-test-org/members{/member}",
+  "public_members_url": "https://api.github.com/orgs/hub4j-test-org/public_members{/member}",
+  "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+  "description": "Hub4j Test Org Description (this could be null or blank too)",
+  "name": "Hub4j Test Org Name (this could be null or blank too)",
+  "company": null,
+  "blog": "https://hub4j.url.io/could/be/null",
+  "location": "Hub4j Test Org Location (this could be null or blank too)",
+  "email": "hub4jtestorgemail@could.be.null.com",
+  "twitter_username": null,
+  "is_verified": false,
+  "has_organization_projects": true,
+  "has_repository_projects": true,
+  "public_repos": 48,
+  "public_gists": 0,
+  "followers": 0,
+  "following": 0,
+  "html_url": "https://github.com/hub4j-test-org",
+  "created_at": "2014-05-10T19:39:11Z",
+  "updated_at": "2020-06-04T05:56:10Z",
+  "type": "Organization",
+  "total_private_repos": 3,
+  "owned_private_repos": 3,
+  "private_gists": 0,
+  "disk_usage": 11979,
+  "collaborators": 0,
+  "billing_email": "kk@kohsuke.org",
+  "default_repository_permission": "none",
+  "members_can_create_repositories": false,
+  "two_factor_requirement_enabled": false,
+  "members_allowed_repository_creation_type": "none",
+  "members_can_create_public_repositories": false,
+  "members_can_create_private_repositories": false,
+  "members_can_create_internal_repositories": false,
+  "members_can_create_pages": true,
+  "members_can_fork_private_repositories": false,
+  "members_can_create_public_pages": true,
+  "members_can_create_private_pages": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "private_repos": 10000,
+    "filled_seats": 35,
+    "seats": 3
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/orgs_hub4j-test-org_teams-4.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/orgs_hub4j-test-org_teams-4.json
new file mode 100644
index 000000000..df154ce21
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/orgs_hub4j-test-org_teams-4.json
@@ -0,0 +1,49 @@
+{
+  "name": "create-team-test",
+  "id": 5819578,
+  "node_id": "T_kwDOAHMfo84AWMy6",
+  "slug": "create-team-test",
+  "description": null,
+  "privacy": "secret",
+  "url": "https://api.github.com/organizations/7544739/team/5819578",
+  "html_url": "https://github.com/orgs/hub4j-test-org/teams/create-team-test",
+  "members_url": "https://api.github.com/organizations/7544739/team/5819578/members{/member}",
+  "repositories_url": "https://api.github.com/organizations/7544739/team/5819578/repos",
+  "permission": "pull",
+  "parent": null,
+  "created_at": "2022-03-18T21:50:11Z",
+  "updated_at": "2022-03-18T21:50:11Z",
+  "members_count": 1,
+  "repos_count": 0,
+  "organization": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "url": "https://api.github.com/orgs/hub4j-test-org",
+    "repos_url": "https://api.github.com/orgs/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/orgs/hub4j-test-org/events",
+    "hooks_url": "https://api.github.com/orgs/hub4j-test-org/hooks",
+    "issues_url": "https://api.github.com/orgs/hub4j-test-org/issues",
+    "members_url": "https://api.github.com/orgs/hub4j-test-org/members{/member}",
+    "public_members_url": "https://api.github.com/orgs/hub4j-test-org/public_members{/member}",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "description": "Hub4j Test Org Description (this could be null or blank too)",
+    "name": "Hub4j Test Org Name (this could be null or blank too)",
+    "company": null,
+    "blog": "https://hub4j.url.io/could/be/null",
+    "location": "Hub4j Test Org Location (this could be null or blank too)",
+    "email": "hub4jtestorgemail@could.be.null.com",
+    "twitter_username": null,
+    "is_verified": false,
+    "has_organization_projects": true,
+    "has_repository_projects": true,
+    "public_repos": 48,
+    "public_gists": 0,
+    "followers": 0,
+    "following": 0,
+    "html_url": "https://github.com/hub4j-test-org",
+    "created_at": "2014-05-10T19:39:11Z",
+    "updated_at": "2020-06-04T05:56:10Z",
+    "type": "Organization"
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..8bb9249af
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,364 @@
+{
+  "id": 206888201,
+  "node_id": "MDEwOlJlcG9zaXRvcnkyMDY4ODgyMDE=",
+  "name": "github-api",
+  "full_name": "hub4j-test-org/github-api",
+  "private": false,
+  "owner": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "html_url": "https://github.com/hub4j-test-org/github-api",
+  "description": "Tricky",
+  "fork": true,
+  "url": "https://api.github.com/repos/hub4j-test-org/github-api",
+  "forks_url": "https://api.github.com/repos/hub4j-test-org/github-api/forks",
+  "keys_url": "https://api.github.com/repos/hub4j-test-org/github-api/keys{/key_id}",
+  "collaborators_url": "https://api.github.com/repos/hub4j-test-org/github-api/collaborators{/collaborator}",
+  "teams_url": "https://api.github.com/repos/hub4j-test-org/github-api/teams",
+  "hooks_url": "https://api.github.com/repos/hub4j-test-org/github-api/hooks",
+  "issue_events_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/events{/number}",
+  "events_url": "https://api.github.com/repos/hub4j-test-org/github-api/events",
+  "assignees_url": "https://api.github.com/repos/hub4j-test-org/github-api/assignees{/user}",
+  "branches_url": "https://api.github.com/repos/hub4j-test-org/github-api/branches{/branch}",
+  "tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/tags",
+  "blobs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/blobs{/sha}",
+  "git_tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/tags{/sha}",
+  "git_refs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/refs{/sha}",
+  "trees_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/trees{/sha}",
+  "statuses_url": "https://api.github.com/repos/hub4j-test-org/github-api/statuses/{sha}",
+  "languages_url": "https://api.github.com/repos/hub4j-test-org/github-api/languages",
+  "stargazers_url": "https://api.github.com/repos/hub4j-test-org/github-api/stargazers",
+  "contributors_url": "https://api.github.com/repos/hub4j-test-org/github-api/contributors",
+  "subscribers_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscribers",
+  "subscription_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscription",
+  "commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/commits{/sha}",
+  "git_commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/commits{/sha}",
+  "comments_url": "https://api.github.com/repos/hub4j-test-org/github-api/comments{/number}",
+  "issue_comment_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/comments{/number}",
+  "contents_url": "https://api.github.com/repos/hub4j-test-org/github-api/contents/{+path}",
+  "compare_url": "https://api.github.com/repos/hub4j-test-org/github-api/compare/{base}...{head}",
+  "merges_url": "https://api.github.com/repos/hub4j-test-org/github-api/merges",
+  "archive_url": "https://api.github.com/repos/hub4j-test-org/github-api/{archive_format}{/ref}",
+  "downloads_url": "https://api.github.com/repos/hub4j-test-org/github-api/downloads",
+  "issues_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues{/number}",
+  "pulls_url": "https://api.github.com/repos/hub4j-test-org/github-api/pulls{/number}",
+  "milestones_url": "https://api.github.com/repos/hub4j-test-org/github-api/milestones{/number}",
+  "notifications_url": "https://api.github.com/repos/hub4j-test-org/github-api/notifications{?since,all,participating}",
+  "labels_url": "https://api.github.com/repos/hub4j-test-org/github-api/labels{/name}",
+  "releases_url": "https://api.github.com/repos/hub4j-test-org/github-api/releases{/id}",
+  "deployments_url": "https://api.github.com/repos/hub4j-test-org/github-api/deployments",
+  "created_at": "2019-09-06T23:26:04Z",
+  "updated_at": "2021-11-09T20:13:29Z",
+  "pushed_at": "2022-03-04T11:02:08Z",
+  "git_url": "git://github.com/hub4j-test-org/github-api.git",
+  "ssh_url": "git@github.com:hub4j-test-org/github-api.git",
+  "clone_url": "https://github.com/hub4j-test-org/github-api.git",
+  "svn_url": "https://github.com/hub4j-test-org/github-api",
+  "homepage": "http://github-api.kohsuke.org/",
+  "size": 19045,
+  "stargazers_count": 0,
+  "watchers_count": 0,
+  "language": "Java",
+  "has_issues": true,
+  "has_projects": true,
+  "has_downloads": true,
+  "has_wiki": true,
+  "has_pages": false,
+  "forks_count": 0,
+  "mirror_url": null,
+  "archived": false,
+  "disabled": false,
+  "open_issues_count": 7,
+  "license": {
+    "key": "mit",
+    "name": "MIT License",
+    "spdx_id": "MIT",
+    "url": "https://api.github.com/licenses/mit",
+    "node_id": "MDc6TGljZW5zZTEz"
+  },
+  "allow_forking": true,
+  "is_template": false,
+  "topics": [],
+  "visibility": "public",
+  "forks": 0,
+  "open_issues": 7,
+  "watchers": 0,
+  "default_branch": "main",
+  "permissions": {
+    "admin": true,
+    "maintain": true,
+    "push": true,
+    "triage": true,
+    "pull": true
+  },
+  "temp_clone_token": "",
+  "allow_squash_merge": true,
+  "allow_merge_commit": true,
+  "allow_rebase_merge": true,
+  "allow_auto_merge": false,
+  "delete_branch_on_merge": false,
+  "allow_update_branch": false,
+  "organization": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "parent": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-03-18T10:24:59Z",
+    "pushed_at": "2022-03-15T12:49:31Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39710,
+    "stargazers_count": 873,
+    "watchers_count": 873,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 599,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 100,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 599,
+    "open_issues": 100,
+    "watchers": 873,
+    "default_branch": "main"
+  },
+  "source": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-03-18T10:24:59Z",
+    "pushed_at": "2022-03-15T12:49:31Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39710,
+    "stargazers_count": 873,
+    "watchers_count": 873,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 599,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 100,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 599,
+    "open_issues": 100,
+    "watchers": 873,
+    "default_branch": "main"
+  },
+  "network_count": 599,
+  "subscribers_count": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/user-1.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/user-1.json
new file mode 100644
index 000000000..cfe0f3a0c
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/__files/user-1.json
@@ -0,0 +1,46 @@
+{
+  "login": "jgangemi",
+  "id": 1831839,
+  "node_id": "MDQ6VXNlcjE4MzE4Mzk=",
+  "avatar_url": "https://avatars.githubusercontent.com/u/1831839?v=4",
+  "gravatar_id": "",
+  "url": "https://api.github.com/users/jgangemi",
+  "html_url": "https://github.com/jgangemi",
+  "followers_url": "https://api.github.com/users/jgangemi/followers",
+  "following_url": "https://api.github.com/users/jgangemi/following{/other_user}",
+  "gists_url": "https://api.github.com/users/jgangemi/gists{/gist_id}",
+  "starred_url": "https://api.github.com/users/jgangemi/starred{/owner}{/repo}",
+  "subscriptions_url": "https://api.github.com/users/jgangemi/subscriptions",
+  "organizations_url": "https://api.github.com/users/jgangemi/orgs",
+  "repos_url": "https://api.github.com/users/jgangemi/repos",
+  "events_url": "https://api.github.com/users/jgangemi/events{/privacy}",
+  "received_events_url": "https://api.github.com/users/jgangemi/received_events",
+  "type": "User",
+  "site_admin": false,
+  "name": "Jae Gangemi",
+  "company": null,
+  "blog": "",
+  "location": null,
+  "email": null,
+  "hireable": null,
+  "bio": null,
+  "twitter_username": null,
+  "public_repos": 39,
+  "public_gists": 1,
+  "followers": 1,
+  "following": 0,
+  "created_at": "2012-06-08T19:54:02Z",
+  "updated_at": "2022-03-09T12:59:44Z",
+  "private_gists": 0,
+  "total_private_repos": 9,
+  "owned_private_repos": 9,
+  "disk_usage": 16623,
+  "collaborators": 0,
+  "two_factor_authentication": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "collaborators": 0,
+    "private_repos": 10000
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/organizations_7544739_team_5819578_repos_hub4j-test-org_github-api-5.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/organizations_7544739_team_5819578_repos_hub4j-test-org_github-api-5.json
new file mode 100644
index 000000000..1d1ac06e2
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/organizations_7544739_team_5819578_repos_hub4j-test-org_github-api-5.json
@@ -0,0 +1,47 @@
+{
+  "id": "e4a6ce2a-a5dc-4869-ae9d-50c5723ab190",
+  "name": "organizations_7544739_team_5819578_repos_hub4j-test-org_github-api",
+  "request": {
+    "url": "/organizations/7544739/team/5819578/repos/hub4j-test-org/github-api",
+    "method": "PUT",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"permission\":\"triage\"}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 204,
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Fri, 18 Mar 2022 21:50:12 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, read:org, repo, user, write:org",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4937",
+      "X-RateLimit-Reset": "1647642206",
+      "X-RateLimit-Used": "63",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "Vary": "Accept-Encoding, Accept, X-Requested-With",
+      "X-GitHub-Request-Id": "F648:32DC:3A5D6B:6F68FD:6234FE94"
+    }
+  },
+  "uuid": "e4a6ce2a-a5dc-4869-ae9d-50c5723ab190",
+  "persistent": true,
+  "insertionIndex": 5
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..1255c29fa
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/orgs_hub4j-test-org-2.json
@@ -0,0 +1,48 @@
+{
+  "id": "c3064708-e979-4ffa-a4fc-2260ae7dc65e",
+  "name": "orgs_hub4j-test-org",
+  "request": {
+    "url": "/orgs/hub4j-test-org",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "orgs_hub4j-test-org-2.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Fri, 18 Mar 2022 21:50:10 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"7158b1627effd511902a75ae99efc0c0361a7d11186ee2a7540a75e7b63c2d4b\"",
+      "Last-Modified": "Thu, 04 Jun 2020 05:56:10 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, read:org, repo, user, write:org",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4940",
+      "X-RateLimit-Reset": "1647642206",
+      "X-RateLimit-Used": "60",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F645:75A6:3865AE:6EF8AD:6234FE92"
+    }
+  },
+  "uuid": "c3064708-e979-4ffa-a4fc-2260ae7dc65e",
+  "persistent": true,
+  "insertionIndex": 2
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/orgs_hub4j-test-org_teams-4.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/orgs_hub4j-test-org_teams-4.json
new file mode 100644
index 000000000..60277c9e7
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/orgs_hub4j-test-org_teams-4.json
@@ -0,0 +1,55 @@
+{
+  "id": "fc36b944-0b1c-4083-83a5-db23d8ed293d",
+  "name": "orgs_hub4j-test-org_teams",
+  "request": {
+    "url": "/orgs/hub4j-test-org/teams",
+    "method": "POST",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"name\":\"create-team-test\"}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 201,
+    "bodyFileName": "orgs_hub4j-test-org_teams-4.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Fri, 18 Mar 2022 21:50:12 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "\"cc1c573c70ea994341e5c3089cfad47333e71adbce083f22824b8f57c2167dea\"",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, repo",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4938",
+      "X-RateLimit-Reset": "1647642206",
+      "X-RateLimit-Used": "62",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F647:6593:2128DD:4BBC82:6234FE93",
+      "Location": "https://api.github.com/organizations/7544739/team/5819578"
+    }
+  },
+  "uuid": "fc36b944-0b1c-4083-83a5-db23d8ed293d",
+  "persistent": true,
+  "insertionIndex": 4
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..fcd211097
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,48 @@
+{
+  "id": "97d37ed3-37c5-4b6c-a94a-7e33142295c1",
+  "name": "repos_hub4j-test-org_github-api",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repos_hub4j-test-org_github-api-3.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Fri, 18 Mar 2022 21:50:11 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"f659ce60400fb1f0bd592ef4533029ee2aca8f3785088fc086eb3c10b2548f0f\"",
+      "Last-Modified": "Tue, 09 Nov 2021 20:13:29 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "repo",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4939",
+      "X-RateLimit-Reset": "1647642206",
+      "X-RateLimit-Used": "61",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F646:3A72:2CDAC5:819DC7:6234FE93"
+    }
+  },
+  "uuid": "97d37ed3-37c5-4b6c-a94a-7e33142295c1",
+  "persistent": true,
+  "insertionIndex": 3
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/user-1.json b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/user-1.json
new file mode 100644
index 000000000..e2ae676f8
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHOrganizationTest/wiremock/testCreateTeamWithRepoRole/mappings/user-1.json
@@ -0,0 +1,48 @@
+{
+  "id": "35a29373-1735-4afe-9e05-bb08b0a8ddfa",
+  "name": "user",
+  "request": {
+    "url": "/user",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "user-1.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Fri, 18 Mar 2022 21:50:09 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"65ac0e73527e3adc4df6bbbde94bb21480926587df8832f0bab8a5fc1bc746c9\"",
+      "Last-Modified": "Wed, 09 Mar 2022 12:59:44 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4945",
+      "X-RateLimit-Reset": "1647642206",
+      "X-RateLimit-Used": "55",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "F643:3A71:3D5249:73EB94:6234FE90"
+    }
+  },
+  "uuid": "35a29373-1735-4afe-9e05-bb08b0a8ddfa",
+  "persistent": true,
+  "insertionIndex": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..162ceb1c7
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/orgs_hub4j-test-org-2.json
@@ -0,0 +1,55 @@
+{
+  "login": "hub4j-test-org",
+  "id": 7544739,
+  "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+  "url": "https://api.github.com/orgs/hub4j-test-org",
+  "repos_url": "https://api.github.com/orgs/hub4j-test-org/repos",
+  "events_url": "https://api.github.com/orgs/hub4j-test-org/events",
+  "hooks_url": "https://api.github.com/orgs/hub4j-test-org/hooks",
+  "issues_url": "https://api.github.com/orgs/hub4j-test-org/issues",
+  "members_url": "https://api.github.com/orgs/hub4j-test-org/members{/member}",
+  "public_members_url": "https://api.github.com/orgs/hub4j-test-org/public_members{/member}",
+  "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+  "description": "Hub4j Test Org Description (this could be null or blank too)",
+  "name": "Hub4j Test Org Name (this could be null or blank too)",
+  "company": null,
+  "blog": "https://hub4j.url.io/could/be/null",
+  "location": "Hub4j Test Org Location (this could be null or blank too)",
+  "email": "hub4jtestorgemail@could.be.null.com",
+  "twitter_username": null,
+  "is_verified": false,
+  "has_organization_projects": true,
+  "has_repository_projects": true,
+  "public_repos": 49,
+  "public_gists": 0,
+  "followers": 0,
+  "following": 0,
+  "html_url": "https://github.com/hub4j-test-org",
+  "created_at": "2014-05-10T19:39:11Z",
+  "updated_at": "2020-06-04T05:56:10Z",
+  "type": "Organization",
+  "total_private_repos": 3,
+  "owned_private_repos": 3,
+  "private_gists": 0,
+  "disk_usage": 11979,
+  "collaborators": 0,
+  "billing_email": "kk@kohsuke.org",
+  "default_repository_permission": "none",
+  "members_can_create_repositories": false,
+  "two_factor_requirement_enabled": false,
+  "members_allowed_repository_creation_type": "none",
+  "members_can_create_public_repositories": false,
+  "members_can_create_private_repositories": false,
+  "members_can_create_internal_repositories": false,
+  "members_can_create_pages": true,
+  "members_can_fork_private_repositories": false,
+  "members_can_create_public_pages": true,
+  "members_can_create_private_pages": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "private_repos": 10000,
+    "filled_seats": 35,
+    "seats": 3
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..ae72e6c57
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,364 @@
+{
+  "id": 206888201,
+  "node_id": "MDEwOlJlcG9zaXRvcnkyMDY4ODgyMDE=",
+  "name": "github-api",
+  "full_name": "hub4j-test-org/github-api",
+  "private": false,
+  "owner": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "html_url": "https://github.com/hub4j-test-org/github-api",
+  "description": "Tricky",
+  "fork": true,
+  "url": "https://api.github.com/repos/hub4j-test-org/github-api",
+  "forks_url": "https://api.github.com/repos/hub4j-test-org/github-api/forks",
+  "keys_url": "https://api.github.com/repos/hub4j-test-org/github-api/keys{/key_id}",
+  "collaborators_url": "https://api.github.com/repos/hub4j-test-org/github-api/collaborators{/collaborator}",
+  "teams_url": "https://api.github.com/repos/hub4j-test-org/github-api/teams",
+  "hooks_url": "https://api.github.com/repos/hub4j-test-org/github-api/hooks",
+  "issue_events_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/events{/number}",
+  "events_url": "https://api.github.com/repos/hub4j-test-org/github-api/events",
+  "assignees_url": "https://api.github.com/repos/hub4j-test-org/github-api/assignees{/user}",
+  "branches_url": "https://api.github.com/repos/hub4j-test-org/github-api/branches{/branch}",
+  "tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/tags",
+  "blobs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/blobs{/sha}",
+  "git_tags_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/tags{/sha}",
+  "git_refs_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/refs{/sha}",
+  "trees_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/trees{/sha}",
+  "statuses_url": "https://api.github.com/repos/hub4j-test-org/github-api/statuses/{sha}",
+  "languages_url": "https://api.github.com/repos/hub4j-test-org/github-api/languages",
+  "stargazers_url": "https://api.github.com/repos/hub4j-test-org/github-api/stargazers",
+  "contributors_url": "https://api.github.com/repos/hub4j-test-org/github-api/contributors",
+  "subscribers_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscribers",
+  "subscription_url": "https://api.github.com/repos/hub4j-test-org/github-api/subscription",
+  "commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/commits{/sha}",
+  "git_commits_url": "https://api.github.com/repos/hub4j-test-org/github-api/git/commits{/sha}",
+  "comments_url": "https://api.github.com/repos/hub4j-test-org/github-api/comments{/number}",
+  "issue_comment_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues/comments{/number}",
+  "contents_url": "https://api.github.com/repos/hub4j-test-org/github-api/contents/{+path}",
+  "compare_url": "https://api.github.com/repos/hub4j-test-org/github-api/compare/{base}...{head}",
+  "merges_url": "https://api.github.com/repos/hub4j-test-org/github-api/merges",
+  "archive_url": "https://api.github.com/repos/hub4j-test-org/github-api/{archive_format}{/ref}",
+  "downloads_url": "https://api.github.com/repos/hub4j-test-org/github-api/downloads",
+  "issues_url": "https://api.github.com/repos/hub4j-test-org/github-api/issues{/number}",
+  "pulls_url": "https://api.github.com/repos/hub4j-test-org/github-api/pulls{/number}",
+  "milestones_url": "https://api.github.com/repos/hub4j-test-org/github-api/milestones{/number}",
+  "notifications_url": "https://api.github.com/repos/hub4j-test-org/github-api/notifications{?since,all,participating}",
+  "labels_url": "https://api.github.com/repos/hub4j-test-org/github-api/labels{/name}",
+  "releases_url": "https://api.github.com/repos/hub4j-test-org/github-api/releases{/id}",
+  "deployments_url": "https://api.github.com/repos/hub4j-test-org/github-api/deployments",
+  "created_at": "2019-09-06T23:26:04Z",
+  "updated_at": "2021-11-09T20:13:29Z",
+  "pushed_at": "2022-03-04T11:02:08Z",
+  "git_url": "git://github.com/hub4j-test-org/github-api.git",
+  "ssh_url": "git@github.com:hub4j-test-org/github-api.git",
+  "clone_url": "https://github.com/hub4j-test-org/github-api.git",
+  "svn_url": "https://github.com/hub4j-test-org/github-api",
+  "homepage": "http://github-api.kohsuke.org/",
+  "size": 19045,
+  "stargazers_count": 0,
+  "watchers_count": 0,
+  "language": "Java",
+  "has_issues": true,
+  "has_projects": true,
+  "has_downloads": true,
+  "has_wiki": true,
+  "has_pages": false,
+  "forks_count": 0,
+  "mirror_url": null,
+  "archived": false,
+  "disabled": false,
+  "open_issues_count": 7,
+  "license": {
+    "key": "mit",
+    "name": "MIT License",
+    "spdx_id": "MIT",
+    "url": "https://api.github.com/licenses/mit",
+    "node_id": "MDc6TGljZW5zZTEz"
+  },
+  "allow_forking": true,
+  "is_template": false,
+  "topics": [],
+  "visibility": "public",
+  "forks": 0,
+  "open_issues": 7,
+  "watchers": 0,
+  "default_branch": "main",
+  "permissions": {
+    "admin": true,
+    "maintain": true,
+    "push": true,
+    "triage": true,
+    "pull": true
+  },
+  "temp_clone_token": "",
+  "allow_squash_merge": true,
+  "allow_merge_commit": true,
+  "allow_rebase_merge": true,
+  "allow_auto_merge": false,
+  "delete_branch_on_merge": false,
+  "allow_update_branch": false,
+  "organization": {
+    "login": "hub4j-test-org",
+    "id": 7544739,
+    "node_id": "MDEyOk9yZ2FuaXphdGlvbjc1NDQ3Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7544739?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/hub4j-test-org",
+    "html_url": "https://github.com/hub4j-test-org",
+    "followers_url": "https://api.github.com/users/hub4j-test-org/followers",
+    "following_url": "https://api.github.com/users/hub4j-test-org/following{/other_user}",
+    "gists_url": "https://api.github.com/users/hub4j-test-org/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/hub4j-test-org/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/hub4j-test-org/subscriptions",
+    "organizations_url": "https://api.github.com/users/hub4j-test-org/orgs",
+    "repos_url": "https://api.github.com/users/hub4j-test-org/repos",
+    "events_url": "https://api.github.com/users/hub4j-test-org/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/hub4j-test-org/received_events",
+    "type": "Organization",
+    "site_admin": false
+  },
+  "parent": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-04-05T15:53:55Z",
+    "pushed_at": "2022-04-06T13:31:06Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39832,
+    "stargazers_count": 878,
+    "watchers_count": 878,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 601,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 101,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 601,
+    "open_issues": 101,
+    "watchers": 878,
+    "default_branch": "main"
+  },
+  "source": {
+    "id": 617210,
+    "node_id": "MDEwOlJlcG9zaXRvcnk2MTcyMTA=",
+    "name": "github-api",
+    "full_name": "hub4j/github-api",
+    "private": false,
+    "owner": {
+      "login": "hub4j",
+      "id": 54909825,
+      "node_id": "MDEyOk9yZ2FuaXphdGlvbjU0OTA5ODI1",
+      "avatar_url": "https://avatars.githubusercontent.com/u/54909825?v=4",
+      "gravatar_id": "",
+      "url": "https://api.github.com/users/hub4j",
+      "html_url": "https://github.com/hub4j",
+      "followers_url": "https://api.github.com/users/hub4j/followers",
+      "following_url": "https://api.github.com/users/hub4j/following{/other_user}",
+      "gists_url": "https://api.github.com/users/hub4j/gists{/gist_id}",
+      "starred_url": "https://api.github.com/users/hub4j/starred{/owner}{/repo}",
+      "subscriptions_url": "https://api.github.com/users/hub4j/subscriptions",
+      "organizations_url": "https://api.github.com/users/hub4j/orgs",
+      "repos_url": "https://api.github.com/users/hub4j/repos",
+      "events_url": "https://api.github.com/users/hub4j/events{/privacy}",
+      "received_events_url": "https://api.github.com/users/hub4j/received_events",
+      "type": "Organization",
+      "site_admin": false
+    },
+    "html_url": "https://github.com/hub4j/github-api",
+    "description": "Java API for GitHub",
+    "fork": false,
+    "url": "https://api.github.com/repos/hub4j/github-api",
+    "forks_url": "https://api.github.com/repos/hub4j/github-api/forks",
+    "keys_url": "https://api.github.com/repos/hub4j/github-api/keys{/key_id}",
+    "collaborators_url": "https://api.github.com/repos/hub4j/github-api/collaborators{/collaborator}",
+    "teams_url": "https://api.github.com/repos/hub4j/github-api/teams",
+    "hooks_url": "https://api.github.com/repos/hub4j/github-api/hooks",
+    "issue_events_url": "https://api.github.com/repos/hub4j/github-api/issues/events{/number}",
+    "events_url": "https://api.github.com/repos/hub4j/github-api/events",
+    "assignees_url": "https://api.github.com/repos/hub4j/github-api/assignees{/user}",
+    "branches_url": "https://api.github.com/repos/hub4j/github-api/branches{/branch}",
+    "tags_url": "https://api.github.com/repos/hub4j/github-api/tags",
+    "blobs_url": "https://api.github.com/repos/hub4j/github-api/git/blobs{/sha}",
+    "git_tags_url": "https://api.github.com/repos/hub4j/github-api/git/tags{/sha}",
+    "git_refs_url": "https://api.github.com/repos/hub4j/github-api/git/refs{/sha}",
+    "trees_url": "https://api.github.com/repos/hub4j/github-api/git/trees{/sha}",
+    "statuses_url": "https://api.github.com/repos/hub4j/github-api/statuses/{sha}",
+    "languages_url": "https://api.github.com/repos/hub4j/github-api/languages",
+    "stargazers_url": "https://api.github.com/repos/hub4j/github-api/stargazers",
+    "contributors_url": "https://api.github.com/repos/hub4j/github-api/contributors",
+    "subscribers_url": "https://api.github.com/repos/hub4j/github-api/subscribers",
+    "subscription_url": "https://api.github.com/repos/hub4j/github-api/subscription",
+    "commits_url": "https://api.github.com/repos/hub4j/github-api/commits{/sha}",
+    "git_commits_url": "https://api.github.com/repos/hub4j/github-api/git/commits{/sha}",
+    "comments_url": "https://api.github.com/repos/hub4j/github-api/comments{/number}",
+    "issue_comment_url": "https://api.github.com/repos/hub4j/github-api/issues/comments{/number}",
+    "contents_url": "https://api.github.com/repos/hub4j/github-api/contents/{+path}",
+    "compare_url": "https://api.github.com/repos/hub4j/github-api/compare/{base}...{head}",
+    "merges_url": "https://api.github.com/repos/hub4j/github-api/merges",
+    "archive_url": "https://api.github.com/repos/hub4j/github-api/{archive_format}{/ref}",
+    "downloads_url": "https://api.github.com/repos/hub4j/github-api/downloads",
+    "issues_url": "https://api.github.com/repos/hub4j/github-api/issues{/number}",
+    "pulls_url": "https://api.github.com/repos/hub4j/github-api/pulls{/number}",
+    "milestones_url": "https://api.github.com/repos/hub4j/github-api/milestones{/number}",
+    "notifications_url": "https://api.github.com/repos/hub4j/github-api/notifications{?since,all,participating}",
+    "labels_url": "https://api.github.com/repos/hub4j/github-api/labels{/name}",
+    "releases_url": "https://api.github.com/repos/hub4j/github-api/releases{/id}",
+    "deployments_url": "https://api.github.com/repos/hub4j/github-api/deployments",
+    "created_at": "2010-04-19T04:13:03Z",
+    "updated_at": "2022-04-05T15:53:55Z",
+    "pushed_at": "2022-04-06T13:31:06Z",
+    "git_url": "git://github.com/hub4j/github-api.git",
+    "ssh_url": "git@github.com:hub4j/github-api.git",
+    "clone_url": "https://github.com/hub4j/github-api.git",
+    "svn_url": "https://github.com/hub4j/github-api",
+    "homepage": "https://github-api.kohsuke.org/",
+    "size": 39832,
+    "stargazers_count": 878,
+    "watchers_count": 878,
+    "language": "Java",
+    "has_issues": true,
+    "has_projects": true,
+    "has_downloads": true,
+    "has_wiki": true,
+    "has_pages": true,
+    "forks_count": 601,
+    "mirror_url": null,
+    "archived": false,
+    "disabled": false,
+    "open_issues_count": 101,
+    "license": {
+      "key": "mit",
+      "name": "MIT License",
+      "spdx_id": "MIT",
+      "url": "https://api.github.com/licenses/mit",
+      "node_id": "MDc6TGljZW5zZTEz"
+    },
+    "allow_forking": true,
+    "is_template": false,
+    "topics": [
+      "api",
+      "client-library",
+      "github",
+      "github-api",
+      "github-api-v3",
+      "java",
+      "java-api"
+    ],
+    "visibility": "public",
+    "forks": 601,
+    "open_issues": 101,
+    "watchers": 878,
+    "default_branch": "main"
+  },
+  "network_count": 601,
+  "subscribers_count": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repos_hub4j-test-org_github-api_collaborators-7.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repos_hub4j-test-org_github-api_collaborators-7.json
new file mode 100644
index 000000000..99cc2f77a
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repos_hub4j-test-org_github-api_collaborators-7.json
@@ -0,0 +1,842 @@
+[
+  {
+    "login": "vbehar",
+    "id": 6251,
+    "node_id": "MDQ6VXNlcjYyNTE=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/6251?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/vbehar",
+    "html_url": "https://github.com/vbehar",
+    "followers_url": "https://api.github.com/users/vbehar/followers",
+    "following_url": "https://api.github.com/users/vbehar/following{/other_user}",
+    "gists_url": "https://api.github.com/users/vbehar/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/vbehar/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/vbehar/subscriptions",
+    "organizations_url": "https://api.github.com/users/vbehar/orgs",
+    "repos_url": "https://api.github.com/users/vbehar/repos",
+    "events_url": "https://api.github.com/users/vbehar/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/vbehar/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": false,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "maintain"
+  },
+  {
+    "login": "kohsuke",
+    "id": 50003,
+    "node_id": "MDQ6VXNlcjUwMDAz",
+    "avatar_url": "https://avatars.githubusercontent.com/u/50003?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/kohsuke",
+    "html_url": "https://github.com/kohsuke",
+    "followers_url": "https://api.github.com/users/kohsuke/followers",
+    "following_url": "https://api.github.com/users/kohsuke/following{/other_user}",
+    "gists_url": "https://api.github.com/users/kohsuke/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/kohsuke/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/kohsuke/subscriptions",
+    "organizations_url": "https://api.github.com/users/kohsuke/orgs",
+    "repos_url": "https://api.github.com/users/kohsuke/repos",
+    "events_url": "https://api.github.com/users/kohsuke/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/kohsuke/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "gastaldi",
+    "id": 54133,
+    "node_id": "MDQ6VXNlcjU0MTMz",
+    "avatar_url": "https://avatars.githubusercontent.com/u/54133?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/gastaldi",
+    "html_url": "https://github.com/gastaldi",
+    "followers_url": "https://api.github.com/users/gastaldi/followers",
+    "following_url": "https://api.github.com/users/gastaldi/following{/other_user}",
+    "gists_url": "https://api.github.com/users/gastaldi/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/gastaldi/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/gastaldi/subscriptions",
+    "organizations_url": "https://api.github.com/users/gastaldi/orgs",
+    "repos_url": "https://api.github.com/users/gastaldi/repos",
+    "events_url": "https://api.github.com/users/gastaldi/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/gastaldi/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "halkeye",
+    "id": 110087,
+    "node_id": "MDQ6VXNlcjExMDA4Nw==",
+    "avatar_url": "https://avatars.githubusercontent.com/u/110087?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/halkeye",
+    "html_url": "https://github.com/halkeye",
+    "followers_url": "https://api.github.com/users/halkeye/followers",
+    "following_url": "https://api.github.com/users/halkeye/following{/other_user}",
+    "gists_url": "https://api.github.com/users/halkeye/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/halkeye/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/halkeye/subscriptions",
+    "organizations_url": "https://api.github.com/users/halkeye/orgs",
+    "repos_url": "https://api.github.com/users/halkeye/repos",
+    "events_url": "https://api.github.com/users/halkeye/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/halkeye/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "tedyoung",
+    "id": 382660,
+    "node_id": "MDQ6VXNlcjM4MjY2MA==",
+    "avatar_url": "https://avatars.githubusercontent.com/u/382660?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/tedyoung",
+    "html_url": "https://github.com/tedyoung",
+    "followers_url": "https://api.github.com/users/tedyoung/followers",
+    "following_url": "https://api.github.com/users/tedyoung/following{/other_user}",
+    "gists_url": "https://api.github.com/users/tedyoung/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/tedyoung/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/tedyoung/subscriptions",
+    "organizations_url": "https://api.github.com/users/tedyoung/orgs",
+    "repos_url": "https://api.github.com/users/tedyoung/repos",
+    "events_url": "https://api.github.com/users/tedyoung/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/tedyoung/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "mrginglymus",
+    "id": 390569,
+    "node_id": "MDQ6VXNlcjM5MDU2OQ==",
+    "avatar_url": "https://avatars.githubusercontent.com/u/390569?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/mrginglymus",
+    "html_url": "https://github.com/mrginglymus",
+    "followers_url": "https://api.github.com/users/mrginglymus/followers",
+    "following_url": "https://api.github.com/users/mrginglymus/following{/other_user}",
+    "gists_url": "https://api.github.com/users/mrginglymus/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/mrginglymus/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/mrginglymus/subscriptions",
+    "organizations_url": "https://api.github.com/users/mrginglymus/orgs",
+    "repos_url": "https://api.github.com/users/mrginglymus/repos",
+    "events_url": "https://api.github.com/users/mrginglymus/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/mrginglymus/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "cmoulliard",
+    "id": 463790,
+    "node_id": "MDQ6VXNlcjQ2Mzc5MA==",
+    "avatar_url": "https://avatars.githubusercontent.com/u/463790?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/cmoulliard",
+    "html_url": "https://github.com/cmoulliard",
+    "followers_url": "https://api.github.com/users/cmoulliard/followers",
+    "following_url": "https://api.github.com/users/cmoulliard/following{/other_user}",
+    "gists_url": "https://api.github.com/users/cmoulliard/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/cmoulliard/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/cmoulliard/subscriptions",
+    "organizations_url": "https://api.github.com/users/cmoulliard/orgs",
+    "repos_url": "https://api.github.com/users/cmoulliard/repos",
+    "events_url": "https://api.github.com/users/cmoulliard/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/cmoulliard/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "farmdawgnation",
+    "id": 620189,
+    "node_id": "MDQ6VXNlcjYyMDE4OQ==",
+    "avatar_url": "https://avatars.githubusercontent.com/u/620189?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/farmdawgnation",
+    "html_url": "https://github.com/farmdawgnation",
+    "followers_url": "https://api.github.com/users/farmdawgnation/followers",
+    "following_url": "https://api.github.com/users/farmdawgnation/following{/other_user}",
+    "gists_url": "https://api.github.com/users/farmdawgnation/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/farmdawgnation/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/farmdawgnation/subscriptions",
+    "organizations_url": "https://api.github.com/users/farmdawgnation/orgs",
+    "repos_url": "https://api.github.com/users/farmdawgnation/repos",
+    "events_url": "https://api.github.com/users/farmdawgnation/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/farmdawgnation/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "alexanderrtaylor",
+    "id": 852179,
+    "node_id": "MDQ6VXNlcjg1MjE3OQ==",
+    "avatar_url": "https://avatars.githubusercontent.com/u/852179?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/alexanderrtaylor",
+    "html_url": "https://github.com/alexanderrtaylor",
+    "followers_url": "https://api.github.com/users/alexanderrtaylor/followers",
+    "following_url": "https://api.github.com/users/alexanderrtaylor/following{/other_user}",
+    "gists_url": "https://api.github.com/users/alexanderrtaylor/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/alexanderrtaylor/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/alexanderrtaylor/subscriptions",
+    "organizations_url": "https://api.github.com/users/alexanderrtaylor/orgs",
+    "repos_url": "https://api.github.com/users/alexanderrtaylor/repos",
+    "events_url": "https://api.github.com/users/alexanderrtaylor/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/alexanderrtaylor/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "jlengrand",
+    "id": 921666,
+    "node_id": "MDQ6VXNlcjkyMTY2Ng==",
+    "avatar_url": "https://avatars.githubusercontent.com/u/921666?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/jlengrand",
+    "html_url": "https://github.com/jlengrand",
+    "followers_url": "https://api.github.com/users/jlengrand/followers",
+    "following_url": "https://api.github.com/users/jlengrand/following{/other_user}",
+    "gists_url": "https://api.github.com/users/jlengrand/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/jlengrand/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/jlengrand/subscriptions",
+    "organizations_url": "https://api.github.com/users/jlengrand/orgs",
+    "repos_url": "https://api.github.com/users/jlengrand/repos",
+    "events_url": "https://api.github.com/users/jlengrand/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/jlengrand/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "PauloMigAlmeida",
+    "id": 1011868,
+    "node_id": "MDQ6VXNlcjEwMTE4Njg=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/1011868?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/PauloMigAlmeida",
+    "html_url": "https://github.com/PauloMigAlmeida",
+    "followers_url": "https://api.github.com/users/PauloMigAlmeida/followers",
+    "following_url": "https://api.github.com/users/PauloMigAlmeida/following{/other_user}",
+    "gists_url": "https://api.github.com/users/PauloMigAlmeida/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/PauloMigAlmeida/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/PauloMigAlmeida/subscriptions",
+    "organizations_url": "https://api.github.com/users/PauloMigAlmeida/orgs",
+    "repos_url": "https://api.github.com/users/PauloMigAlmeida/repos",
+    "events_url": "https://api.github.com/users/PauloMigAlmeida/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/PauloMigAlmeida/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "gsmet",
+    "id": 1279749,
+    "node_id": "MDQ6VXNlcjEyNzk3NDk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/1279749?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/gsmet",
+    "html_url": "https://github.com/gsmet",
+    "followers_url": "https://api.github.com/users/gsmet/followers",
+    "following_url": "https://api.github.com/users/gsmet/following{/other_user}",
+    "gists_url": "https://api.github.com/users/gsmet/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/gsmet/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/gsmet/subscriptions",
+    "organizations_url": "https://api.github.com/users/gsmet/orgs",
+    "repos_url": "https://api.github.com/users/gsmet/repos",
+    "events_url": "https://api.github.com/users/gsmet/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/gsmet/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "JLLeitschuh",
+    "id": 1323708,
+    "node_id": "MDQ6VXNlcjEzMjM3MDg=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/1323708?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/JLLeitschuh",
+    "html_url": "https://github.com/JLLeitschuh",
+    "followers_url": "https://api.github.com/users/JLLeitschuh/followers",
+    "following_url": "https://api.github.com/users/JLLeitschuh/following{/other_user}",
+    "gists_url": "https://api.github.com/users/JLLeitschuh/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/JLLeitschuh/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/JLLeitschuh/subscriptions",
+    "organizations_url": "https://api.github.com/users/JLLeitschuh/orgs",
+    "repos_url": "https://api.github.com/users/JLLeitschuh/repos",
+    "events_url": "https://api.github.com/users/JLLeitschuh/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/JLLeitschuh/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "kohsuke2",
+    "id": 1329242,
+    "node_id": "MDQ6VXNlcjEzMjkyNDI=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/1329242?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/kohsuke2",
+    "html_url": "https://github.com/kohsuke2",
+    "followers_url": "https://api.github.com/users/kohsuke2/followers",
+    "following_url": "https://api.github.com/users/kohsuke2/following{/other_user}",
+    "gists_url": "https://api.github.com/users/kohsuke2/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/kohsuke2/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/kohsuke2/subscriptions",
+    "organizations_url": "https://api.github.com/users/kohsuke2/orgs",
+    "repos_url": "https://api.github.com/users/kohsuke2/repos",
+    "events_url": "https://api.github.com/users/kohsuke2/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/kohsuke2/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "ecxia",
+    "id": 1586186,
+    "node_id": "MDQ6VXNlcjE1ODYxODY=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/1586186?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/ecxia",
+    "html_url": "https://github.com/ecxia",
+    "followers_url": "https://api.github.com/users/ecxia/followers",
+    "following_url": "https://api.github.com/users/ecxia/following{/other_user}",
+    "gists_url": "https://api.github.com/users/ecxia/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/ecxia/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/ecxia/subscriptions",
+    "organizations_url": "https://api.github.com/users/ecxia/orgs",
+    "repos_url": "https://api.github.com/users/ecxia/repos",
+    "events_url": "https://api.github.com/users/ecxia/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/ecxia/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "jgangemi",
+    "id": 1831839,
+    "node_id": "MDQ6VXNlcjE4MzE4Mzk=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/1831839?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/jgangemi",
+    "html_url": "https://github.com/jgangemi",
+    "followers_url": "https://api.github.com/users/jgangemi/followers",
+    "following_url": "https://api.github.com/users/jgangemi/following{/other_user}",
+    "gists_url": "https://api.github.com/users/jgangemi/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/jgangemi/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/jgangemi/subscriptions",
+    "organizations_url": "https://api.github.com/users/jgangemi/orgs",
+    "repos_url": "https://api.github.com/users/jgangemi/repos",
+    "events_url": "https://api.github.com/users/jgangemi/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/jgangemi/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "bitwiseman",
+    "id": 1958953,
+    "node_id": "MDQ6VXNlcjE5NTg5NTM=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/1958953?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/bitwiseman",
+    "html_url": "https://github.com/bitwiseman",
+    "followers_url": "https://api.github.com/users/bitwiseman/followers",
+    "following_url": "https://api.github.com/users/bitwiseman/following{/other_user}",
+    "gists_url": "https://api.github.com/users/bitwiseman/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/bitwiseman/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/bitwiseman/subscriptions",
+    "organizations_url": "https://api.github.com/users/bitwiseman/orgs",
+    "repos_url": "https://api.github.com/users/bitwiseman/repos",
+    "events_url": "https://api.github.com/users/bitwiseman/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/bitwiseman/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "antrix190",
+    "id": 3845033,
+    "node_id": "MDQ6VXNlcjM4NDUwMzM=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/3845033?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/antrix190",
+    "html_url": "https://github.com/antrix190",
+    "followers_url": "https://api.github.com/users/antrix190/followers",
+    "following_url": "https://api.github.com/users/antrix190/following{/other_user}",
+    "gists_url": "https://api.github.com/users/antrix190/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/antrix190/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/antrix190/subscriptions",
+    "organizations_url": "https://api.github.com/users/antrix190/orgs",
+    "repos_url": "https://api.github.com/users/antrix190/repos",
+    "events_url": "https://api.github.com/users/antrix190/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/antrix190/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "asthinasthi",
+    "id": 4577101,
+    "node_id": "MDQ6VXNlcjQ1NzcxMDE=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/4577101?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/asthinasthi",
+    "html_url": "https://github.com/asthinasthi",
+    "followers_url": "https://api.github.com/users/asthinasthi/followers",
+    "following_url": "https://api.github.com/users/asthinasthi/following{/other_user}",
+    "gists_url": "https://api.github.com/users/asthinasthi/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/asthinasthi/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/asthinasthi/subscriptions",
+    "organizations_url": "https://api.github.com/users/asthinasthi/orgs",
+    "repos_url": "https://api.github.com/users/asthinasthi/repos",
+    "events_url": "https://api.github.com/users/asthinasthi/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/asthinasthi/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "ingwarsw",
+    "id": 5390156,
+    "node_id": "MDQ6VXNlcjUzOTAxNTY=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/5390156?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/ingwarsw",
+    "html_url": "https://github.com/ingwarsw",
+    "followers_url": "https://api.github.com/users/ingwarsw/followers",
+    "following_url": "https://api.github.com/users/ingwarsw/following{/other_user}",
+    "gists_url": "https://api.github.com/users/ingwarsw/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/ingwarsw/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/ingwarsw/subscriptions",
+    "organizations_url": "https://api.github.com/users/ingwarsw/orgs",
+    "repos_url": "https://api.github.com/users/ingwarsw/repos",
+    "events_url": "https://api.github.com/users/ingwarsw/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/ingwarsw/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "Sage-Pierce",
+    "id": 5396306,
+    "node_id": "MDQ6VXNlcjUzOTYzMDY=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/5396306?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/Sage-Pierce",
+    "html_url": "https://github.com/Sage-Pierce",
+    "followers_url": "https://api.github.com/users/Sage-Pierce/followers",
+    "following_url": "https://api.github.com/users/Sage-Pierce/following{/other_user}",
+    "gists_url": "https://api.github.com/users/Sage-Pierce/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/Sage-Pierce/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/Sage-Pierce/subscriptions",
+    "organizations_url": "https://api.github.com/users/Sage-Pierce/orgs",
+    "repos_url": "https://api.github.com/users/Sage-Pierce/repos",
+    "events_url": "https://api.github.com/users/Sage-Pierce/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/Sage-Pierce/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "t0m4uk1991",
+    "id": 6698785,
+    "node_id": "MDQ6VXNlcjY2OTg3ODU=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/6698785?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/t0m4uk1991",
+    "html_url": "https://github.com/t0m4uk1991",
+    "followers_url": "https://api.github.com/users/t0m4uk1991/followers",
+    "following_url": "https://api.github.com/users/t0m4uk1991/following{/other_user}",
+    "gists_url": "https://api.github.com/users/t0m4uk1991/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/t0m4uk1991/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/t0m4uk1991/subscriptions",
+    "organizations_url": "https://api.github.com/users/t0m4uk1991/orgs",
+    "repos_url": "https://api.github.com/users/t0m4uk1991/repos",
+    "events_url": "https://api.github.com/users/t0m4uk1991/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/t0m4uk1991/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "Irialad",
+    "id": 6895648,
+    "node_id": "MDQ6VXNlcjY4OTU2NDg=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/6895648?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/Irialad",
+    "html_url": "https://github.com/Irialad",
+    "followers_url": "https://api.github.com/users/Irialad/followers",
+    "following_url": "https://api.github.com/users/Irialad/following{/other_user}",
+    "gists_url": "https://api.github.com/users/Irialad/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/Irialad/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/Irialad/subscriptions",
+    "organizations_url": "https://api.github.com/users/Irialad/orgs",
+    "repos_url": "https://api.github.com/users/Irialad/repos",
+    "events_url": "https://api.github.com/users/Irialad/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/Irialad/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "avano",
+    "id": 7081216,
+    "node_id": "MDQ6VXNlcjcwODEyMTY=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/7081216?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/avano",
+    "html_url": "https://github.com/avano",
+    "followers_url": "https://api.github.com/users/avano/followers",
+    "following_url": "https://api.github.com/users/avano/following{/other_user}",
+    "gists_url": "https://api.github.com/users/avano/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/avano/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/avano/subscriptions",
+    "organizations_url": "https://api.github.com/users/avano/orgs",
+    "repos_url": "https://api.github.com/users/avano/repos",
+    "events_url": "https://api.github.com/users/avano/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/avano/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "vahrennd",
+    "id": 8679583,
+    "node_id": "MDQ6VXNlcjg2Nzk1ODM=",
+    "avatar_url": "https://avatars.githubusercontent.com/u/8679583?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/vahrennd",
+    "html_url": "https://github.com/vahrennd",
+    "followers_url": "https://api.github.com/users/vahrennd/followers",
+    "following_url": "https://api.github.com/users/vahrennd/following{/other_user}",
+    "gists_url": "https://api.github.com/users/vahrennd/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/vahrennd/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/vahrennd/subscriptions",
+    "organizations_url": "https://api.github.com/users/vahrennd/orgs",
+    "repos_url": "https://api.github.com/users/vahrennd/repos",
+    "events_url": "https://api.github.com/users/vahrennd/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/vahrennd/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "bloslo",
+    "id": 11611189,
+    "node_id": "MDQ6VXNlcjExNjExMTg5",
+    "avatar_url": "https://avatars.githubusercontent.com/u/11611189?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/bloslo",
+    "html_url": "https://github.com/bloslo",
+    "followers_url": "https://api.github.com/users/bloslo/followers",
+    "following_url": "https://api.github.com/users/bloslo/following{/other_user}",
+    "gists_url": "https://api.github.com/users/bloslo/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/bloslo/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/bloslo/subscriptions",
+    "organizations_url": "https://api.github.com/users/bloslo/orgs",
+    "repos_url": "https://api.github.com/users/bloslo/repos",
+    "events_url": "https://api.github.com/users/bloslo/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/bloslo/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "km2018",
+    "id": 13594336,
+    "node_id": "MDQ6VXNlcjEzNTk0MzM2",
+    "avatar_url": "https://avatars.githubusercontent.com/u/13594336?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/km2018",
+    "html_url": "https://github.com/km2018",
+    "followers_url": "https://api.github.com/users/km2018/followers",
+    "following_url": "https://api.github.com/users/km2018/following{/other_user}",
+    "gists_url": "https://api.github.com/users/km2018/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/km2018/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/km2018/subscriptions",
+    "organizations_url": "https://api.github.com/users/km2018/orgs",
+    "repos_url": "https://api.github.com/users/km2018/repos",
+    "events_url": "https://api.github.com/users/km2018/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/km2018/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "akashRindhe",
+    "id": 14114123,
+    "node_id": "MDQ6VXNlcjE0MTE0MTIz",
+    "avatar_url": "https://avatars.githubusercontent.com/u/14114123?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/akashRindhe",
+    "html_url": "https://github.com/akashRindhe",
+    "followers_url": "https://api.github.com/users/akashRindhe/followers",
+    "following_url": "https://api.github.com/users/akashRindhe/following{/other_user}",
+    "gists_url": "https://api.github.com/users/akashRindhe/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/akashRindhe/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/akashRindhe/subscriptions",
+    "organizations_url": "https://api.github.com/users/akashRindhe/orgs",
+    "repos_url": "https://api.github.com/users/akashRindhe/repos",
+    "events_url": "https://api.github.com/users/akashRindhe/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/akashRindhe/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "jberglund-BSFT",
+    "id": 19560713,
+    "node_id": "MDQ6VXNlcjE5NTYwNzEz",
+    "avatar_url": "https://avatars.githubusercontent.com/u/19560713?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/jberglund-BSFT",
+    "html_url": "https://github.com/jberglund-BSFT",
+    "followers_url": "https://api.github.com/users/jberglund-BSFT/followers",
+    "following_url": "https://api.github.com/users/jberglund-BSFT/following{/other_user}",
+    "gists_url": "https://api.github.com/users/jberglund-BSFT/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/jberglund-BSFT/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/jberglund-BSFT/subscriptions",
+    "organizations_url": "https://api.github.com/users/jberglund-BSFT/orgs",
+    "repos_url": "https://api.github.com/users/jberglund-BSFT/repos",
+    "events_url": "https://api.github.com/users/jberglund-BSFT/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/jberglund-BSFT/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "timja",
+    "id": 21194782,
+    "node_id": "MDQ6VXNlcjIxMTk0Nzgy",
+    "avatar_url": "https://avatars.githubusercontent.com/u/21194782?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/timja",
+    "html_url": "https://github.com/timja",
+    "followers_url": "https://api.github.com/users/timja/followers",
+    "following_url": "https://api.github.com/users/timja/following{/other_user}",
+    "gists_url": "https://api.github.com/users/timja/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/timja/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/timja/subscriptions",
+    "organizations_url": "https://api.github.com/users/timja/orgs",
+    "repos_url": "https://api.github.com/users/timja/repos",
+    "events_url": "https://api.github.com/users/timja/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/timja/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  }
+]
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repositories_206888201_collaborators-8.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repositories_206888201_collaborators-8.json
new file mode 100644
index 000000000..7a82b8978
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/repositories_206888201_collaborators-8.json
@@ -0,0 +1,170 @@
+[
+  {
+    "login": "martinvanzijl",
+    "id": 24422213,
+    "node_id": "MDQ6VXNlcjI0NDIyMjEz",
+    "avatar_url": "https://avatars.githubusercontent.com/u/24422213?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/martinvanzijl",
+    "html_url": "https://github.com/martinvanzijl",
+    "followers_url": "https://api.github.com/users/martinvanzijl/followers",
+    "following_url": "https://api.github.com/users/martinvanzijl/following{/other_user}",
+    "gists_url": "https://api.github.com/users/martinvanzijl/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/martinvanzijl/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/martinvanzijl/subscriptions",
+    "organizations_url": "https://api.github.com/users/martinvanzijl/orgs",
+    "repos_url": "https://api.github.com/users/martinvanzijl/repos",
+    "events_url": "https://api.github.com/users/martinvanzijl/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/martinvanzijl/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "SCHJonathan",
+    "id": 26502832,
+    "node_id": "MDQ6VXNlcjI2NTAyODMy",
+    "avatar_url": "https://avatars.githubusercontent.com/u/26502832?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/SCHJonathan",
+    "html_url": "https://github.com/SCHJonathan",
+    "followers_url": "https://api.github.com/users/SCHJonathan/followers",
+    "following_url": "https://api.github.com/users/SCHJonathan/following{/other_user}",
+    "gists_url": "https://api.github.com/users/SCHJonathan/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/SCHJonathan/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/SCHJonathan/subscriptions",
+    "organizations_url": "https://api.github.com/users/SCHJonathan/orgs",
+    "repos_url": "https://api.github.com/users/SCHJonathan/repos",
+    "events_url": "https://api.github.com/users/SCHJonathan/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/SCHJonathan/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "willtsai",
+    "id": 28876888,
+    "node_id": "MDQ6VXNlcjI4ODc2ODg4",
+    "avatar_url": "https://avatars.githubusercontent.com/u/28876888?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/willtsai",
+    "html_url": "https://github.com/willtsai",
+    "followers_url": "https://api.github.com/users/willtsai/followers",
+    "following_url": "https://api.github.com/users/willtsai/following{/other_user}",
+    "gists_url": "https://api.github.com/users/willtsai/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/willtsai/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/willtsai/subscriptions",
+    "organizations_url": "https://api.github.com/users/willtsai/orgs",
+    "repos_url": "https://api.github.com/users/willtsai/repos",
+    "events_url": "https://api.github.com/users/willtsai/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/willtsai/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "Typraeurion",
+    "id": 36168707,
+    "node_id": "MDQ6VXNlcjM2MTY4NzA3",
+    "avatar_url": "https://avatars.githubusercontent.com/u/36168707?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/Typraeurion",
+    "html_url": "https://github.com/Typraeurion",
+    "followers_url": "https://api.github.com/users/Typraeurion/followers",
+    "following_url": "https://api.github.com/users/Typraeurion/following{/other_user}",
+    "gists_url": "https://api.github.com/users/Typraeurion/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/Typraeurion/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/Typraeurion/subscriptions",
+    "organizations_url": "https://api.github.com/users/Typraeurion/orgs",
+    "repos_url": "https://api.github.com/users/Typraeurion/repos",
+    "events_url": "https://api.github.com/users/Typraeurion/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/Typraeurion/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "mxandeco",
+    "id": 42962662,
+    "node_id": "MDQ6VXNlcjQyOTYyNjYy",
+    "avatar_url": "https://avatars.githubusercontent.com/u/42962662?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/mxandeco",
+    "html_url": "https://github.com/mxandeco",
+    "followers_url": "https://api.github.com/users/mxandeco/followers",
+    "following_url": "https://api.github.com/users/mxandeco/following{/other_user}",
+    "gists_url": "https://api.github.com/users/mxandeco/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/mxandeco/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/mxandeco/subscriptions",
+    "organizations_url": "https://api.github.com/users/mxandeco/orgs",
+    "repos_url": "https://api.github.com/users/mxandeco/repos",
+    "events_url": "https://api.github.com/users/mxandeco/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/mxandeco/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  },
+  {
+    "login": "tginiotis-at-work",
+    "id": 61763026,
+    "node_id": "MDQ6VXNlcjYxNzYzMDI2",
+    "avatar_url": "https://avatars.githubusercontent.com/u/61763026?v=4",
+    "gravatar_id": "",
+    "url": "https://api.github.com/users/tginiotis-at-work",
+    "html_url": "https://github.com/tginiotis-at-work",
+    "followers_url": "https://api.github.com/users/tginiotis-at-work/followers",
+    "following_url": "https://api.github.com/users/tginiotis-at-work/following{/other_user}",
+    "gists_url": "https://api.github.com/users/tginiotis-at-work/gists{/gist_id}",
+    "starred_url": "https://api.github.com/users/tginiotis-at-work/starred{/owner}{/repo}",
+    "subscriptions_url": "https://api.github.com/users/tginiotis-at-work/subscriptions",
+    "organizations_url": "https://api.github.com/users/tginiotis-at-work/orgs",
+    "repos_url": "https://api.github.com/users/tginiotis-at-work/repos",
+    "events_url": "https://api.github.com/users/tginiotis-at-work/events{/privacy}",
+    "received_events_url": "https://api.github.com/users/tginiotis-at-work/received_events",
+    "type": "User",
+    "site_admin": false,
+    "permissions": {
+      "admin": true,
+      "maintain": true,
+      "push": true,
+      "triage": true,
+      "pull": true
+    },
+    "role_name": "admin"
+  }
+]
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/user-1.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/user-1.json
new file mode 100644
index 000000000..cfe0f3a0c
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/user-1.json
@@ -0,0 +1,46 @@
+{
+  "login": "jgangemi",
+  "id": 1831839,
+  "node_id": "MDQ6VXNlcjE4MzE4Mzk=",
+  "avatar_url": "https://avatars.githubusercontent.com/u/1831839?v=4",
+  "gravatar_id": "",
+  "url": "https://api.github.com/users/jgangemi",
+  "html_url": "https://github.com/jgangemi",
+  "followers_url": "https://api.github.com/users/jgangemi/followers",
+  "following_url": "https://api.github.com/users/jgangemi/following{/other_user}",
+  "gists_url": "https://api.github.com/users/jgangemi/gists{/gist_id}",
+  "starred_url": "https://api.github.com/users/jgangemi/starred{/owner}{/repo}",
+  "subscriptions_url": "https://api.github.com/users/jgangemi/subscriptions",
+  "organizations_url": "https://api.github.com/users/jgangemi/orgs",
+  "repos_url": "https://api.github.com/users/jgangemi/repos",
+  "events_url": "https://api.github.com/users/jgangemi/events{/privacy}",
+  "received_events_url": "https://api.github.com/users/jgangemi/received_events",
+  "type": "User",
+  "site_admin": false,
+  "name": "Jae Gangemi",
+  "company": null,
+  "blog": "",
+  "location": null,
+  "email": null,
+  "hireable": null,
+  "bio": null,
+  "twitter_username": null,
+  "public_repos": 39,
+  "public_gists": 1,
+  "followers": 1,
+  "following": 0,
+  "created_at": "2012-06-08T19:54:02Z",
+  "updated_at": "2022-03-09T12:59:44Z",
+  "private_gists": 0,
+  "total_private_repos": 9,
+  "owned_private_repos": 9,
+  "disk_usage": 16623,
+  "collaborators": 0,
+  "two_factor_authentication": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "collaborators": 0,
+    "private_repos": 10000
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/users_jgangemi-9.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/users_jgangemi-9.json
new file mode 100644
index 000000000..cfe0f3a0c
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/__files/users_jgangemi-9.json
@@ -0,0 +1,46 @@
+{
+  "login": "jgangemi",
+  "id": 1831839,
+  "node_id": "MDQ6VXNlcjE4MzE4Mzk=",
+  "avatar_url": "https://avatars.githubusercontent.com/u/1831839?v=4",
+  "gravatar_id": "",
+  "url": "https://api.github.com/users/jgangemi",
+  "html_url": "https://github.com/jgangemi",
+  "followers_url": "https://api.github.com/users/jgangemi/followers",
+  "following_url": "https://api.github.com/users/jgangemi/following{/other_user}",
+  "gists_url": "https://api.github.com/users/jgangemi/gists{/gist_id}",
+  "starred_url": "https://api.github.com/users/jgangemi/starred{/owner}{/repo}",
+  "subscriptions_url": "https://api.github.com/users/jgangemi/subscriptions",
+  "organizations_url": "https://api.github.com/users/jgangemi/orgs",
+  "repos_url": "https://api.github.com/users/jgangemi/repos",
+  "events_url": "https://api.github.com/users/jgangemi/events{/privacy}",
+  "received_events_url": "https://api.github.com/users/jgangemi/received_events",
+  "type": "User",
+  "site_admin": false,
+  "name": "Jae Gangemi",
+  "company": null,
+  "blog": "",
+  "location": null,
+  "email": null,
+  "hireable": null,
+  "bio": null,
+  "twitter_username": null,
+  "public_repos": 39,
+  "public_gists": 1,
+  "followers": 1,
+  "following": 0,
+  "created_at": "2012-06-08T19:54:02Z",
+  "updated_at": "2022-03-09T12:59:44Z",
+  "private_gists": 0,
+  "total_private_repos": 9,
+  "owned_private_repos": 9,
+  "disk_usage": 16623,
+  "collaborators": 0,
+  "two_factor_authentication": true,
+  "plan": {
+    "name": "free",
+    "space": 976562499,
+    "collaborators": 0,
+    "private_repos": 10000
+  }
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/orgs_hub4j-test-org-2.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/orgs_hub4j-test-org-2.json
new file mode 100644
index 000000000..26879bb37
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/orgs_hub4j-test-org-2.json
@@ -0,0 +1,48 @@
+{
+  "id": "e6a881ae-37d1-4d13-bfd5-ea974753e28f",
+  "name": "orgs_hub4j-test-org",
+  "request": {
+    "url": "/orgs/hub4j-test-org",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "orgs_hub4j-test-org-2.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:42:19 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"9c48b6d97946cc9cca7a7eba9df130c47c977fea9e3ed36222d79a378e2ff6c8\"",
+      "Last-Modified": "Thu, 04 Jun 2020 05:56:10 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "admin:org, read:org, repo, user, write:org",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4952",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "48",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "CECF:0B4E:46D1E:3FF6B7:624D98BB"
+    }
+  },
+  "uuid": "e6a881ae-37d1-4d13-bfd5-ea974753e28f",
+  "persistent": true,
+  "insertionIndex": 2
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api-3.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api-3.json
new file mode 100644
index 000000000..6db0fa4ec
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api-3.json
@@ -0,0 +1,48 @@
+{
+  "id": "49521425-2e5f-42ad-b3e8-303ec0024cda",
+  "name": "repos_hub4j-test-org_github-api",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repos_hub4j-test-org_github-api-3.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:42:20 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"f659ce60400fb1f0bd592ef4533029ee2aca8f3785088fc086eb3c10b2548f0f\"",
+      "Last-Modified": "Tue, 09 Nov 2021 20:13:29 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "repo",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4951",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "49",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "CED2:7498:A2B7E0:1606203:624D98BC"
+    }
+  },
+  "uuid": "49521425-2e5f-42ad-b3e8-303ec0024cda",
+  "persistent": true,
+  "insertionIndex": 3
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators-7.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators-7.json
new file mode 100644
index 000000000..f5c02809d
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators-7.json
@@ -0,0 +1,48 @@
+{
+  "id": "f869dcab-3062-4b39-837f-c3040ae909e7",
+  "name": "repos_hub4j-test-org_github-api_collaborators",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api/collaborators",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repos_hub4j-test-org_github-api_collaborators-7.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:45:49 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"c25154dd632007731047bdcf4bd2d6efa956d93da1ff3ec63eb726b5a954531d\"",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4945",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "55",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "CF41:5446:1F1E10:47661E:624D998D",
+      "Link": "<https://api.github.com/repositories/206888201/collaborators?page=2>; rel=\"next\", <https://api.github.com/repositories/206888201/collaborators?page=2>; rel=\"last\""
+    }
+  },
+  "uuid": "f869dcab-3062-4b39-837f-c3040ae909e7",
+  "persistent": true,
+  "insertionIndex": 7
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-4.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-4.json
new file mode 100644
index 000000000..fe1c414aa
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-4.json
@@ -0,0 +1,49 @@
+{
+  "id": "c26dd0b4-763d-4813-ab2e-127a0c97eddd",
+  "name": "repos_hub4j-test-org_github-api_collaborators_jgangemi",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api/collaborators/jgangemi",
+    "method": "PUT",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"permission\":{\"permission\":\"push\"}}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 422,
+    "body": "{\"message\":\"`{\\\"permission\\\"=>\\\"push\\\"}` is not a valid permission.\",\"documentation_url\":\"https://docs.github.com/rest/reference/repos#add-a-repository-collaborator\"}",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:42:20 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4950",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "50",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "Vary": "Accept-Encoding, Accept, X-Requested-With",
+      "X-GitHub-Request-Id": "CED3:2769:C8D357:235265D:624D98BC"
+    }
+  },
+  "uuid": "c26dd0b4-763d-4813-ab2e-127a0c97eddd",
+  "persistent": true,
+  "insertionIndex": 4
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-5.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-5.json
new file mode 100644
index 000000000..f9e6b7ca0
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-5.json
@@ -0,0 +1,49 @@
+{
+  "id": "eeea5e22-2c68-417a-9303-11e9bfb7ecfa",
+  "name": "repos_hub4j-test-org_github-api_collaborators_jgangemi",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api/collaborators/jgangemi",
+    "method": "PUT",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"permission\":{\"permission\":\"pull\"}}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 422,
+    "body": "{\"message\":\"`{\\\"permission\\\"=>\\\"pull\\\"}` is not a valid permission.\",\"documentation_url\":\"https://docs.github.com/rest/reference/repos#add-a-repository-collaborator\"}",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:43:42 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4948",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "52",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "Vary": "Accept-Encoding, Accept, X-Requested-With",
+      "X-GitHub-Request-Id": "CF05:6F76:B645E4:22C8480:624D990D"
+    }
+  },
+  "uuid": "eeea5e22-2c68-417a-9303-11e9bfb7ecfa",
+  "persistent": true,
+  "insertionIndex": 5
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-6.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-6.json
new file mode 100644
index 000000000..c88ef394a
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repos_hub4j-test-org_github-api_collaborators_jgangemi-6.json
@@ -0,0 +1,47 @@
+{
+  "id": "b78ec5d5-f584-4e81-9080-81779618a93f",
+  "name": "repos_hub4j-test-org_github-api_collaborators_jgangemi",
+  "request": {
+    "url": "/repos/hub4j-test-org/github-api/collaborators/jgangemi",
+    "method": "PUT",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    },
+    "bodyPatterns": [
+      {
+        "equalToJson": "{\"permission\":\"pull\"}",
+        "ignoreArrayOrder": true,
+        "ignoreExtraElements": false
+      }
+    ]
+  },
+  "response": {
+    "status": 204,
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:45:49 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4946",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "54",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "Vary": "Accept-Encoding, Accept, X-Requested-With",
+      "X-GitHub-Request-Id": "CF40:2961:245341:6DD416:624D998D"
+    }
+  },
+  "uuid": "b78ec5d5-f584-4e81-9080-81779618a93f",
+  "persistent": true,
+  "insertionIndex": 6
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repositories_206888201_collaborators-8.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repositories_206888201_collaborators-8.json
new file mode 100644
index 000000000..562dda67c
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/repositories_206888201_collaborators-8.json
@@ -0,0 +1,48 @@
+{
+  "id": "c8638ef3-63c7-4b98-809e-2c913a8a0024",
+  "name": "repositories_206888201_collaborators",
+  "request": {
+    "url": "/repositories/206888201/collaborators?page=2",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "repositories_206888201_collaborators-8.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:45:50 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"b22e9856582486f7298b3d23070cba87c85eeafac7a9f278d691918b66657310\"",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4944",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "56",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "CF42:0EAE:3AF067:6D2595:624D998D",
+      "Link": "<https://api.github.com/repositories/206888201/collaborators?page=1>; rel=\"prev\", <https://api.github.com/repositories/206888201/collaborators?page=1>; rel=\"first\""
+    }
+  },
+  "uuid": "c8638ef3-63c7-4b98-809e-2c913a8a0024",
+  "persistent": true,
+  "insertionIndex": 8
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/user-1.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/user-1.json
new file mode 100644
index 000000000..14c5d747d
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/user-1.json
@@ -0,0 +1,48 @@
+{
+  "id": "841c9e73-8c02-4018-9e1c-719ac32be0c8",
+  "name": "user",
+  "request": {
+    "url": "/user",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "user-1.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:42:18 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"65ac0e73527e3adc4df6bbbde94bb21480926587df8832f0bab8a5fc1bc746c9\"",
+      "Last-Modified": "Wed, 09 Mar 2022 12:59:44 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4954",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "46",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "CEC4:4546:1199788:2196458:624D98BA"
+    }
+  },
+  "uuid": "841c9e73-8c02-4018-9e1c-719ac32be0c8",
+  "persistent": true,
+  "insertionIndex": 1
+}
\ No newline at end of file
diff --git a/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/users_jgangemi-9.json b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/users_jgangemi-9.json
new file mode 100644
index 000000000..67731bf89
--- /dev/null
+++ b/src/test/resources/org/kohsuke/github/GHRepositoryTest/wiremock/addCollaboratorsRepoPerm/mappings/users_jgangemi-9.json
@@ -0,0 +1,48 @@
+{
+  "id": "a38d6471-c0b3-43d9-994e-bd253670bea3",
+  "name": "users_jgangemi",
+  "request": {
+    "url": "/users/jgangemi",
+    "method": "GET",
+    "headers": {
+      "Accept": {
+        "equalTo": "application/vnd.github.v3+json"
+      }
+    }
+  },
+  "response": {
+    "status": 200,
+    "bodyFileName": "users_jgangemi-9.json",
+    "headers": {
+      "Server": "GitHub.com",
+      "Date": "Wed, 06 Apr 2022 13:45:50 GMT",
+      "Content-Type": "application/json; charset=utf-8",
+      "Cache-Control": "private, max-age=60, s-maxage=60",
+      "Vary": [
+        "Accept, Authorization, Cookie, X-GitHub-OTP",
+        "Accept-Encoding, Accept, X-Requested-With"
+      ],
+      "ETag": "W/\"65ac0e73527e3adc4df6bbbde94bb21480926587df8832f0bab8a5fc1bc746c9\"",
+      "Last-Modified": "Wed, 09 Mar 2022 12:59:44 GMT",
+      "X-OAuth-Scopes": "admin:public_key, admin:repo_hook, delete_repo, repo, user, workflow",
+      "X-Accepted-OAuth-Scopes": "",
+      "github-authentication-token-expiration": "2022-05-06 06:00:00 UTC",
+      "X-GitHub-Media-Type": "github.v3; format=json",
+      "X-RateLimit-Limit": "5000",
+      "X-RateLimit-Remaining": "4943",
+      "X-RateLimit-Reset": "1649254722",
+      "X-RateLimit-Used": "57",
+      "X-RateLimit-Resource": "core",
+      "Strict-Transport-Security": "max-age=31536000; includeSubdomains; preload",
+      "X-Frame-Options": "deny",
+      "X-Content-Type-Options": "nosniff",
+      "X-XSS-Protection": "0",
+      "Referrer-Policy": "origin-when-cross-origin, strict-origin-when-cross-origin",
+      "Content-Security-Policy": "default-src 'none'",
+      "X-GitHub-Request-Id": "CF43:6B70:374C2E:67A0E8:624D998E"
+    }
+  },
+  "uuid": "a38d6471-c0b3-43d9-994e-bd253670bea3",
+  "persistent": true,
+  "insertionIndex": 9
+}
\ No newline at end of file