diff --git a/source/_static/api/deployer.html b/source/_static/api/deployer.html index 877bfe3cf..608215839 100644 --- a/source/_static/api/deployer.html +++ b/source/_static/api/deployer.html @@ -392,7 +392,7 @@ -

Crafter Deployer (4.5.1)

Download OpenAPI specification:

E-mail: info@craftercms.org License: GPL 3.0

Crafter Deployer (5.0.0)

Download OpenAPI specification:

E-mail: info@craftercms.org License: GPL 3.0

Crafter Deployer API

-

target

Target management operations

+

target

Target management operations

Create a Crafter Deployer target

Module: Deployer
-Target creation is based on templates. The deployer comes with two out of the box: remote and local. The remote template creates targets that pull changes from a remote Git repository, making it ideal to create targets for delivery environments. The local template instead generates targets that use a local Git repo and the last processed commit to infer the changes, without executing a pull, so it’s used mostly to create targets for authoring environments.

If a target already exists and replace is true, then the new target will replace the existing one. If replace is false and the target exists, a 409 is returned.

+"Target creation is based on templates. The deployer comes with two out of the box: remote and local. The remote template creates targets that pull changes from a remote Git repository, making it ideal to create targets for delivery environments. The local template instead generates targets that use a local Git repo and the last processed commit to infer the changes, without executing a pull, so it's used mostly to create targets for authoring environments.

If a target already exists and replace is true, then the new target will replace the existing one. If replace is false and the target exists, a 409 is returned."

Request Body schema: application/json
required

Create target request body

-
env
required
string

The target’s environment (e.g. dev).

-
site_name
required
string

The target’s project/site name (e.g. my-editorial).

+
env
required
string

The target's environment (e.g. dev).

+
site_name
required
string

The target's project/site name (e.g. my-editorial).

replace
boolean

Replace the existing target.

template_name
string

Only use with remote template. The branch name of the remote Git repo to pull from. If not specified, the branch will be whatever branch is the current one in the remote repo.

repo_username
string

Only use with remote template. The username of the remote Git repo.

-
repo_password
string

Only use with remote template. The password of the remote Git repo.

+
repo_password
string

Only use with remote template. The username of the remote Git repo.

ssh_private_key_path
string

Only use with remote template. The path for the private key used for the remote Git repo.

ssh_private_key_passphrase
string

Module: Deployer

{
  • "env": "preview",
  • "site_name": "my-editorial",
  • "replace": true,
  • "disable_deploy_cron": true,
  • "template_name": "local",
  • "repo_url": "/opt/crafter/data/repos/sites/my-editorial/sandbox",
  • "engine_url": "http://localhost:8080"
}

Response samples

Content type
application/json
{
  • "message": "OK"
}

Get a Crafter Deployer target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

Responses

Response samples

Content type
application/json
{
  • "env": "dev",
  • "siteName": "editorial",
  • "id": "editorial-dev",
  • "load_date": "2023-01-26T10:00:01.234-05:00",
  • "status": "INIT_COMPLETED"
}

Get all Crafter Deployer targets.

Response samples

Content type
application/json
{
  • "env": "dev",
  • "siteName": "editorial",
  • "id": "editorial-dev",
  • "load_date": "2023-01-26T10:00:1.234-05:00",
  • "status": "INIT_COMPLETED"
}

Get all Crafter Deployer targets.

Module: Deployer

Responses

Response samples

Content type
application/json
[
  • {
    },
  • {
    }
]

Delete a Crafter Deployer target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

Responses

Response samples

Content type
application/json
{
  • "message": "Target not found"
}

Delete a Crafter Deployer target if it exists.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

Responses

Response samples

Content type
application/json
{
  • "message": "Target not found"
}

Deploy a Crafter Deployer target.

503

Service unavailable

+

Response samples

Content type
application/json
{
  • "message": "Target not found"
}

Deploy a Crafter Deployer target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

Request Body schema: application/json
reprocess_all_files
boolean

If all files in all the target repos should be reprocessed.

