Push a block
Log in to add to favouritesPOST/api/management/projects/{projectId}/blocks?autoRelease={true|false}
Parameters
Name | Parameter type | Type | Description |
---|---|---|---|
projectId(required) | path | string | The project identifier found in the project overview screen of the management console. |
release | query | boolean | Automatically release the block as soon as it has been discovered. Defaults to false. |
Responses
HTTP status code | Reason | Model |
---|---|---|
202 | Accepted | Block version |
401 | Unauthorized | Error |
404 | Project not found | Error |
422 | Validation error | Error |
500 | Internal server error | Error |
Examples
Pushing a new version of the movie-listing block
Accept: application/json
POST: /api/management/projects/movieDb/blocks/
{
"id": "movie-listing",
"projectId": "movieDb",
"image": {
"uri": "moviedb/movie-listing",
"tag": "81e13d08"
},
"source": {
"branch": "master",
"provider": "github",
"repositoryUrl": "https://github.com/moviedb/movie-listing.git",
"commit": {
"id": "81e13d08",
"message": "Implemented movie listing",
"authorEmail": "m.scorsese@film.com",
"committerEmail": "m.scorsese@film.com",
"datetime": "2021-08-09T14:05:10Z"
}
}
}
Remarks
The resource used to push a block is a subset of the final block version as the remaining properties (i.e. endpoints, static paths, etc...) are automatically 'discovered' by the publishing platform by inspecting the referenced docker image and extracting the details defined in the manifest file.