---
id: service-policy-read
title: "Read data policy"
description: "This endpoint is used to read latest version of data policy defined in the organisation in the consent building block."
sidebar_label: "Read data policy"
hide_title: true
hide_table_of_contents: true
api: eJzdWW1v3DYS/isDfaldaOVdvyU1iuJcO0m3LRLDjq/A1QYyK82uWFOkQlK73hr6dr/kftr9ksOQ0kr7ktRBDjjgvthaipz3eWY4eooysqkRpRNaRWfR+1xYIJWVWigHwkJlKQOnwRBmINGRdTAnY4VWoKeQoUMotRTpEjKaCkUZCAUuJ9BmhkpYZMrtWqqVJeVgUgmZCTWDidTpQxLFkS7J+K3jLDqLLJm5SOnKE74mzKI4KtFgQY6Mjc5+f9qQ+1aJjxXB+JKFQgV68gelLoojwW9LdHkURwoL4l+e6phpGvpYCUNZdOZMRXFk05wKjM6eIrcsea91RqhZVNfxJsfzlgkshMuZs6G5sEGDhu/HisyyY7y2oWM9RWk/y/ued9uSbWf5/eFwyP9SrRwpx49YllKk3n4Hf1iW76lHrzRsXSfC6aB+j8/KVk44yQvB7FG8qXHr6Jmek1E2OB9VBpfo8HxmiAp2buNrQyiL1h39WHA5+tAyNCUTogst3EWeHCtltJRk7iLYe3N5db3vWeiFIsPUwimVcvSseFoOoceB0m4g1IAJTdDSyrSdrX8PvoijysjoPt4wjci2zR9HU20KdNFZFMURPWJReiOdnhy/GB0eHtLL9EV6NJkcpYfpixfD0ZbZoroNgOeSvqQpVtL1k2uL6lssiM3Blm621HHUZObzWY2SYTLcIv73LsE7+rAnHKSoYKql1Av/xlIxJwOB9j5LwHZ9NvfcudKeHRw0K0mqi4PSiDmmy8En9L4iU6DiMLu9/hXQwSIXaQ6OcWtOZtkHJ5YwxLKXe+JjMovB5rqSGSjteA1ZmxCGaY5qRsDhDU4UxAr9URlhM5G6L7Lrq9styX/uE6oZIbLKOrO8odRp83zSPxFKl6doaIvFuCEJNtCsY59U18Q4IbS6IiN0dolL22MnlKMZmU/xOzo92WTD6Q6mJQqlp8ppnzHlOo5mpGcGy1yk18TafL3x3qwogumRrOP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WrtzevBnym7oZgnR84dzKdVjxLaLNrNQr3l5PkKBn5pk9bV6DqycNflz43ae9V6//d17Em2h09uoNSolC9UXuA1d/bb2b9IcvZ6lPXfRzl2jre9/TEk7JbI+ual8M3Ko+3wrL3st0zhb4d/uLb105pQx1Z29fVmXv+YXyQf6Eoe9dNi7QPn/wGuFOeFrLVsi9JK+fKcDUPpRoc6so1A1rpege32ri1+vfmFWMiNoDZFYsHXyyaB6a+U6jNuhFE4L9c4XYe+Z4z4hda/rDaHt588sAKacNuNtF9Xdf/AVf+YYM=
sidebar_class_name: "get api-method"
info_path: docs/consent-management-individual-api/igrant-io-api-documentation
custom_edit_url: null
---

> **Build this with an AI coding agent.** Install the iGrant.io Agent Skills, then ask your agent to build the integration:
>
> ```bash
> npx skills add L3-iGrant/skills
> ```


import ApiTabs from "@theme/ApiTabs";
import DiscriminatorTabs from "@theme/DiscriminatorTabs";
import MethodEndpoint from "@theme/ApiExplorer/MethodEndpoint";
import SecuritySchemes from "@theme/ApiExplorer/SecuritySchemes";
import MimeTabs from "@theme/MimeTabs";
import ParamsItem from "@theme/ParamsItem";
import ResponseSamples from "@theme/ResponseSamples";
import SchemaItem from "@theme/SchemaItem";
import SchemaTabs from "@theme/SchemaTabs";
import Markdown from "@theme/Markdown";
import OperationTabs from "@theme/OperationTabs";
import TabItem from "@theme/TabItem";

