---
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: eJzdWetu2zgWfhVCfyYZ2I7t3DrBYLBp0os7RRvEyQ6wTYDSEm1zIosakrLrCfxvn2QfbZ9kv0PqZsvJOOgCC+yfVpHIcz/fufgxiIQJtUytVElwFtxMpWEiiVIlE8vwnBkRMauYFjxiMbfCWDYX2uA4U2MWcctZqmIZLlkkxjLBaZkwOxVM6QlPpOFEuXgXqsQIEB5lMo5kMmGjWIUPnaAVqFRod3QQQQwj9FyG4soRvgZrnEi55jNhwTs4+/K4IfdtIv/IBBtcklAcoo1+F6HFLUlfU26neE5wn/5yVAdEU4s/MqkFWFqdiVZgwqmY8eDsMbDLlM4aqyFmsFq1NjmeF0zYQtopcdZiLo3XIOcLkfSyYrx2oGI95rF5lvc9nTYp2c7Q9363S//BmBbGpEeeptDJ2e/gd0PyPdbopZqsa6W/7dWv8SltZaWN6YU3O15saFw4eqIQAYnxzudJxC7xcD7RQszIubmvETHxrHBHPRbslLvQ0mIstI8ubthd4MiRUlrFsdB3Adt7d3l1ve9YqEUiNFHzt5KQoqfkaSiEvrUTZdsyaROhETeiNG1l6y/eF60g03EAu66bRkZN87eCsdIzDjMHeBbf+Cx1Rjo5Pjrt9ft98So8DQ9Ho8OwH56ednsNswWrIgB2JX0pxjyLbT25GlQ/gSKZgyydHwGfPDN3Z9XrdDvdBvG/Vwle0Wd70rIQzhzDPWrhvhgxA0vmae+TBGTXnblPrU3N2cFB/qYTqtlBquWch8v2E3pfCRBKKMxurz8yBNJiKsMphEFAQZRlHZxIQh/LTu6Ri8moxcxUZXHEEC30jpM2PgzDKU8mMCvpZCVcBoV+z7Q0kQzti+z65rYh+Yc6oRUhRJSBynKI5FN6d9LvkVd2GnItGiwGOUn4xdEEF4qha0E4gSMwnlTRJV+aGjsAvZgI/RS/w5PjTTaU7jBlTpSljiqlfUSUwXQi1ETzFJ65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Hu88dpScH+V1z8HFw8ebT8E2b7qyqJVjlB8qdSIUZ7RKK7CpX4W446Rx2eq7pU8ZCupo89OvSc5v2WrX+3/06lke7Re04SGOMpbVVu4fVL8VvZvUly1n5UxcAbArV6dzjI23KbnW8WtFr/xuVw1uIA+9F23cKdTv8xW9fW6X1dWTtXFVn7ukP7YL8haLsXect0j578jfArfIUkJ0s65IUcpaGW9FSKsehqlwToKW2drHRxq3Vv3dvCBN5DphVsXhwxSJ/IOpbhdqsG14E+pcq3NYrP1NGAL5/KY/7L09eKJHWnyYT3aMZ+w9X/mGD
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>
      