from_commit_id
string

The id of the commit to start processing changes

Available since version 4.0.0

-
deployment_mode
string

The deployment mode to execute. Possible values:
   PUBLISH: All processors will run
   SEARCH_INDEX: Only the indexing processor will run

Available since version 4.0.0

+
deployment_mode
string

The deployment mode to execute. Possible values:
nbsp;  PUBLISH: All processors will run
   SEARCH_INDEX: Only the indexing processor will run

Available since version 4.0.0

Responses

Request samples

Content type
application/json
{
  • "reprocess_all_files": true,
  • "from_commit_id": "string",
  • "deployment_mode": "string"
}

Response samples

Content type
application/json
{
  • "message": "OK"
}

Deploy all Crafter Deployer targets.

Request samples

Content type
application/json
{
  • "reprocess_all_files": true,
  • "from_commit_id": "string",
  • "deployment_mode": "string"
}

Response samples

Content type
application/json
{
  • "message": "OK"
}

Deploy all Crafter Deployer targets.

Module: Deployer

Request Body schema: application/json
reprocess_all_files
boolean

If all files in all the target repos should be reprocessed.

@@ -532,10 +532,10 @@ " class="sc-eVqvcJ sc-fszimp sc-etsjJW kIppRw jnwENr ljKHqG">

Internal server error

Request samples

Content type
application/json
{
  • "reprocess_all_files": true,
  • "deployment_mode": "string"
}

Response samples

Content type
application/json
{
  • "message": "OK"
}

Get the pending deployments for a target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

Responses

Response samples

Content type
application/json
[
  • {
    },
  • {
    }
]

Get the current deployment for a target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

Responses

Response samples

Content type
application/json
{
  • "mode": "PUBLISH",
  • "status": null,
  • "running": true,
  • "duration": null,
  • "start": "2025-03-11T17:07:00.006221-04:00",
  • "end": null,
  • "target": {
    },
  • "changeSet": {
    },
  • "processorExecutions": [
    ]
}

Get the current and pending deployments for a target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

Responses

Response samples

Content type
application/json
[
  • {
    },
  • {
    }
]

Clear git lock of a Crafter Deployer target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

query Parameters
token
required
string
Example: token=defaultManagementToken

The authorization token

Responses

Response samples

Content type
application/json
{
  • "message": "Required request parameter 'token' for method parameter type String is not present"
}

Recreate the underlying search index for a Crafter Deployer target.

Module: Deployer

-
path Parameters
env
required
string
Example: env,dev

The target’s environment (e.g. dev).

-
site_name
required
string
Example: site_name,editorial

The target’s project/site name (e.g. editorial).

+
path Parameters
env
required
string
Example: env,dev

The target's environment (e.g. dev).

+
site_name
required
string
Example: site_name,editorial

The target's project/site name (e.g. editorial).

query Parameters
token
required
string
Example: token=defaultManagementToken

The authorization token

Responses

Response samples

Content type
application/json
{
  • "message": "OK"
}

Duplicate a target

Module: Deployer

-
path Parameters
env
required
string
Example: dev

The target’s environment (e.g. dev).

+
path Parameters
env
required
string
Example: dev

The target's environment (e.g. dev).

source_site_name
required
string
Example: editorial

The source project/site name (e.g. editorial).

Request Body schema: application/json
required

Duplicate target's request body

-
env
required
string

The target’s environment (e.g. dev).

-
site_name
required
string

The target’s project/site name (e.g. my-editorial).

+
env
required
string

The target's environment (e.g. dev).

+
site_name
required
string

The target's project/site name (e.g. my-editorial).

replace
boolean

Replace the existing target.

template_name
string

Only use with remote template. The branch name of the remote Git repo to pull from. If not specified, the branch will be whatever branch is the current one in the remote repo.

repo_username
string

Only use with remote template. The username of the remote Git repo.

-
repo_password
string

Only use with remote template. The password of the remote Git repo.

+
repo_password
string

Only use with remote template. The username of the remote Git repo.

ssh_private_key_path
string

