Database Schema
This contains APIs for performing CRUD operations on Database Schema Entity
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.
Parameter on the basis of which sorting is done.
createdPossible values: Order on the basis of which sorting is done.
DESCPossible values: DB Migration tool type
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.
Response body for List Database Schema
Error Response body
Error Response body
Error Response body
GET /v1/orgs/{org}/projects/{project}/dbschema HTTP/1.1
Accept: */*
[
{
"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
}
]Create a database schema
Organization identifier
Project identifier
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.
Database Schema Request
identifier of the database schema
^[a-zA-Z_][0-9a-zA-Z_$]{0,127}$DB Migration tool type
LiquibasePossible values: name of the database schema
harness service corresponding to database schema
harness_servicedb schema type
if percona-toolkit to be enabled
falseResponse body for Database Schema
Database Schema Response
epoch seconds when the database schema was created
identifier of the database schema
number of database instances corresponding to database schema
DB Migration tool type
LiquibasePossible values: name of the database schema
parentUniqueId for scope schema belongs to
Identifier for the primary dbInstance used for advanced feature like LLM Authoring etc.
harness service corresponding to database schema
db schema type
epoch seconds when the database schema was last updated
if percona-toolkit is enabled
falseError Response body
Error Response body
Error Response body
Error Response body
POST /v1/orgs/{org}/projects/{project}/dbschema HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 624
{
"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"
}
},
"identifier": "text",
"migrationType": "Liquibase",
"name": "text",
"service": "harness_service",
"tags": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"type": "Repository",
"usePercona": false
}{
"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
}Retrieves the specified database schema
Organization identifier
Project identifier
Identifier of the database 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.
Response body for Database Schema
Database Schema Response
epoch seconds when the database schema was created
identifier of the database schema
number of database instances corresponding to database schema
DB Migration tool type
LiquibasePossible values: name of the database schema
parentUniqueId for scope schema belongs to
Identifier for the primary dbInstance used for advanced feature like LLM Authoring etc.
harness service corresponding to database schema
db schema type
epoch seconds when the database schema was last updated
if percona-toolkit is enabled
falseError Response body
Error Response body
Error Response body
Error Response body
GET /v1/orgs/{org}/projects/{project}/dbschema/{dbschema} HTTP/1.1
Accept: */*
{
"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
}Update a database schema
Organization identifier
Project identifier
Identifier of the database 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.
name of the database schema
This is the primary db instance identifier for advanced feature like LLM Authoring etc.
harness service corresponding to database schema
harness_servicedb schema type
if percona-tookit is enabled
Response body for Database Schema
Database Schema Response
epoch seconds when the database schema was created
identifier of the database schema
number of database instances corresponding to database schema
DB Migration tool type
LiquibasePossible values: name of the database schema
parentUniqueId for scope schema belongs to
Identifier for the primary dbInstance used for advanced feature like LLM Authoring etc.
harness service corresponding to database schema
db schema type
epoch seconds when the database schema was last updated
if percona-toolkit is enabled
falseError Response body
Error Response body
Error Response body
Error Response body
PUT /v1/orgs/{org}/projects/{project}/dbschema/{dbschema} HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 587
{
"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": "text",
"toml": "text"
},
"cloneResources": {
"limits": {
"cpu": "400m",
"memory": "500Mi"
}
},
"name": "text",
"primaryDbInstanceId": "text",
"service": "harness_service",
"tags": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"type": "Repository",
"usePercona": true
}{
"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
}Delete a database schema
Organization identifier
Project identifier
Identifier of the database 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.
The database schema was deleted successfully
No content
Error Response body
Error Response body
Error Response body
Error Response body
DELETE /v1/orgs/{org}/projects/{project}/dbschema/{dbschema} HTTP/1.1
Accept: */*
No content
Update a database instance
Organization identifier
Project identifier
Identifier of the database schema
database instance unique id
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.
branch where the instance is stored
Commit SHA to pin the changelog to a specific revision. Mutually exclusive with branch and gitTag.
DB Connector
Liquibase context
Git tag to pin the changelog to a specific tagged revision. Mutually exclusive with branch and commitSha.
name of the database instance
version of the changelog applied to the database
Response body for Database Instance
Database Instance Response
branch where the instance is stored
commit SHA to pin the changelog to a specific revision
DB Connector
Liquibase context
epoch seconds when the database instance was created
Git tag to pin the changelog to a specific tagged revision
identifier of the database instance
Most recent tag applied to the database
Tag on last deployed changeSet
name of the database instance
epoch seconds when the database instance was last updated
Error Response body
Error Response body
Error Response body
Error Response body
PUT /v1/orgs/{org}/projects/{project}/dbschema/{dbschema}/instance/{dbinstance} HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 126
{
"branch": "string",
"connector": "string",
"context": "string",
"name": "string",
"tags": {
"property1": "string",
"property2": "string"
}
}{
"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
}Last updated
Was this helpful?