# Policy Statistics

## Return a list of all statistic definitions.

> Returns a paginated list of statistic definitions owned by the current user. Optionally filter by policy instance topic ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"messageId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"status":{"type":"string","enum":["DRAFT","DRY_RUN","PUBLISHED","ERROR","ACTIVE"]},"config":{"type":"object","nullable":true,"additionalProperties":true}},"required":["name","config"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics":{"get":{"description":"Returns a paginated list of statistic definitions owned by the current user. Optionally filter by policy instance topic ID.","operationId":"PolicyStatisticsApi_getStatisticDefinitions","parameters":[{"name":"pageIndex","required":false,"in":"query","description":"The number of pages to skip before starting to collect the result set","schema":{"type":"number"}},{"name":"pageSize","required":false,"in":"query","description":"The numbers of items to return","schema":{"type":"number"}},{"name":"policyInstanceTopicId","required":false,"in":"query","description":"Policy Instance Topic Id","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation. Returns statistic definitions array and total count in X-Total-Count header.","headers":{"X-Total-Count":{"schema":{"type":"integer"},"description":"Total items in the collection."}},"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Return a list of all statistic definitions.","tags":["policy-statistics"]}}}}
```

## Creates a new statistic definition.

> Creates a new statistic definition linked to a policy. Defines metrics and rules for collecting and aggregating policy document data.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"messageId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"status":{"type":"string","enum":["DRAFT","DRY_RUN","PUBLISHED","ERROR","ACTIVE"]},"config":{"type":"object","nullable":true,"additionalProperties":true}},"required":["name","config"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics":{"post":{"description":"Creates a new statistic definition linked to a policy. Defines metrics and rules for collecting and aggregating policy document data.","operationId":"PolicyStatisticsApi_createStatisticDefinition","parameters":[],"requestBody":{"required":true,"description":"Configuration.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"responses":{"201":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Creates a new statistic definition.","tags":["policy-statistics"]}}}}
```

## Retrieves statistic definition.

> Retrieves statistic definition for the specified ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"messageId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"status":{"type":"string","enum":["DRAFT","DRY_RUN","PUBLISHED","ERROR","ACTIVE"]},"config":{"type":"object","nullable":true,"additionalProperties":true}},"required":["name","config"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}":{"get":{"description":"Retrieves statistic definition for the specified ID.","operationId":"PolicyStatisticsApi_getStatisticDefinitionById","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Retrieves statistic definition.","tags":["policy-statistics"]}}}}
```

## Updates statistic definition.

> Updates statistic definition configuration for the specified statistic ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"messageId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"status":{"type":"string","enum":["DRAFT","DRY_RUN","PUBLISHED","ERROR","ACTIVE"]},"config":{"type":"object","nullable":true,"additionalProperties":true}},"required":["name","config"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}":{"put":{"description":"Updates statistic definition configuration for the specified statistic ID.","operationId":"PolicyStatisticsApi_updateStatisticDefinition","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}}],"requestBody":{"required":true,"description":"Object that contains a configuration.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"404":{"description":"Item not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Updates statistic definition.","tags":["policy-statistics"]}}}}
```

## Deletes the statistic definition.

> Deletes the statistic definition with the provided ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}":{"delete":{"description":"Deletes the statistic definition with the provided ID.","operationId":"PolicyStatisticsApi_deleteStatisticDefinition","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"type":"boolean"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Deletes the statistic definition.","tags":["policy-statistics"]}}}}
```

## Publishes statistic definition.

> Publishes statistic definition for the specified statistic ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"messageId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"status":{"type":"string","enum":["DRAFT","DRY_RUN","PUBLISHED","ERROR","ACTIVE"]},"config":{"type":"object","nullable":true,"additionalProperties":true}},"required":["name","config"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/publish":{"put":{"description":"Publishes statistic definition for the specified statistic ID.","operationId":"PolicyStatisticsApi_publishStatisticDefinition","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"404":{"description":"Item not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Publishes statistic definition.","tags":["policy-statistics"]}}}}
```

## Retrieves statistic relationships.

