Teams
This endpoint is used to create, update, search or delete teams information inside a Terrakube organization.
org.azbuilder.owner=TERRAKUBE_ADMINEntity fields:
data.type
string
Should be "team"
data.attributes.name
string
Active Directory Group name
data.attributes.manageWorkspace
boolean
Enable Create/Update/Delete Workspaces for a Team
data.attributes.manageModule
boolean
Enable Create/Update/Delete Workspaces for a Team
data.attributes.manageProvider
boolean
Enable Create/Update/Delete Terraform Provider for a Team
data.attributes.manageVcs
boolean
Enable Create/Update/Delete VCS connection for private GIT Repositories for a Team
data.attributes.manageTemplates
boolean
Enable Create/Update/Delete Templates for a Team
In 2.34.0, data.attributes.destroyJob controls destroy permission for Custom access and defaults to true. Admin/Write allow destroy; Plan/Read do not. See Run Restrictions.
Example:
{
"data": {
"type": "team",
"attributes": {
"name": "TERRAKUBE_TEAM",
"manageWorkspace": true,
"manageModule": true,
"manageProvider": true,
"manageVcs": true,
"manageTemplate": true
}
}
}Supported Operations
Returns an instance of type team
organization Identifier
team Identifier
Successful response
GET /api/v1/organization/{organizationId}/team/{teamId} HTTP/1.1
Host: terrakube-api.example.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
Successful response
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"approveJob": null,
"manageCollection": null,
"manageJob": null,
"manageModule": null,
"managePolicies": null,
"manageProvider": null,
"manageState": null,
"manageTemplate": null,
"manageVcs": null,
"manageWorkspace": null,
"name": null,
"planJob": null,
"role": null,
"destroyJob": null
},
"relationships": {
"organization": {
"data": [
null
]
}
}
},
"included": [
{
"type": "text",
"id": "text",
"attributes": {},
"relationships": {}
}
]
}Creates an item of type team and adds it to team
organization Identifier
Successful response
POST /api/v1/organization/{organizationId}/team HTTP/1.1
Host: terrakube-api.example.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/vnd.api+json
Accept: */*
Content-Length: 437
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"approveJob": null,
"manageCollection": null,
"manageJob": null,
"manageModule": null,
"managePolicies": null,
"manageProvider": null,
"manageState": null,
"manageTemplate": null,
"manageVcs": null,
"manageWorkspace": null,
"name": null,
"planJob": null,
"role": null,
"destroyJob": null
},
"relationships": {
"organization": {
"data": [
null
]
}
}
},
"included": [
{
"type": "text",
"id": "text",
"attributes": {},
"relationships": {}
}
]
}Successful response
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"approveJob": null,
"manageCollection": null,
"manageJob": null,
"manageModule": null,
"managePolicies": null,
"manageProvider": null,
"manageState": null,
"manageTemplate": null,
"manageVcs": null,
"manageWorkspace": null,
"name": null,
"planJob": null,
"role": null,
"destroyJob": null
},
"relationships": {
"organization": {
"data": [
null
]
}
}
},
"included": [
{
"type": "text",
"id": "text",
"attributes": {},
"relationships": {}
}
]
}Deletes an instance of type team
organization Identifier
team Identifier
Successful response
No content
DELETE /api/v1/organization/{organizationId}/team/{teamId} HTTP/1.1
Host: terrakube-api.example.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
Successful response
No content
Modifies an instance of type team
organization Identifier
team Identifier
Successful response
No content
PATCH /api/v1/organization/{organizationId}/team/{teamId} HTTP/1.1
Host: terrakube-api.example.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/vnd.api+json
Accept: */*
Content-Length: 437
{
"data": {
"type": "text",
"id": "text",
"attributes": {
"approveJob": null,
"manageCollection": null,
"manageJob": null,
"manageModule": null,
"managePolicies": null,
"manageProvider": null,
"manageState": null,
"manageTemplate": null,
"manageVcs": null,
"manageWorkspace": null,
"name": null,
"planJob": null,
"role": null,
"destroyJob": null
},
"relationships": {
"organization": {
"data": [
null
]
}
}
},
"included": [
{
"type": "text",
"id": "text",
"attributes": {},
"relationships": {}
}
]
}Successful response
No content
Last updated
Was this helpful?