> For the complete documentation index, see [llms.txt](https://developer.harness.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.harness.io/api-reference/software-delivery-agent-apis/database-devops/deployed-state.md).

# Deployed State

This contains APIs for tracking changeSet deployment status

## Get Deployed State

> Status of changeset deployment as part of execution with comparison to earlier state.

```json
{"openapi":"3.0.0","info":{"title":"Harness NextGen Software Delivery Platform API Reference","version":"1.0"},"tags":[{"description":"This contains APIs for tracking changeSet deployment status","name":"Deployed State"}],"paths":{"/v1/orgs/{org}/projects/{project}/dbschema/{dbschema}/instance/{dbinstance}/deployedState":{"post":{"description":"Status of changeset deployment as part of execution with comparison to earlier state.","operationId":"V1GetDeployedState","parameters":[{"$ref":"#/components/parameters/PageIndex"},{"$ref":"#/components/parameters/Limit"}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployedStateInput"}}}},"responses":{"200":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/DeployedStateOutput"},"type":"array"}}},"description":"Response","headers":{"X-Page-Number":{"description":"Page number in Paginated response.","schema":{"type":"integer"}},"X-Page-Size":{"description":"Maximum page size in Paginated response.","schema":{"type":"integer"}},"X-Total-Elements":{"description":"Total number of elements returned in Paginated response.","schema":{"type":"integer"}}}},"400":{"$ref":"#/components/responses/ErrorResponse"},"403":{"$ref":"#/components/responses/ErrorResponse"},"404":{"$ref":"#/components/responses/ErrorResponse"},"500":{"$ref":"#/components/responses/ErrorResponse"}},"summary":"Get Deployed State","tags":["Deployed State"]}}},"components":{"parameters":{"PageIndex":{"description":"Pagination page number strategy: Specify the page number within the paginated collection related to the number of items on each page.","in":"query","name":"page","schema":{"default":0,"format":"int64","type":"integer"}},"Limit":{"description":"Pagination: Number of items to return.","in":"query","name":"limit","schema":{"default":10,"maximum":100,"type":"integer"}}},"schemas":{"DeployedStateInput":{"description":"Input for getting execution deployed states","properties":{"pipeline":{"description":"identifier of the pipeline","type":"string"},"planExecutionId":{"type":"string"},"stageExecutionId":{"type":"string"},"startTime":{"default":0,"description":"start time of step execution","format":"int64","type":"integer"},"stepType":{"$ref":"#/components/schemas/DBStepType"}},"required":["planExecutionId","stageExecutionId","stepType","pipeline"],"title":"DeployedStateInput","type":"object"},"DBStepType":{"enum":["DBSchemaApply","DBSchemaRollback"],"title":"DBStepType","type":"string"},"DeployedStateOutput":{"description":"The status of changeset deployment","properties":{"author":{"type":"string"},"changeSetFQN":{"description":"changesetFQN is a unique identifier for database changesets in the format filename::changesetId::author","type":"string"},"changeSetId":{"type":"string"},"command":{"$ref":"#/components/schemas/Command"},"comment":{"description":"comment in changeset definition","type":"string"},"deployedAt":{"format":"int64","type":"integer"},"deployedInCurrentExecution":{"description":"if changeset run as part of current step execution","type":"boolean"},"fileName":{"type":"string"},"label":{"description":"label in changeset definition","type":"string"},"metadata":{"$ref":"#/components/schemas/ExecutionMetadata"},"status":{"$ref":"#/components/schemas/CommandExecutionStatus"},"tag":{"type":"string"}},"required":["status","changeSetId","author","fileName","command","metadata","deployedInCurrentExecution","changeSetFQN"],"title":"DeployedStateOutput","type":"object"},"Command":{"description":"Type of the plugin command to run","enum":["Update","Validate","History","Tag","Rollback","RollbackCount","RollbackCountSQL","RollbackOneChangeset","RollbackOneChangesetSQL","UpdateSQL","Clone","Custom","ParentWrapper","RollbackSQL","Status","MarkNextChangesetRan","DBOPSUpdateSQL","DBOPSRollbackSQL","DBOPSRollbackCountSQL","DBOPSSnapshot","GenerateChangelog"],"minLength":1,"title":"Command","type":"string"},"ExecutionMetadata":{"description":"Properties related to pipeline execution","properties":{"pipeline":{"type":"string"},"planExecutionId":{"type":"string"},"stageExecutionId":{"type":"string"}},"required":["pipeline","planExecutionId","stageExecutionId"],"title":"ExecutionMetadata","type":"object"},"CommandExecutionStatus":{"enum":["IN_PROGRESS","SUCCESS","FAILURE","CANCELLED"],"title":"CommandExecutionStatus","type":"string"},"Error":{"description":"Error Response","properties":{"message":{"description":"error message detail","type":"string"}},"required":["message"],"title":"Error Response","type":"object"}},"responses":{"ErrorResponse":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"description":"Error Response body"}}}}
```