> Retrieves statistic relationships for the specified ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionRelationshipsDTO":{"type":"object","properties":{"policy":{"$ref":"#/components/schemas/PolicyDTO"},"schemas":{"type":"array","items":{"$ref":"#/components/schemas/SchemaDTO"}},"schema":{"$ref":"#/components/schemas/SchemaDTO"}}},"PolicyDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"topicDescription":{"type":"string"},"applicabilityConditions":{"type":"string"},"detailsUrl":{"type":"string"},"typicalProjects":{"type":"string"},"importantParameters":{"$ref":"#/components/schemas/PolicyImportantParametersDTO"},"policyTag":{"type":"string"},"status":{"type":"string","enum":["DRY-RUN","DRAFT","PUBLISH_ERROR","PUBLISH","DISCONTINUED","DEMO","VIEW"]},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"instanceTopicId":{"type":"string"},"messageId":{"type":"string"},"availability":{"type":"string","enum":["private","public"]},"codeVersion":{"type":"string"},"tools":{"type":"array","items":{"$ref":"#/components/schemas/PolicyToolDTO"}},"createDate":{"type":"string"},"version":{"type":"string"},"originalChanged":{"type":"string"},"editableParametersSettings":{"type":"array","items":{"$ref":"#/components/schemas/PolicyEditableFieldDTO"}},"config":{"type":"object","additionalProperties":true},"userRole":{"type":"string"},"userRoles":{"type":"array","items":{"type":"string"}},"userGroup":{"type":"object","additionalProperties":true,"nullable":true,"description":"Last active group in iteration order (not a separate summary). Often shown via groupLabel or uuid."},"userGroups":{"additionalProperties":true,"description":"Full list of group rows for this user in the policy (getGroupsByUser), including inactive.","type":"array","items":{"type":"object"}},"policyRoles":{"type":"array","items":{"type":"string"}},"policyNavigation":{"additionalProperties":true,"type":"array","items":{"type":"object"}},"policyTopics":{"additionalProperties":true,"type":"array","items":{"type":"object"}},"policyTokens":{"additionalProperties":true,"type":"array","items":{"type":"object"}},"policyGroups":{"additionalProperties":true,"type":"array","items":{"type":"object"}},"policyDocumentation":{"additionalProperties":true,"description":"User-configured policy API documentation entries. The `alias` may be a single slug (`create-device`) or a path of slugs separated by `/` (`monitoring-reports/create`).","type":"array","items":{"type":"object"}},"categories":{"type":"array","items":{"type":"string"}},"projectSchema":{"type":"string"},"tests":{"type":"array","items":{"$ref":"#/components/schemas/PolicyTestDTO"}},"ignoreRules":{"description":"Validation-only rules to hide matching warnings/infos (not persisted)","type":"array","items":{"$ref":"#/components/schemas/IgnoreRuleDTO"}}},"required":["id","uuid","name","description","topicDescription","policyTag","status","creator","owner","topicId","instanceTopicId","messageId","codeVersion","tools","createDate","version","editableParametersSettings","config","userRole","userRoles","userGroup","userGroups","policyRoles","policyNavigation","policyTopics","policyTokens","policyGroups","policyDocumentation","categories","projectSchema","tests"]},"PolicyImportantParametersDTO":{"type":"object","properties":{"atValidation":{"type":"string"},"monitored":{"type":"string"}}},"PolicyToolDTO":{"type":"object","properties":{"name":{"type":"string"},"version":{"type":"string","nullable":true},"topicId":{"type":"string"},"messageId":{"type":"string"}},"required":["name","topicId","messageId"]},"PolicyEditableFieldDTO":{"type":"object","properties":{}},"PolicyTestDTO":{"type":"object","properties":{"id":{"type":"string","description":"Test ID"},"uuid":{"type":"string","description":"Test UUID"},"name":{"type":"string","description":"Test Name"},"policyId":{"type":"string","description":"Policy ID"},"owner":{"type":"string","description":"Test owner"},"status":{"type":"string","description":"Test status","enum":["New","Running","Stopped","Success","Failure"]},"date":{"type":"string","description":"Last start date"},"duration":{"type":"string","description":"Test duration"},"progress":{"type":"string","description":"Test progress"},"resultId":{"type":"string","description":"Test result"},"result":{"type":"string","description":"Test result"}},"required":["id","uuid","name","policyId","owner","status","date","duration","progress","resultId","result"]},"IgnoreRuleDTO":{"type":"object","properties":{"code":{"type":"string","description":"Stable message code, e.g. DEPRECATION_BLOCK"},"blockType":{"type":"string","description":"Limit by block type"},"property":{"type":"string","description":"Limit by property"},"contains":{"type":"string","description":"Substring filter applied to message text"},"severity":{"type":"string","description":"Type of message","enum":["warning","info"]}}},"SchemaDTO":{"type":"object","properties":{"createDate":{"type":"string","nullable":true},"updateDate":{"type":"string","nullable":true},"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"entity":{"type":"string","enum":["NONE","VC","EVC","STANDARD_REGISTRY","USER","POLICY","MINT_TOKEN","INTEGRATION_DATA_V2","RETIRE","WIPE_TOKEN","MINT_NFTOKEN","ISSUER","USER_ROLE","CHUNK","ACTIVITY_IMPACT","TOKEN_DATA_SOURCE","ROLE","USER_PERMISSIONS","POLICY_DISCUSSION_V2","POLICY_COMMENT","POLICY_EXPORT_PROOF","EVIDENCE_ATTACHMENTS"]},"iri":{"type":"string"},"status":{"type":"string","enum":["DRAFT","PUBLISHED","UNPUBLISHED","ERROR","DEMO","VIEW"]},"topicId":{"type":"string"},"version":{"type":"string"},"creator":{"type":"string","nullable":true},"owner":{"type":"string"},"messageId":{"type":"string","nullable":true},"category":{"type":"string","enum":["POLICY","MODULE","SYSTEM","TAG","TOOL","STATISTIC","LABEL"]},"documentURL":{"type":"string"},"contextURL":{"type":"string"},"document":{"oneOf":[{"type":"object","additionalProperties":true},{"type":"string"}]},"context":{"oneOf":[{"type":"object","additionalProperties":true},{"type":"string"}]},"readonly":{"type":"boolean","nullable":true},"system":{"type":"boolean","nullable":true},"active":{"type":"boolean","nullable":true},"codeVersion":{"type":"string","nullable":true},"topicCount":{"type":"number","nullable":true}},"required":["id","uuid","name","description","entity","iri","status","topicId","version","owner","category","documentURL","contextURL","document","context"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/relationships":{"get":{"description":"Retrieves statistic relationships for the specified ID.","operationId":"PolicyStatisticsApi_getStatisticRelationships","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionRelationshipsDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Retrieves statistic relationships.","tags":["policy-statistics"]}}}}
```

## Return a list of all documents.

> Returns all documents.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"VcDocumentDTO":{"type":"object","properties":{"id":{"type":"string"},"policyId":{"type":"string"},"hash":{"type":"string"},"signature":{"type":"number"},"status":{"type":"string","enum":["NEW","ISSUE","REVOKE","SUSPEND","RESUME","FAILED"]},"tag":{"type":"string"},"type":{"type":"string"},"createDate":{"type":"string"},"updateDate":{"type":"string"},"owner":{"type":"string"},"hederaStatus":{"type":"string"},"option":{"type":"object","additionalProperties":true},"topicId":{"type":"string"},"messageId":{"type":"string"},"document":{"$ref":"#/components/schemas/VcDTO"}}},"VcDTO":{"type":"object","properties":{"id":{"type":"string","nullable":true},"@context":{"type":"array","items":{"type":"string"}},"type":{"type":"array","items":{"type":"string"}},"credentialSubject":{"additionalProperties":true,"type":"array","items":{"type":"object"}},"issuer":{"oneOf":[{"type":"string"},{"type":"object","additionalProperties":true}]},"issuanceDate":{"type":"string"},"proof":{"nullable":true,"type":"object","allOf":[{"$ref":"#/components/schemas/ProofDTO"}]}},"required":["id","@context","type","credentialSubject","issuer","issuanceDate","proof"]},"ProofDTO":{"type":"object","properties":{"type":{"type":"string"},"created":{"type":"string"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string"},"jws":{"type":"string"}},"required":["type","created","verificationMethod","proofPurpose","jws"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/documents":{"get":{"description":"Returns all documents.","operationId":"PolicyStatisticsApi_getStatisticDocuments","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}},{"name":"pageIndex","required":false,"in":"query","description":"The number of pages to skip before starting to collect the result set","schema":{"type":"number"}},{"name":"pageSize","required":false,"in":"query","description":"The numbers of items to return","schema":{"type":"number"}}],"responses":{"200":{"description":"Successful operation.","headers":{"X-Total-Count":{"schema":{"type":"integer"},"description":"Total items in the collection."}},"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/VcDocumentDTO"}}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Return a list of all documents.","tags":["policy-statistics"]}}}}
```

