{
"description": "Anexo (conteúdo) que fará parte de assinatura digital. A assinatura será baseada no valor de hash (SHA-256) do conteúdo. O conteúdo pode ser fornecido (Attachment.data) ou apenas referenciado (Attachement.url).",
"_filename": "StructureDefinition-anexo-assinado.json",
"package_name": "br.go.ses.seguranca",
"date": "2025-08-20T14:23:52+00:00",
"derivation": "constraint",
"publisher": "SES-GO",
"fhirVersion": "4.0.1",
"jurisdiction": [ {
"coding": [ {
"code": "BR",
"system": "urn:iso:std:iso:3166"
} ]
} ],
"name": "AnexoParaAssinar",
"mapping": [ {
"uri": "http://hl7.org/v2",
"name": "HL7 v2 Mapping",
"identity": "v2"
}, {
"uri": "http://hl7.org/v3",
"name": "RIM Mapping",
"identity": "rim"
} ],
"abstract": false,
"type": "Attachment",
"experimental": null,
"resourceType": "StructureDefinition",
"title": "Anexo para assinar",
"package_version": "0.0.2",
"snapshot": {
"element": [ {
"constraint": [ {
"key": "att-1",
"human": "If the Attachment has data, it SHALL have a contentType",
"xpath": "not(exists(f:data)) or exists(f:contentType)",
"source": "http://hl7.org/fhir/StructureDefinition/Attachment",
"severity": "error",
"expression": "data.empty() or contentType.exists()"
}, {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment",
"min": 0,
"definition": "For referring to data content defined in other formats.",
"isModifier": false,
"short": "Content in a format defined elsewhere",
"mapping": [ {
"map": "n/a",
"identity": "rim"
}, {
"map": "ED/RP",
"identity": "v2"
}, {
"map": "ED",
"identity": "rim"
} ],
"max": "*",
"id": "Attachment",
"condition": [ "ele-1" ],
"comment": "When providing a summary view (for example with Observation.value[x]) Attachment should be represented with a brief display text such as \"Signed Procedure Consent\".",
"base": {
"max": "*",
"min": 0,
"path": "Attachment"
}
}, {
"path": "Attachment.id",
"min": 0,
"definition": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
"isModifier": false,
"short": "Unique id for inter-element referencing",
"mapping": [ {
"map": "n/a",
"identity": "rim"
} ],
"type": [ {
"code": "http://hl7.org/fhirpath/System.String",
"extension": [ {
"url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type",
"valueUrl": "string"
} ]
} ],
"representation": [ "xmlAttr" ],
"max": "1",
"id": "Attachment.id",
"base": {
"max": "1",
"min": 0,
"path": "Element.id"
},
"isSummary": false
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
}, {
"key": "ext-1",
"human": "Must have either extensions or value[x], not both",
"xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), \"value\")])",
"source": "http://hl7.org/fhir/StructureDefinition/Extension",
"severity": "error",
"expression": "extension.exists() != value.exists()"
} ],
"path": "Attachment.extension",
"min": 1,
"definition": "An Extension",
"isModifier": false,
"short": "Deve incluir o valor de hash (SHA-256 na base64).",
"slicing": {
"rules": "open",
"description": "Extensions are always sliced by (at least) url",
"discriminator": [ {
"path": "url",
"type": "value"
} ]
},
"type": [ {
"code": "Extension"
} ],
"max": "*",
"id": "Attachment.extension",
"base": {
"max": "*",
"min": 0,
"path": "Element.extension"
},
"isSummary": false
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
}, {
"key": "ext-1",
"human": "Must have either extensions or value[x], not both",
"xpath": "exists(f:extension)!=exists(f:*[starts-with(local-name(.), \"value\")])",
"source": "http://hl7.org/fhir/StructureDefinition/Extension",
"severity": "error",
"expression": "extension.exists() != value.exists()"
} ],
"path": "Attachment.extension",
"min": 1,
"definition": "Valo de hash usando o algoritmo SHA-256",
"isModifier": false,
"short": "Hash Sha256",
"type": [ {
"code": "Extension",
"profile": [ "https://fhir.saude.go.gov.br/r4/seguranca/StructureDefinition/hash-sha256" ]
} ],
"sliceName": "hash256",
"max": "1",
"id": "Attachment.extension:hash256",
"base": {
"max": "*",
"min": 0,
"path": "Element.extension"
},
"isSummary": false
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.contentType",
"requirements": "Processors of the data need to be able to know how to interpret the data.",
"min": 1,
"definition": "Identifies the type of the data in the attachment and allows a method to be chosen to interpret or render the data. Includes mime type parameters such as charset where appropriate.",
"isModifier": false,
"short": "Mime type of the content, with charset etc.",
"mapping": [ {
"map": "ED.2+ED.3/RP.2+RP.3. Note conversion may be needed if old style values are being used",
"identity": "v2"
}, {
"map": "./mediaType, ./charset",
"identity": "rim"
} ],
"type": [ {
"code": "code"
} ],
"binding": {
"strength": "required",
"valueSet": "http://hl7.org/fhir/ValueSet/mimetypes|4.0.1",
"extension": [ {
"url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
"valueString": "MimeType"
} ],
"description": "The mime type of an attachment. Any valid mime type is allowed."
},
"max": "1",
"id": "Attachment.contentType",
"example": [ {
"label": "General",
"valueCode": "text/plain; charset=UTF-8, image/png"
} ],
"base": {
"max": "1",
"min": 0,
"path": "Attachment.contentType"
},
"isSummary": true
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.language",
"requirements": "Users need to be able to choose between the languages in a set of attachments.",
"min": 0,
"definition": "The human language of the content. The value can be any valid value according to BCP 47.",
"isModifier": false,
"short": "Human language of the content (BCP-47)",
"mapping": [ {
"map": "./language",
"identity": "rim"
} ],
"type": [ {
"code": "code"
} ],
"binding": {
"strength": "preferred",
"valueSet": "http://hl7.org/fhir/ValueSet/languages",
"extension": [ {
"url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-maxValueSet",
"valueCanonical": "http://hl7.org/fhir/ValueSet/all-languages"
}, {
"url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName",
"valueString": "Language"
} ],
"description": "A human language."
},
"max": "1",
"id": "Attachment.language",
"example": [ {
"label": "General",
"valueCode": "en-AU"
} ],
"base": {
"max": "1",
"min": 0,
"path": "Attachment.language"
},
"isSummary": true
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.data",
"requirements": "The data needs to able to be transmitted inline.",
"min": 0,
"definition": "The actual data of the attachment - a sequence of bytes, base64 encoded.",
"isModifier": false,
"short": "Data inline, base64ed",
"mapping": [ {
"map": "ED.5",
"identity": "v2"
}, {
"map": "./data",
"identity": "rim"
} ],
"type": [ {
"code": "base64Binary"
} ],
"max": "1",
"id": "Attachment.data",
"comment": "The base64-encoded data SHALL be expressed in the same character set as the base resource XML or JSON.",
"base": {
"max": "1",
"min": 0,
"path": "Attachment.data"
},
"isSummary": false
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.url",
"requirements": "The data needs to be transmitted by reference.",
"min": 0,
"definition": "A location where the data can be accessed.",
"isModifier": false,
"short": "Uri where the data can be found",
"mapping": [ {
"map": "RP.1+RP.2 - if they refer to a URL (see v2.6)",
"identity": "v2"
}, {
"map": "./reference/literal",
"identity": "rim"
} ],
"type": [ {
"code": "url"
} ],
"max": "1",
"id": "Attachment.url",
"comment": "If both data and url are provided, the url SHALL point to the same content as the data contains. Urls may be relative references or may reference transient locations such as a wrapping envelope using cid: though this has ramifications for using signatures. Relative URLs are interpreted relative to the service url, like a resource reference, rather than relative to the resource itself. If a URL is provided, it SHALL resolve to actual data.",
"example": [ {
"label": "General",
"valueUrl": "http://www.acme.com/logo-small.png"
} ],
"base": {
"max": "1",
"min": 0,
"path": "Attachment.url"
},
"isSummary": true
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.size",
"requirements": "Representing the size allows applications to determine whether they should fetch the content automatically in advance, or refuse to fetch it at all.",
"min": 1,
"definition": "The number of bytes of data that make up this attachment (before base64 encoding, if that is done).",
"isModifier": false,
"short": "O tamanho em bytes do conteúdo deve ser necessariamente fornecido.",
"mapping": [ {
"map": "N/A (needs data type R3 proposal)",
"identity": "rim"
} ],
"type": [ {
"code": "unsignedInt"
} ],
"max": "1",
"id": "Attachment.size",
"comment": "The number of bytes is redundant if the data is provided as a base64binary, but is useful if the data is provided as a url reference.",
"base": {
"max": "1",
"min": 0,
"path": "Attachment.size"
},
"isSummary": true
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.hash",
"requirements": "Included so that applications can verify that the contents of a location have not changed due to technical failures (e.g., storage rot, transport glitch, incorrect version).",
"min": 1,
"definition": "The calculated hash of the data using SHA-1. Represented using base64.",
"isModifier": false,
"short": "O valor de hash (SHA-1 na base64) do conteúdo deve necessariamente ser fornecido.",
"mapping": [ {
"map": ".integrityCheck[parent::ED/integrityCheckAlgorithm=\"SHA-1\"]",
"identity": "rim"
} ],
"type": [ {
"code": "base64Binary"
} ],
"max": "1",
"id": "Attachment.hash",
"comment": "The hash is calculated on the data prior to base64 encoding, if the data is based64 encoded. The hash is not intended to support digital signatures. Where protection against malicious threats a digital signature should be considered, see [Provenance.signature](http://hl7.org/fhir/R4/provenance-definitions.html#Provenance.signature) for mechanism to protect a resource with a digital signature.",
"base": {
"max": "1",
"min": 0,
"path": "Attachment.hash"
},
"isSummary": true
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.title",
"requirements": "Applications need a label to display to a human user in place of the actual data if the data cannot be rendered or perceived by the viewer.",
"min": 0,
"definition": "A label or set of text to display in place of the data.",
"isModifier": false,
"short": "Label to display in place of the data",
"mapping": [ {
"map": "./title/data",
"identity": "rim"
} ],
"type": [ {
"code": "string"
} ],
"extension": [ {
"url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
"valueBoolean": true
} ],
"max": "1",
"id": "Attachment.title",
"example": [ {
"label": "General",
"valueString": "Official Corporate Logo"
} ],
"base": {
"max": "1",
"min": 0,
"path": "Attachment.title"
},
"isSummary": true
}, {
"constraint": [ {
"key": "ele-1",
"human": "All FHIR elements must have a @value or children",
"xpath": "@value|f:*|h:div",
"source": "http://hl7.org/fhir/StructureDefinition/Element",
"severity": "error",
"expression": "hasValue() or (children().count() > id.count())"
} ],
"path": "Attachment.creation",
"requirements": "This is often tracked as an integrity issue for use of the attachment.",
"min": 0,
"definition": "The date that the attachment was first created.",
"isModifier": false,
"short": "Date attachment was first created",
"mapping": [ {
"map": "N/A (needs data type R3 proposal)",
"identity": "rim"
} ],
"type": [ {
"code": "dateTime"
} ],
"max": "1",
"id": "Attachment.creation",
"base": {
"max": "1",
"min": 0,
"path": "Attachment.creation"
},
"isSummary": true
} ],
"extension": [ {
"url": "http://hl7.org/fhir/tools/StructureDefinition/snapshot-base-version",
"valueString": "4.0.1"
} ]
},
"status": "draft",
"id": "f3119759-69c3-466f-ae69-58503f982200",
"kind": "complex-type",
"url": "https://fhir.saude.go.gov.br/r4/seguranca/StructureDefinition/anexo-assinado",
"version": "0.0.2",
"differential": {
"element": [ {
"id": "Attachment",
"path": "Attachment"
}, {
"id": "Attachment.extension",
"min": 1,
"path": "Attachment.extension",
"short": "Deve incluir o valor de hash (SHA-256 na base64)."
}, {
"id": "Attachment.extension:hash256",
"max": "1",
"min": 1,
"path": "Attachment.extension",
"type": [ {
"code": "Extension",
"profile": [ "https://fhir.saude.go.gov.br/r4/seguranca/StructureDefinition/hash-sha256" ]
} ],
"sliceName": "hash256"
}, {
"id": "Attachment.contentType",
"min": 1,
"path": "Attachment.contentType"
}, {
"id": "Attachment.size",
"min": 1,
"path": "Attachment.size",
"short": "O tamanho em bytes do conteúdo deve ser necessariamente fornecido."
}, {
"id": "Attachment.hash",
"min": 1,
"path": "Attachment.hash",
"short": "O valor de hash (SHA-1 na base64) do conteúdo deve necessariamente ser fornecido."
} ]
},
"contact": [ {
"name": "SES-GO",
"telecom": [ {
"value": "https://fhir.saude.go.gov.br",
"system": "url"
}, {
"value": "ti-ses.saude@goias.gov.br",
"system": "email"
} ]
} ],
"baseDefinition": "http://hl7.org/fhir/StructureDefinition/Attachment"
}