<h1 className={"openapi__heading"}>Read data policy</h1>

<MethodEndpoint method={"get"} path={"/service/policy/{policyId}"}></MethodEndpoint>



This endpoint is used to read latest version of data policy defined in the organisation in the consent building block.

## Request

<details style={{"marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collapsed={false} open={true}><summary style={{}}><h3 className={"openapi-markdown__details-summary-header-params"}>Path Parameters</h3></summary><div><ul><ParamsItem className={"paramsItem"} param={{"description":"Unique ID of an object","in":"path","name":"policyId","required":true,"schema":{"type":"string"}}}></ParamsItem></ul></div></details><details style={{"marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collapsed={false} open={true}><summary style={{}}><h3 className={"openapi-markdown__details-summary-header-params"}>Query Parameters</h3></summary><div><ul><ParamsItem className={"paramsItem"} param={{"description":"An object with ID revisionId","in":"query","name":"revisionId","required":false,"schema":{"type":"string"}}}></ParamsItem></ul></div></details><div><div><ApiTabs label={undefined} id={undefined}><TabItem label={"200"} value={"200"}><div>

Data policy retrieved successfully

</div><details style={{"textAlign":"left","marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collaposed={true} open={false}><summary style={{}}><strong>Response Headers</strong></summary><ul style={{"marginLeft":"1rem"}}></ul></details><div><MimeTabs className={"openapi-tabs__mime"} schemaType={"response"}><TabItem label={"application/json"} value={"application/json"}><SchemaTabs className={"openapi-tabs__schema"}><TabItem label={"Schema"} value={"Schema"}><details style={{}} className={"openapi-markdown__details response"} data-collapsed={false} open={true}><summary style={{}} className={"openapi-markdown__details-summary-response"}><strong>Schema</strong></summary><div style={{"textAlign":"left","marginLeft":"1rem"}}></div><ul style={{"marginLeft":"1rem"}}><SchemaItem collapsible={true} className={"schemaItem"}><details style={{}} className={"openapi-markdown__details"}><summary style={{}}><span className={"openapi-schema__container"}><strong className={"openapi-schema__property"}>policy</strong><span className={"openapi-schema__name"}> object</span></span></summary><div style={{"marginLeft":"1rem"}}><div style={{"marginTop":".5rem","marginBottom":".5rem"}}>

A policy governs data and DataAgreement in the realm of an organisation that is refered to as "data controller" (GDPR) and owner of referencing Agreements.

</div><SchemaItem collapsible={false} name={"id"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"65471222e8c7c3bb3c2c7701","description":""}}></SchemaItem><SchemaItem collapsible={false} name={"name"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"Default data policy","description":"Name of the policy"}}></SchemaItem><SchemaItem collapsible={false} name={"version"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"1.0.0","description":"Version of the policy (it can follow the semver format)"}}></SchemaItem><SchemaItem collapsible={false} name={"url"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"https://example.com/privacy-policy","description":"Permanent URL at which this very version of the Policy can be read, should not be allowed to change over time"}}></SchemaItem><SchemaItem collapsible={false} name={"jurisdiction"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"EU","description":"Jurisdiction"}}></SchemaItem><SchemaItem collapsible={false} name={"industrySector"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"Healthcare","description":"Industry sector"}}></SchemaItem><SchemaItem collapsible={false} name={"dataRetentionPeriodDays"} required={false} schemaName={"integer"} qualifierMessage={undefined} schema={{"type":"integer","format":"","example":365,"description":"Data retention period in days"}}></SchemaItem><SchemaItem collapsible={false} name={"geographicRestriction"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"EU","description":"Geographic restriction"}}></SchemaItem><SchemaItem collapsible={false} name={"storageLocation"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"EU","description":"Storage location"}}></SchemaItem><SchemaItem collapsible={false} name={"thirdPartyDataSharing"} required={false} schemaName={"boolean"} qualifierMessage={undefined} schema={{"type":"boolean","format":"","example":true,"description":"Third party data sharing"}}></SchemaItem></div></details></SchemaItem><SchemaItem collapsible={true} className={"schemaItem"}><details style={{}} className={"openapi-markdown__details"}><summary style={{}}><span className={"openapi-schema__container"}><strong className={"openapi-schema__property"}>revision</strong><span className={"openapi-schema__name"}> object</span></span></summary><div style={{"marginLeft":"1rem"}}><div style={{"marginTop":".5rem","marginBottom":".5rem"}}>

