Team Onboarding Connections

Get all Team Onboarding connections

Get all Team Onboarding connection resources.

GET /api/v2/team-onboarding/connections/

Query Parameters

Fields Required Description
search No Filter search queries by project id.
page_size No Page size of the returned response. Set to 10 by default.
GET /api/v2/team-onboarding/connections/ HTTP/1.1
Accept: application/json
Authorization: Token "YOUR SDE ACCESS TOKEN"
HTTP/1.1 200 OK
Content-Type: application/json

{
    "count": 2,
    "next": null,
    "previous": null,
    "results": [
        {
            "repo_id": 1,
            "project_id": 1,
            "repo_url": "https://github.com/repo_owner/repo.git",
            "repo_branch": null,
            "repo_full_name": null,
            "integration_key": 1,
            "created": "2024-01-23T18:04:36.134827-05:00"
        },
        {
            "repo_id": 2,
            "project_id": 1,
            "repo_url": "https://github.com/repo_owner/repo.git",
            "repo_branch": "main",
            "repo_full_name": "repo_owner/repo",
            "integration_key": 1,
            "created": "2024-01-23T18:31:54.867444-05:00"
        }
    ]
}

Get a specific Team Onboarding connection

Returns a single Team Onboarding connection resource, as specified by the repo_id and project_id.

GET /api/v2/team-onboarding/connections/?repo_id={repo_id}&project_id={project_id}

Query Parameters

Fields Required Description
project_id Yes The project id.
repo_id Yes The team onboarding connection id.
GET /api/v2/team-onboarding/connections/?repo_id=1&project_id=1 HTTP/1.1
Accept: application/json
Authorization: Token "YOUR SDE ACCESS TOKEN"
HTTP/1.1 200 OK
Content-Type: application/json

{
    "repo_id": 1,
    "project_id": 1,
    "repo_url": "https://github.com/repo_owner/repo.git",
    "repo_branch": null,
    "repo_full_name": "repo_owner/repo",
    "integration_key": 1,
    "created": "2024-01-23T18:04:36.134827-05:00"
}

Create a Team Onboarding connection

Creates a new Team Onboarding connection resource for a given project.

POST /api/v2/team-onboarding/connections/

Payload

Fields Required Description
project_id Yes The project id.
repo_url Yes The git repository url (HTTPS protocol).
repo_branch No The git branch associated with the connection. The default branch will be used if not provided.
repo_full_name No The full name of the git repository.
integration_key Yes The auth integration id to refer to the user's OAuth information. Only the user who created the auth integration is allowed to create the Team Onboarding connection.
POST /api/v2/team-onboarding/connections/ HTTP/1.1
Accept: application/json
Authorization: Token "YOUR SDE ACCESS TOKEN"

{
    "project_id": 1,
    "repo_url": "https://github.com/repo_owner/repo.git",
    "repo_branch": "main",
    "repo_full_name": "repo_owner/repo",
    "integration_key": 1
}
HTTP/1.1 201 CREATED
Content-Type: application/json

{
    "repo_id": 1,
    "project_id": 1,
    "repo_url": "https://github.com/repo_owner/repo.git",
    "repo_branch": "main",
    "repo_full_name": "repo_owner/repo",
    "integration_key": 1,
    "created": "2024-01-30T12:18:41.078583-05:00"
}

Update a specific Team Onboarding connection

Update a single Team Onboarding connection resource, as specified by the repo_id and project_id.

PATCH /api/v2/team-onboarding/connections/?repo_id={repo_id}&project_id={project_id}

Query Parameters

Fields Required Description
project_id Yes The project id.
repo_id Yes The team onboarding connection id.

Payload

Fields Required Description
repo_url No The git repository url.
repo_branch No The git branch associated with the connection. The default branch will be used if not provided.
repo_full_name No The full name of the git repository.
integration_key No The auth integration id to refer to the user's OAuth information. Only the user who created the auth integration is allowed to create the Team Onboarding connection.
PATCH /api/v2/team-onboarding/connections/?repo_id=1&project_id=1 HTTP/1.1
Accept: application/json
Authorization: Token "YOUR SDE ACCESS TOKEN"

{
    "repo_url": "https://github.com/repo_owner/repo.git",
    "repo_branch": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "repo_id": 1,
    "project_id": 1,
    "repo_url": "https://github.com/repo_owner/repo.git",
    "repo_branch": null,
    "repo_full_name": "repo_owner/repo",
    "integration_key": 1,
    "created": "2024-01-23T18:04:36.134827-05:00"
}

Delete a Team Onboarding connection

Deletes a Team Onboarding connection resource for a given project.

DELETE /api/v2/team-onboarding/connections/?repo_id={repo_id}&project_id={project_id}

Query Parameters

Fields Required Description
project_id Yes The project id.
repo_id Yes The team onboarding connection id.
DELETE /api/v2/team-onboarding/connections/?repo_id=1&project_id=1 HTTP/1.1
Accept: application/json
Authorization: Token "YOUR SDE ACCESS TOKEN"
HTTP/1.1 204 NO CONTENT

results matching ""

    No results matching ""