## Return a list of all statistic assessment.

> Returns all statistic assessment.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticAssessmentDTO":{"type":"object","properties":{"id":{"type":"string"},"definitionId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"topicId":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"messageId":{"type":"string"},"target":{"type":"string"},"relationships":{"type":"array","items":{"type":"string"}},"document":{"type":"object","nullable":true,"additionalProperties":true}},"required":["document"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/assessment":{"get":{"description":"Returns all statistic assessment.","operationId":"PolicyStatisticsApi_getStatisticAssessments","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}},{"name":"pageIndex","required":false,"in":"query","description":"The number of pages to skip before starting to collect the result set","schema":{"type":"number"}},{"name":"pageSize","required":false,"in":"query","description":"The numbers of items to return","schema":{"type":"number"}}],"responses":{"200":{"description":"Successful operation.","headers":{"X-Total-Count":{"schema":{"type":"integer"},"description":"Total items in the collection."}},"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StatisticAssessmentDTO"}}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Return a list of all statistic assessment.","tags":["policy-statistics"]}}}}
```

## Creates a new statistic assessment.

> Creates a new statistic assessment.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticAssessmentDTO":{"type":"object","properties":{"id":{"type":"string"},"definitionId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"topicId":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"messageId":{"type":"string"},"target":{"type":"string"},"relationships":{"type":"array","items":{"type":"string"}},"document":{"type":"object","nullable":true,"additionalProperties":true}},"required":["document"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/assessment":{"post":{"description":"Creates a new statistic assessment.","operationId":"PolicyStatisticsApi_createStatisticAssessment","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}}],"requestBody":{"required":true,"description":"Configuration.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticAssessmentDTO"}}}},"responses":{"201":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticAssessmentDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Creates a new statistic assessment.","tags":["policy-statistics"]}}}}
```

