Harness NextGen Software Delivery Platform API Reference
Sending DB snapshot file from plugin to harness for capturing current state
Unique id for the snapshot of the DB
Harness command Example : Update, Rollback
UpdatePossible values: plan execution Id of the pipeline execution
stage execution id of the pipeline execution
Identifier for the Pipeline
Identifier for the DBInstance
DB Schema identifier
Harness parentUnique Id for schema
Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.
Sha256 of the content to validate on server if provided (hex-encoded)
Created
No content
Error Response body
Error Response body
Error Response body
POST /v1/dbops/metadata-snapshot/{snapshotId}?harnessCommand=Update&pipelineExecutionId=text&stageExecutionId=text&pipelineIdentifier=text&dbInstance=text&dbSchema=text&parentId=text HTTP/1.1
Content-Type: application/octet-stream
Accept: */*
Content-Length: 8
"binary"No content
List database instances
Organization identifier
Project identifier
Pagination page number strategy: Specify the page number within the paginated collection related to the number of items on each page.
0Pagination: Number of items to return.
10This would be used to filter resources having attributes matching the search term.
Order on the basis of which sorting is done.
DESCPossible values: Parameter on the basis of which sorting is done.
createdPossible values: Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.
Input for filtering instances in list API
list of '-' separated values of schema identifier and instance identifiers
list of schema identifiers to filter instances
Response body for List Database Schema
Error Response body
Error Response body
Error Response body
Error Response body
POST /v1/orgs/{org}/projects/{project}/dbinstancelist HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 54
{
"instanceFQNs": [
"text"
],
"schemaIdentifiers": [
"text"
]
}[
{
"branch": "text",
"commitSha": "text",
"connector": "text",
"context": "text",
"created": 1,
"gitTag": "text",
"identifier": "text",
"lastAppliedTag": "text",
"lastDeployedChangeSetTag": "text",
"name": "text",
"schemaId": "text",
"schemaIdentifier": "text",
"substituteProperties": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"tags": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"toOnboard": true,
"updated": 1
}
]List database schemas
Organization identifier
Project identifier
Pagination page number strategy: Specify the page number within the paginated collection related to the number of items on each page.
0Pagination: Number of items to return.
10This would be used to filter resources having attributes matching the search term.
Order on the basis of which sorting is done.
DESCPossible values: Parameter on the basis of which sorting is done.
createdPossible values: Identifier field of the account the resource is scoped to. This is required for Authorization methods other than the x-api-key header. If you are using the x-api-key header, this can be skipped.
List schema body input
list of schema identifiers
Response body for List Database Schema
Error Response body
Error Response body
Error Response body
Error Response body
POST /v1/orgs/{org}/projects/{project}/dbschemalist HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 24
{
"identifiers": [
"text"
]
}[
{
"changeLogScript": {
"command": "curl -X -o changeLog.yaml https://www.filestore.com/changeLog.yaml",
"image": "plugins/image:latest",
"location": "folder/changelog.yaml",
"shell": "Sh, Bash, <+pipeline.variables.shell>",
"toml": "text"
},
"changelog": {
"archivePath": "text",
"connector": "harness_git",
"includeAllPath": "text",
"location": "folder/changelog.yaml",
"repo": "folder/changelog.yaml",
"toml": "text"
},
"cloneResources": {
"limits": {
"cpu": "400m",
"memory": "500Mi"
}
},
"created": 1,
"identifier": "text",
"instanceCount": 1,
"migrationType": "Liquibase",
"name": "text",
"parentId": "text",
"primaryDbInstanceId": "text",
"schemaSourceType": "Git",
"service": "text",
"tags": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"type": "Repository",
"updated": 1,
"usePercona": false
}
]Last updated
Was this helpful?