Only use with remote template. The path for the private key used for the remote Git repo.

ssh_private_key_passphrase
string

Internal server error

Request samples

Content type
application/json
{
  • "env": "string",
  • "site_name": "string",
  • "replace": true,
  • "template_name": "string",
  • "disable_deploy_cron": true,
  • "repo_url": "string",
  • "repo_branch": "string",
  • "repo_username": "string",
  • "repo_password": "string",
  • "ssh_private_key_path": "string",
  • "ssh_private_key_passphrase": "string",
  • "engine_url": "string",
  • "notification_addresses": "string",
  • "source": {
    }
}

Response samples

Content type
application/json
{
  • "message": "OK"
}

monitoring

Monitoring operations

-

Get Crafter Deployer's version details.

Get a Crafter Deployer's version details.

Module: Deployer

query Parameters
token
required
string
Example: token=defaultManagementToken

The authorization token

@@ -662,19 +662,13 @@ " class="sc-eVqvcJ sc-fszimp sc-etsjJW kIppRw jnwENr ljKHqG">

Unauthorized

Response samples

Content type
application/json
{
  • "packageName": "Crafter Deployer",
  • "packageVersion": "4.1.0-SNAPSHOT",
  • "packageBuild": "f33f1804c95dd0df4902c9732203841d22022459",
  • "packageBuildDate": "2023-04-17T21:28:40.642Z"
}

Get Crafter Deployer's system information details.

Response samples

Content type
application/json
{
  • "packageName": "Crafter Deployer",
  • "packageVersion": "4.1.0-SNAPSHOT",
  • "packageBuild": "f33f1804c95dd0df4902c9732203841d22022459",
  • "packageBuildDate": "2023-04-17T21:28:40.642Z"
}

Get a Crafter Deployer's version details.

Module: Deployer

query Parameters
token
required
string
Example: token=defaultManagementToken

The authorization token

Responses

Response samples

Content type
application/json
{
  • "packageName": "Crafter Deployer",
  • "packageVersion": "4.1.0-SNAPSHOT",
  • "packageBuild": "f33f1804c95dd0df4902c9732203841d22022459",
  • "packageBuildDate": "2023-04-17T21:28:40.642Z",
  • "osName": "Mac OS X",
  • "osVersion": "13.2.1",
  • "osArch": "x86_64",
  • "javaVersion": 17,
  • "javaVendor": "Oracle Corporation",
  • "javaVm": "OpenJDK 64-Bit Server VM"
}

Get Crafter Deployer's status details.

Response samples

Content type
application/json
{
  • "packageName": "Crafter Deployer",
  • "packageVersion": "4.1.0-SNAPSHOT",
  • "packageBuild": "f33f1804c95dd0df4902c9732203841d22022459",
  • "packageBuildDate": "2023-04-17T21:28:40.642Z",
  • "osName": "Mac OS X",
  • "osVersion": "13.2.1",
  • "osArch": "x86_64",
  • "javaVersion": 17,
  • "javaVendor": "Oracle Corporation",
  • "javaVm": "OpenJDK 64-Bit Server VM"
}

Get a Crafter Deployer's status details.

Module: Deployer

query Parameters
token
required
string
Example: token=defaultManagementToken

The authorization token

@@ -686,7 +680,7 @@ " class="sc-eVqvcJ sc-fszimp sc-etsjJW kIppRw jnwENr ljKHqG">

Unauthorized

Response samples

Content type
application/json
{
  • "StatusInfo": {
    }
}

Get Crafter Deployer's memory details.

Response samples

Content type
application/json
{
  • "StatusInfo": {
    }
}

Get a Crafter Deployer's memory details.

Module: Deployer

query Parameters
token
required
string
Example: token=defaultManagementToken

The authorization token

@@ -700,7 +694,7 @@ " class="sc-eVqvcJ sc-fszimp sc-etsjJW kIppRw jnwENr ljKHqG">

Internal server error

Response samples

Content type
application/json
{
  • "MemoryInfo": {
    }
}