Vcs
This endpoint is used to create, update, search or delete vcs (version control system) information inside a Terrakube organization so you can connect to private git repositories to run modules and workspaces
To use this endpoint you should have "manageVcs" access at team level and a Terrakube Organization
Entity fields:
data.type
string
Should be "vcs"
data.attributes.name
string
Unique vcs name for an Terrakube organization
data.attributes.description
string
Free text for description
data.attributes.vcsType
string
Supported values: GITHUB, GITLAB, BITBUCKET, AZURE_DEVOPS
data.attributes.clientID
string
Client Application Id
data.attributes.clientSecret
string
Client Application secret
Example:
{
"data": {
"type": "vcs",
"attributes": {
"name": "GitHubConnection",
"description": "Private repositories inside GitHub",
"vcsType": "GITHUB",
"clientId": "{{githubClientId}}",
"clientSecret": "{{githubClientSecret}}"
}
}
}
Supported Operations
Returns an instance of type vcs
organization Identifier
vcs Identifier
GET /api/v1/organization/{organizationId}/vcs/{vcsId} HTTP/1.1
Host:
Accept: */*
Successful response
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"accessToken": "text",
"clientId": "text",
"clientSecret": "text",
"description": "text",
"name": "text",
"vcsType": "GITHUB"
},
"relationships": {
"organization": {
"id": "text",
"type": "organization"
}
}
},
"included": [
{
"attributes": {},
"id": "text",
"relationships": {},
"type": "text"
}
]
}
Creates an item of type vcs and adds it to vcs
organization Identifier
POST /api/v1/organization/{organizationId}/vcs HTTP/1.1
Host:
Content-Type: application/vnd.api+json
Accept: */*
Content-Length: 235
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"accessToken": "text",
"clientId": "text",
"clientSecret": "text",
"description": "text",
"name": "text",
"vcsType": "GITHUB"
},
"relationships": {
"organization": {
"id": "text",
"type": "organization"
}
}
}
}
Successful response
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"accessToken": "text",
"clientId": "text",
"clientSecret": "text",
"description": "text",
"name": "text",
"vcsType": "GITHUB"
},
"relationships": {
"organization": {
"id": "text",
"type": "organization"
}
}
}
}
Deletes an instance of type vcs
organization Identifier
vcs Identifier
DELETE /api/v1/organization/{organizationId}/vcs/{vcsId} HTTP/1.1
Host:
Accept: */*
Successful response
No content
Modifies an instance of type vcs
organization Identifier
vcs Identifier
PATCH /api/v1/organization/{organizationId}/vcs/{vcsId} HTTP/1.1
Host:
Content-Type: application/vnd.api+json
Accept: */*
Content-Length: 235
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"accessToken": "text",
"clientId": "text",
"clientSecret": "text",
"description": "text",
"name": "text",
"vcsType": "GITHUB"
},
"relationships": {
"organization": {
"id": "text",
"type": "organization"
}
}
}
}
Successful response
No content
Last updated
Was this helpful?