## Retrieves statistic assessment.

> Retrieves statistic assessment for the specified ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticAssessmentDTO":{"type":"object","properties":{"id":{"type":"string"},"definitionId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"topicId":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"messageId":{"type":"string"},"target":{"type":"string"},"relationships":{"type":"array","items":{"type":"string"}},"document":{"type":"object","nullable":true,"additionalProperties":true}},"required":["document"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/assessment/{assessmentId}":{"get":{"description":"Retrieves statistic assessment for the specified ID.","operationId":"PolicyStatisticsApi_getStatisticAssessment","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}},{"name":"assessmentId","required":true,"in":"path","description":"Statistic Assessment Identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticAssessmentDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Retrieves statistic assessment.","tags":["policy-statistics"]}}}}
```

## Retrieves assessment relationships.

> Retrieves assessment relationships for the specified ID.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticAssessmentRelationshipsDTO":{"type":"object","properties":{"target":{"$ref":"#/components/schemas/VcDocumentDTO"},"relationships":{"type":"array","items":{"$ref":"#/components/schemas/VcDocumentDTO"}}}},"VcDocumentDTO":{"type":"object","properties":{"id":{"type":"string"},"policyId":{"type":"string"},"hash":{"type":"string"},"signature":{"type":"number"},"status":{"type":"string","enum":["NEW","ISSUE","REVOKE","SUSPEND","RESUME","FAILED"]},"tag":{"type":"string"},"type":{"type":"string"},"createDate":{"type":"string"},"updateDate":{"type":"string"},"owner":{"type":"string"},"hederaStatus":{"type":"string"},"option":{"type":"object","additionalProperties":true},"topicId":{"type":"string"},"messageId":{"type":"string"},"document":{"$ref":"#/components/schemas/VcDTO"}}},"VcDTO":{"type":"object","properties":{"id":{"type":"string","nullable":true},"@context":{"type":"array","items":{"type":"string"}},"type":{"type":"array","items":{"type":"string"}},"credentialSubject":{"additionalProperties":true,"type":"array","items":{"type":"object"}},"issuer":{"oneOf":[{"type":"string"},{"type":"object","additionalProperties":true}]},"issuanceDate":{"type":"string"},"proof":{"nullable":true,"type":"object","allOf":[{"$ref":"#/components/schemas/ProofDTO"}]}},"required":["id","@context","type","credentialSubject","issuer","issuanceDate","proof"]},"ProofDTO":{"type":"object","properties":{"type":{"type":"string"},"created":{"type":"string"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string"},"jws":{"type":"string"}},"required":["type","created","verificationMethod","proofPurpose","jws"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"UnprocessableEntityErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/assessment/{assessmentId}/relationships":{"get":{"description":"Retrieves assessment relationships for the specified ID.","operationId":"PolicyStatisticsApi_getStatisticAssessmentRelationships","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}},{"name":"assessmentId","required":true,"in":"path","description":"Statistic Assessment Identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticAssessmentRelationshipsDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"422":{"description":"Unprocessable entity.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnprocessableEntityErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Retrieves assessment relationships.","tags":["policy-statistics"]}}}}
```

