consent_artifacts
Creates, updates, deletes, gets or lists a consent_artifacts
resource.
Overview
Name | consent_artifacts |
Type | Resource |
Id | google.healthcare.consent_artifacts |
Fields
Name | Datatype | Description |
---|---|---|
name | string | Identifier. Resource name of the Consent artifact, of the form projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/consentStores/{consent_store_id}/consentArtifacts/{consent_artifact_id} . Cannot be changed after creation. |
consentContentScreenshots | array | Optional. Screenshots, PDFs, or other binary information documenting the user's consent. |
consentContentVersion | string | Optional. An string indicating the version of the consent information shown to the user. |
guardianSignature | object | User signature. |
metadata | object | Optional. Metadata associated with the Consent artifact. For example, the consent locale or user agent version. |
userId | string | Required. User's UUID provided by the client. |
userSignature | object | User signature. |
witnessSignature | object | User signature. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | consentArtifactsId, consentStoresId, datasetsId, locationsId, projectsId | Gets the specified Consent artifact. |
list | SELECT | consentStoresId, datasetsId, locationsId, projectsId | Lists the Consent artifacts in the specified consent store. |
create | INSERT | consentStoresId, datasetsId, locationsId, projectsId | Creates a new Consent artifact in the parent consent store. |
delete | DELETE | consentArtifactsId, consentStoresId, datasetsId, locationsId, projectsId | Deletes the specified Consent artifact. Fails if the artifact is referenced by the latest revision of any Consent. |
SELECT
examples
Lists the Consent artifacts in the specified consent store.
SELECT
name,
consentContentScreenshots,
consentContentVersion,
guardianSignature,
metadata,
userId,
userSignature,
witnessSignature
FROM google.healthcare.consent_artifacts
WHERE consentStoresId = '{{ consentStoresId }}'
AND datasetsId = '{{ datasetsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new consent_artifacts
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO google.healthcare.consent_artifacts (
consentStoresId,
datasetsId,
locationsId,
projectsId,
name,
userId,
userSignature,
guardianSignature,
witnessSignature,
consentContentScreenshots,
consentContentVersion,
metadata
)
SELECT
'{{ consentStoresId }}',
'{{ datasetsId }}',
'{{ locationsId }}',
'{{ projectsId }}',
'{{ name }}',
'{{ userId }}',
'{{ userSignature }}',
'{{ guardianSignature }}',
'{{ witnessSignature }}',
'{{ consentContentScreenshots }}',
'{{ consentContentVersion }}',
'{{ metadata }}'
;
- name: your_resource_model_name
props:
- name: name
value: string
- name: userId
value: string
- name: userSignature
value:
- name: userId
value: string
- name: image
value:
- name: rawBytes
value: string
- name: gcsUri
value: string
- name: metadata
value: object
- name: signatureTime
value: string
- name: consentContentScreenshots
value:
- - name: rawBytes
value: string
- name: gcsUri
value: string
- name: consentContentVersion
value: string
- name: metadata
value: object
DELETE
example
Deletes the specified consent_artifacts
resource.
/*+ delete */
DELETE FROM google.healthcare.consent_artifacts
WHERE consentArtifactsId = '{{ consentArtifactsId }}'
AND consentStoresId = '{{ consentStoresId }}'
AND datasetsId = '{{ datasetsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';