A *generic* revision model captures the serialised contents of any schema's single row. This is then subject to 1) cryptographic signature and 2) auditing.

Aside from the "successor" column, a revision should be considered locked.

</div><SchemaItem collapsible={false} name={"id"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"65471222e8c7c3bb3c2c6601","description":"Revision ID"}}></SchemaItem><SchemaItem collapsible={false} name={"schemaName"} required={true} schemaName={"string"} qualifierMessage={"**Possible values:** [`dataAgreement`, `policy`, `dataAgreementRecord`]"} schema={{"type":"string","format":"","example":"dataAgreement","description":"Previously \"schema\" but for technical reasons should be called \"schemaName\"","enum":["dataAgreement","policy","dataAgreementRecord"]}}></SchemaItem><SchemaItem collapsible={false} name={"objectId"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"65471222e8c7c3bb3c2c8492","description":"The PK of the object that was serialised"}}></SchemaItem><SchemaItem collapsible={false} name={"objectData"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"{...}","description":"The object that is serialised"}}></SchemaItem><SchemaItem collapsible={false} name={"signedWithoutObjectId"} required={false} schemaName={"boolean"} qualifierMessage={undefined} schema={{"type":"boolean","format":"","example":false,"description":"Indicates that objectId was left blank in serizalizedSnapshot when calculating serializedHash. objectId may subsequently be filled in."}}></SchemaItem><SchemaItem collapsible={false} name={"serizalizedSnapshot"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"{...}","description":"Revisioned data (sed as JSON) as a dict. Apply JSON Canonicalization Scheme as per IETF RFC 8785.  It contains all the fields of the schema except sucessorId, serializedHash, serializedSnapshot.\n"}}></SchemaItem><SchemaItem collapsible={false} name={"serializedHash"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2","description":"Hash of serizalizedSnapshot (SHA-1)"}}></SchemaItem><SchemaItem collapsible={false} name={"timestamp"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"2024-01-15T10:30:00Z","description":"Timestamp of when revisioning happened. It should be ISO 8601 UTC date time"}}></SchemaItem><SchemaItem collapsible={false} name={"authorizedByIndividualId"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"description":"Individual ID","type":"string"}}></SchemaItem><SchemaItem collapsible={false} name={"authorizedByOtherId"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"64541a2e6e7569000145ab00","description":"Reference to an admin user that has created this revision"}}></SchemaItem><SchemaItem collapsible={false} name={"successorId"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"x-fk-model":"Revision","type":"string","description":"If this revision is no longer the latest revision, refer to its successor"}}></SchemaItem><SchemaItem collapsible={false} name={"predecessorHash"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3","description":"Tamper-resistent artifact from previous record, copied from serializedHash"}}></SchemaItem><SchemaItem collapsible={false} name={"predecessorSignature"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","format":"","example":"c3d4e5f6a1b2...","description":"Tamper-resistent artifact from previous record (we don't know if the previous record was signed or not)"}}></SchemaItem></div></details></SchemaItem></ul></details></TabItem><TabItem label={"Example (from schema)"} value={"Example (from schema)"}><ResponseSamples responseExample={"{\n  \"policy\": {\n    \"id\": \"65471222e8c7c3bb3c2c7701\",\n    \"name\": \"Default data policy\",\n    \"version\": \"1.0.0\",\n    \"url\": \"https://example.com/privacy-policy\",\n    \"jurisdiction\": \"EU\",\n    \"industrySector\": \"Healthcare\",\n    \"dataRetentionPeriodDays\": 365,\n    \"geographicRestriction\": \"EU\",\n    \"storageLocation\": \"EU\",\n    \"thirdPartyDataSharing\": true\n  },\n  \"revision\": {\n    \"id\": \"65471222e8c7c3bb3c2c6601\",\n    \"schemaName\": \"dataAgreement\",\n    \"objectId\": \"65471222e8c7c3bb3c2c8492\",\n    \"objectData\": \"{...}\",\n    \"signedWithoutObjectId\": false,\n    \"serizalizedSnapshot\": \"{...}\",\n    \"serializedHash\": \"a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2\",\n    \"timestamp\": \"2024-01-15T10:30:00Z\",\n    \"authorizedByIndividualId\": \"string\",\n    \"authorizedByOtherId\": \"64541a2e6e7569000145ab00\",\n    \"successorId\": \"string\",\n    \"predecessorHash\": \"b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3\",\n    \"predecessorSignature\": \"c3d4e5f6a1b2...\"\n  }\n}"} language={"json"}></ResponseSamples></TabItem></SchemaTabs></TabItem></MimeTabs></div></TabItem><TabItem label={"400"} value={"400"}><div>

bad input parameter

</div><details style={{"textAlign":"left","marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collaposed={true} open={false}><summary style={{}}><strong>Response Headers</strong></summary><ul style={{"marginLeft":"1rem"}}></ul></details><div></div></TabItem><TabItem label={"401"} value={"401"}><div>

Unauthorized

</div><details style={{"textAlign":"left","marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collaposed={true} open={false}><summary style={{}}><strong>Response Headers</strong></summary><ul style={{"marginLeft":"1rem"}}></ul></details><div><MimeTabs className={"openapi-tabs__mime"} schemaType={"response"}><TabItem label={"application/json"} value={"application/json"}><SchemaTabs className={"openapi-tabs__schema"}><TabItem label={"Schema"} value={"Schema"}><details style={{}} className={"openapi-markdown__details response"} data-collapsed={false} open={true}><summary style={{}} className={"openapi-markdown__details-summary-response"}><strong>Schema</strong></summary><div style={{"textAlign":"left","marginLeft":"1rem"}}></div><ul style={{"marginLeft":"1rem"}}><SchemaItem collapsible={false} name={"errorCode"} required={true} schemaName={"integer"} qualifierMessage={undefined} schema={{"type":"integer","example":400}}></SchemaItem><SchemaItem collapsible={false} name={"errorDescription"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","example":"Bad input parameter"}}></SchemaItem></ul></details></TabItem><TabItem label={"Example (from schema)"} value={"Example (from schema)"}><ResponseSamples responseExample={"{\n  \"errorCode\": 400,\n  \"errorDescription\": \"Bad input parameter\"\n}"} language={"json"}></ResponseSamples></TabItem></SchemaTabs></TabItem></MimeTabs></div></TabItem><TabItem label={"500"} value={"500"}><div>

Internal server error

</div><details style={{"textAlign":"left","marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collaposed={true} open={false}><summary style={{}}><strong>Response Headers</strong></summary><ul style={{"marginLeft":"1rem"}}></ul></details><div><MimeTabs className={"openapi-tabs__mime"} schemaType={"response"}><TabItem label={"application/json"} value={"application/json"}><SchemaTabs className={"openapi-tabs__schema"}><TabItem label={"Schema"} value={"Schema"}><details style={{}} className={"openapi-markdown__details response"} data-collapsed={false} open={true}><summary style={{}} className={"openapi-markdown__details-summary-response"}><strong>Schema</strong></summary><div style={{"textAlign":"left","marginLeft":"1rem"}}></div><ul style={{"marginLeft":"1rem"}}><SchemaItem collapsible={false} name={"errorCode"} required={true} schemaName={"integer"} qualifierMessage={undefined} schema={{"type":"integer","example":400}}></SchemaItem><SchemaItem collapsible={false} name={"errorDescription"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","example":"Bad input parameter"}}></SchemaItem></ul></details></TabItem><TabItem label={"Example (from schema)"} value={"Example (from schema)"}><ResponseSamples responseExample={"{\n  \"errorCode\": 400,\n  \"errorDescription\": \"Bad input parameter\"\n}"} language={"json"}></ResponseSamples></TabItem></SchemaTabs></TabItem></MimeTabs></div></TabItem></ApiTabs></div></div>
      