## Imports new statistic definition from a zip file.

> Imports new statistic definition from the provided zip file into the local DB.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"messageId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"status":{"type":"string","enum":["DRAFT","DRY_RUN","PUBLISHED","ERROR","ACTIVE"]},"config":{"type":"object","nullable":true,"additionalProperties":true}},"required":["name","config"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{policyId}/import/file":{"post":{"description":"Imports new statistic definition from the provided zip file into the local DB.","operationId":"PolicyStatisticsApi_importStatisticDefinition","parameters":[{"name":"policyId","required":true,"in":"path","description":"Policy Id","schema":{"type":"string"}}],"requestBody":{"required":true,"description":"A binary/zip file containing statistic definition to be imported.","content":{"application/json":{"schema":{"type":"string"}}}},"responses":{"201":{"description":"Successful operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Imports new statistic definition from a zip file.","tags":["policy-statistics"]}}}}
```

## Returns a zip file containing statistic definition.

> Returns a zip file containing statistic definition.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/{definitionId}/export/file":{"get":{"description":"Returns a zip file containing statistic definition.","operationId":"PolicyStatisticsApi_exportStatisticDefinition","parameters":[{"name":"definitionId","required":true,"in":"path","description":"Statistic Definition Identifier","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation. Response zip file.","content":{"application/zip":{"schema":{"type":"string","format":"binary"}}}},"401":{"description":"Unauthorized request.","content":{"application/zip":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/zip":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/zip":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Returns a zip file containing statistic definition.","tags":["policy-statistics"]}}}}
```

## Imports a zip file containing statistic definition.

> Imports a zip file containing statistic definition.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"3.6.0-rc"},"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"StatisticDefinitionDTO":{"type":"object","properties":{"id":{"type":"string"},"uuid":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"creator":{"type":"string"},"owner":{"type":"string"},"topicId":{"type":"string"},"messageId":{"type":"string"},"policyId":{"type":"string"},"policyTopicId":{"type":"string"},"policyInstanceTopicId":{"type":"string"},"status":{"type":"string","enum":["DRAFT","DRY_RUN","PUBLISHED","ERROR","ACTIVE"]},"config":{"type":"object","nullable":true,"additionalProperties":true}},"required":["name","config"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/policy-statistics/import/file/preview":{"post":{"description":"Imports a zip file containing statistic definition.","operationId":"PolicyStatisticsApi_previewStatisticDefinition","parameters":[],"requestBody":{"required":true,"description":"A binary/zip file containing statistic definition to preview.","content":{"application/json":{"schema":{"type":"string"}}}},"responses":{"200":{"description":"Statistic definition preview.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatisticDefinitionDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Imports a zip file containing statistic definition.","tags":["policy-statistics"]}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://dev.guardian.hedera.com/api-reference/policy-statistics.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
