POST
/
v1
/
teams
/
{teamId}
/
request
import { Vercel } from "@vercel/sdk";

const vercel = new Vercel({
  bearerToken: "<YOUR_BEARER_TOKEN_HERE>",
});

async function run() {
  const result = await vercel.teams.requestAccessToTeam({
    teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l",
    requestBody: {
      joinedFrom: {
        origin: "github",
        commitId: "f498d25d8bd654b578716203be73084b31130cd7",
        repoId: "67753070",
        repoPath: "jane-doe/example",
        gitUserId: 103053343,
        gitUserLogin: "jane-doe",
      },
    },
  });

  // Handle the result
  console.log(result);
}

run();
{
  "teamSlug": "<string>",
  "teamName": "<string>",
  "confirmed": true,
  "joinedFrom": {
    "origin": "import",
    "commitId": "<string>",
    "repoId": "<string>",
    "repoPath": "<string>",
    "gitUserId": "<string>",
    "gitUserLogin": "<string>",
    "ssoUserId": "<string>",
    "ssoConnectedAt": 123,
    "idpUserId": "<string>",
    "dsyncUserId": "<string>",
    "dsyncConnectedAt": 123
  },
  "accessRequestedAt": 123,
  "github": {
    "login": "<string>"
  },
  "gitlab": {
    "login": "<string>"
  },
  "bitbucket": {
    "login": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Default authentication mechanism

Path Parameters

teamId
string
required

The unique team identifier

Example:

"team_1a2b3c4d5e6f7g8h9i0j1k2l"

Body

application/json
joinedFrom
object
required

Response

200
application/json
Successfuly requested access to the team.
teamSlug
string
required
teamName
string
required
github
object | null
required
gitlab
object | null
required
bitbucket
object | null
required
confirmed
boolean
joinedFrom
object
accessRequestedAt
number