Organization

This endpoint is used to create, update, search or delete organizations information inside Terrakube.

You need to be part of the administrator Active Directory Group to work with this endpoint

Entity fields:

Path
Type
Description

data.type

string

Should be "organization"

data.attributes.name

string

Unique name in Terrakube

data.attributes.description

string

Free description

Example:

{
  "data": {
    "type": "organization",
    "attributes": {
      "name": "terrakube",
      "description": "Terrakube Organization"
    }
  }
}

Supported Operations

get

Returns the collection of type organization

Query parameters
filter[organization]stringOptional

Filters the collection of organization using a 'disjoint' RSQL expression

filterstringOptional

Filters the collection of organization using a 'joined' RSQL expression

page[number]integerOptional

Number of pages to return. Can be used with page[size]

page[size]integerOptional

Number of elements per page. Can be used with page[number]

page[offset]integerOptional

Offset from 0 to start paginating. Can be used with page[limit]

page[limit]integerOptional

Maximum number of items to return. Can be used with page[offset]

page[totals]stringOptional

For requesting total pages/records be included in the response page meta data

Responses
200
Successful response
application/vnd.api+json
get
GET /api/v1/organization HTTP/1.1
Host: 
Accept: */*
200

Successful response

{
  "data": [],
  "included": [
    {
      "attributes": {},
      "id": "text",
      "relationships": {},
      "type": "text"
    }
  ]
}
post

Creates an item of type organization

Body
Responses
201
Successful response
application/vnd.api+json
post
POST /api/v1/organization HTTP/1.1
Host: 
Content-Type: application/vnd.api+json
Accept: */*
Content-Length: 375

{
  "data": {
    "type": "text",
    "id": "text",
    "attributes": {
      "description": "text",
      "name": "text"
    },
    "relationships": {
      "job": {
        "id": "text",
        "type": "job"
      },
      "module": {
        "id": "text",
        "type": "module"
      },
      "provider": {
        "id": "text",
        "type": "provider"
      },
      "team": {
        "id": "text",
        "type": "team"
      },
      "template": {
        "id": "text",
        "type": "template"
      },
      "vcs": {
        "id": "text",
        "type": "vcs"
      },
      "workspace": {
        "id": "text",
        "type": "workspace"
      }
    }
  }
}
201

Successful response

{
  "data": {
    "type": "text",
    "id": "text",
    "attributes": {
      "description": "text",
      "name": "text"
    },
    "relationships": {
      "job": {
        "id": "text",
        "type": "job"
      },
      "module": {
        "id": "text",
        "type": "module"
      },
      "provider": {
        "id": "text",
        "type": "provider"
      },
      "team": {
        "id": "text",
        "type": "team"
      },
      "template": {
        "id": "text",
        "type": "template"
      },
      "vcs": {
        "id": "text",
        "type": "vcs"
      },
      "workspace": {
        "id": "text",
        "type": "workspace"
      }
    }
  }
}
delete

Deletes an instance of type organization

Path parameters
organizationIdanyRequired

organization Identifier

Responses
204
Successful response
delete
DELETE /api/v1/organization/{organizationId} HTTP/1.1
Host: 
Accept: */*
204

Successful response

No content

patch

Modifies an instance of type organization

Path parameters
organizationIdanyRequired

organization Identifier

Body
Responses
204
Successful response
patch
PATCH /api/v1/organization/{organizationId} HTTP/1.1
Host: 
Content-Type: application/vnd.api+json
Accept: */*
Content-Length: 375

{
  "data": {
    "type": "text",
    "id": "text",
    "attributes": {
      "description": "text",
      "name": "text"
    },
    "relationships": {
      "job": {
        "id": "text",
        "type": "job"
      },
      "module": {
        "id": "text",
        "type": "module"
      },
      "provider": {
        "id": "text",
        "type": "provider"
      },
      "team": {
        "id": "text",
        "type": "team"
      },
      "template": {
        "id": "text",
        "type": "template"
      },
      "vcs": {
        "id": "text",
        "type": "vcs"
      },
      "workspace": {
        "id": "text",
        "type": "workspace"
      }
    }
  }
}
204

Successful response

No content

For a complete list of organization operation please visit the OpenAPI specification

Last updated

Was this helpful?