Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moving source to components #625

Merged
merged 13 commits into from
Apr 10, 2024
69 changes: 69 additions & 0 deletions schema/components.json
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,75 @@
"required": [
"reason"
]
},
"Source": {
"title": "Source",
"description": "The source object is used to explain where information in a statement originated from, and to link to supporting information.",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"type": "object",
"properties": {
"type": {
"title": "Source type",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"description": "What type of source is this? Multiple tags can be combined. Values should come from the source type codelist.",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"type": "array",
"items": {
"type": "string",
"enum": [
"selfDeclaration",
"officialRegister",
"thirdParty",
"primaryResearch",
"verified"
],
"codelist": "sourceType.csv",
"openCodelist": false
}
},
"description": {
"title": "Description",
"description": "Where required, additional free-text information about the source of this statement can be provided here.",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"type": "string"
},
"url": {
"title": "Source URL",
"description": "If this information was fetched from an external URL, or a machine or human readable web page is available that provides additional information on how this statement was sourced, provide the URL.",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"type": "string",
"format": "uri"
},
"retrievedAt": {
"title": "Retrieved at",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"description": "A timestamp indicating when this statement was imported from an external system, in YYYY-MM-DDTHH:MM:SS or YYYY-MM-DD format. (The statementDate should be set based on the source information.)",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"type": "string",
"anyOf": [
{
"format": "date"
},
{
"format": "date-time"
}
]
},
"assertedBy": {
"title": "Asserted by",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"description": "An array of objects representing who is making this statement. This may be the name of the person or organisation making a self-declaration or the name of some other party making a declaration on their behalf. If this statement has been verified, the array may also include the name of the organisation providing verification.",
odscrachel marked this conversation as resolved.
Show resolved Hide resolved
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"title": "Name",
"description": "The name of the agent making the assertion",
"type": "string"
},
"uri": {
"title": "URI",
"description": "An optional URI to identify the agent making the assertion",
"type": "string",
"format": "uri"
}
}
}
}
}
}
}
}
4 changes: 2 additions & 2 deletions schema/person-record.json
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,8 @@
},
"source": {
"title": "Source",
"description": "The source of this PEP information.",
"$ref": "urn:statement#/$defs/Source"
"description": "The source of this PEP information",
"$ref": "urn:components#/$defs/Source"
}
}
}
Expand Down
73 changes: 2 additions & 71 deletions schema/statement.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@
},
"source": {
"title": "Source",
"description": "The source of information in this Statement.",
"$ref": "#/$defs/Source"
"description": "The source of information in this statement.",
"$ref": "urn:components#/$defs/Source"
},
"declaration": {
"title": "Declaration Reference",
Expand Down Expand Up @@ -310,75 +310,6 @@
"motivation"
]
}
},
"Source": {
"title": "Source",
"description": "Details describing an information source.",
"type": "object",
"properties": {
"type": {
"title": "Source Type",
"description": "The types of the source, using the sourceType codelist.",
"type": "array",
"items": {
"type": "string",
"enum": [
"selfDeclaration",
"officialRegister",
"thirdParty",
"primaryResearch",
"verified"
],
"codelist": "sourceType.csv",
"openCodelist": false
}
},
"description": {
"title": "Description",
"description": "Additional, free-text information about the source of information.",
"type": "string"
},
"url": {
"title": "Source URL",
"description": "The external URL from which this information was fetched, if relevant. Or, if relevant, a URL providing additional detail on how this information was sourced.",
"type": "string",
"format": "uri"
},
"retrievedAt": {
"title": "Retrieved At",
"description": "A timestamp indicating when this information was imported from an external system, in full-date (YYYY-MM-DD) or date-time (e.g. YYYY-MM-DDTHH:MM:SSZ) format. See the IETF RFC3339 standard, section 5.6.",
"type": "string",
"anyOf": [
{
"format": "date"
},
{
"format": "date-time"
}
]
},
"assertedBy": {
"title": "Asserted By",
"description": "The people or organisations providing the information asserted in this Statement. This may include the declaring subject of a self-declaration, or the name of an agent making a declaration on their behalf. If this Statement has been verified, the array may include the name of the organisation providing verification.",
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"title": "Name",
"description": "The name of the agent making the assertion.",
"type": "string"
},
"uri": {
"title": "URI",
"description": "An optional URI to identify the agent making the assertion.",
"type": "string",
"format": "uri"
}
}
}
}
}
}
}
}
Loading