Repository endpoints

GET /api/repository/(string repoID)

Get data about the specified repository, including environments

Example response

HTTP/1.1 200 OK

{
  "id":"[repository-id]",
  "name":"drupal-test",
  "type:"gitlab",
  "gid":"[group-id]",
  "size":1234,
  "details":{
    "url":"https://...."
  }
  "environments":[
    {
      "id":"[environment-id]",
      "name":"[environment-name]",
      "gitRef":{
        "name":"develop",
        "type":"branch"
      }
    }
  ],
  "reusableEnvironments":[
    {
      "label":"reusable1",
      "buildAt":"[datetime]",
      "from":{
        "name":"develop"
      }
    }
  ]
}
Response JSON Object:
  • id (string) – Repository ID

  • gid (string) – Group ID

  • name (string) – Repository name

  • url (string) – Repository URL

  • details (dict) – Details, depends on the type of repository

  • details.url (string) – URL of the code platform repository

  • size (integer) – Repository size (the sum of environment sizes)

  • type (string) – Type of repository (generic | azure)

  • environemnts ([]environment) – Environments that belongs to this repository

  • reusableEnvironemnts ([]reusableEnvironment) – Reusable environments that are available in the repository

POST /api/repository/(string repoID)

Update repository data

Request JSON Object:
  • name (string) – new name of the repository

GET /api/repository/(string repoID)/settings

Get repository settings

Response JSON Object:
  • variables ([]variable) – List of defined custom variables

  • sshPublicKey (string) – repository SSH public key

  • environmentTTL (number) – default environment ttl set to new environments, omitted if zero

  • scheduledRebuild.mode (string) – (all | notclones | reusables | disabled) mode to use for scheduled rebuild

  • scheduledRebuild.hour (string) – hour to trigger the rebuild, in hh:mm format

  • qaackFile.mode (string) – (repo | panel | both) mode to use for qaack file generation, repo by default

  • qaackFile.qaackFile (string) – qaack file content string, yaml format is expected. Encoded as base64

POST /api/repository/(string repoID)/settings

Update repository settings

Request JSON Object:
  • environmentTTL (string) – new ttl of the repository

  • scheduledRebuild.mode (string) – (all | reusables | disabled) mode to use for scheduled rebuild

  • scheduledRebuild.hour (string) – hour to trigger the rebuild, in hh:mm format

  • qaackFile.mode (string) – (repo | panel | both) mode to use for qaack file generation, repo by default

  • qaackFile.qaackFile (string) – qaack file content string, yaml format is expected. Encoded as base64

DELETE /api/repository/(string repoID)

Delete the repository

POST /api/repository/(string repoID)/spawn

This endpoint spawns a new environment (like a clone) from a Git reference.

Request JSON Object:
  • name (string) – (optional) add a custom name to the new environment

  • build (boolean) – (optional) create a new environment and build (default to true)

  • ttl (integer) – (optional) custom time to live for the new environment

  • dict (dict gitRef)

  • gitRef.name (string) – name of the Git the reference

  • gitRef.type (string) – type of the Git the reference (branch | pull request | tag)

Response JSON Object:
  • id (string) – new environment id

  • name (string) – new environment name

  • status (string) – new environment status

  • weburl (string) – new environment public url

POST /api/repository/(string repoID)/sync

Sync the remote VCS references with the local environments

DELETE /api/repository/(string repoID)/reusable/(string reusableLabel)

Delete reusable environment

POST /api/repository/(string repoID)/variables

Create a new custom variable on the repository

Request JSON Object:
  • name (string) – name of the new variable

  • value (string) – value of the new variable

  • visibility (string) – (optional) visibility of the new variable (always | buildtime)

DELETE /api/repository/(string repoID)/variables/(string varName)

Delete a custom variable on the repository

PATCH /api/repository/(string repoID)/variables

Update the value of a custom variable on the repository

Either value or visibility required

Request JSON Object:
  • name (string) – name of the variable

  • value (string) – (optional) new value of the variable

  • visibility (string) – (optional) new visibility variable (always | buildtime)