Data Change Requests

Attachments

23R3

Include attachments on add and change requests to provide supporting information or evidence that Data Stewards can use to quickly validate the requests.

This feature is available in your Network instance by default. Administrators can configure support for attachments for each object in the Workflow Settings.

Supported methods

Attachments can be added when DCRs are submitted from the following:

  • Network UI - Profile page

    Add requests, change requests, and when local Data Stewards route add request to OpenData (Send to OpenData).

  • Network API - Change Request API

    Create Change Request, Retrieve Change Request, and Batch Retrieve Change Request API calls.

Turn on the feature

The feature is available in your Network instance, but attachments are not supported on DCRs for any object by default. Administrators can configure it for each object.

HCPs and HCOs

To allow attachments on DCRs for HCPs and HCOs:

  1. In the Admin console click Settings > Workflow settings.

  2. In the Allow Attachments on Add Request and Change Request Submissions, define the permission on HCP and HCO requests.

    • Do not allow for all HCPs - The option to add attachments will not display on add and change requests. (selected by default).

    • Allow for all HCPs - The option to add attachments will display on all add and change requests.

    • Allow for defined HCP types - The option to add attachments displays only for the defined HCPs.

      Choose the fields and values to filter the attachment option for specific HCPs.

  3. Save your change.

Custom objects

To allow attachments on DCRs for custom objects in your Network instance:

  1. In the Admin console click Settings > Custom Object Workflow Settings.

  2. Select a custom object.

  3. Click Edit.

  4. In the Allow Attachments on Add Request and Change Request Submissions, select the custom object.

  5. Save your change.

Add attachments to DCRs

Adding attachments is optional. This supporting information can help Data Stewards to know where to validate the data.

Attachments can be added when you create an add request or change a record on the profile page.

  1. Click Apply to submit the add request or change request.

    The dialog contains an Attachments section.

  2. Click Browse Files to find images and add them to the request.
  3. Add a description for the attachment (optional).

Supported files

  • File types - All image file types are supported.

    • BMP

    • GIF

    • HEIF (supported on AppleĀ® devices only)

    • JPG/JPEG

    • PNG

    • TIF/TIFF

  • Number of files - A maximum of three attachments can be added to each DCR.

  • File size - 10MB maximum for each file.

View attachments on tasks

Add request and change request tasks now contain an Attachments tab. The tab displays by default if attachments are included in the request.

Details

The following details display for each attachment:

  • thumbnail

  • file name

  • image size

  • date and time that the attachment was added

  • description that the requester added before submitting the DCR

Actions

  • Preview - Click to expand the image on the page. Click the Arrow icon to move to the next attachment.

    You can also download the image in preview mode.

    If the file cannot be previewed, this link does not display.

  • Download - Save the image locally on your computer.

Attachments for OpenData DCRs

By default, this feature is on for all countries in all Veeva OpenData instances. Veeva OpenData can decide to turn off the feature for specific countries.

If OpenData turns off the feature for a country, a banner displays when you apply a DCR for that country. The banner displays the following message: OpenData does not support attachments for this country. Files added will not be sent to OpenData.

Adding attachments is still supported. They will not be included on the DCR for OpenData, but they are available to local Data Stewards for review.

The banner also displays when you view the submitted task (My Requests).

Note: When the feature is not on for a country, OpenData Data Stewards will not see or know if you have added attachments to a DCR for that country.

Reporting

A new column, Has Attachments, is added to the change_request reporting table so you can report on DCRs with attachments. The column value is True/False.

Example

Network API

Attachments are supported in change request API calls. This is supported for Network API v31 and later.

Create Change Request API

Attachments are sent through the API using base64 encoding.

POST data

The following data and details are added to support this feature.

  • attachments

    • file_name - The image name and extension (for example, image1.png).

    • file_caption - A description of the image (optional).

    • file_content_type - The type of file. For example, image/jpeg.

    • format - Defaults to base64 if not specified (optional).

    • file_source_id - An ID for external integration use (optional).

    • file_data - The base64 encoding for the image.

Example request

In this example, two attachments are added.

{
     "metadata": {
         "creator": "admin@verteo.veeva.com",
         "system": "null",
         "note": "test",
         "source": "Veeva CRM"
     },
     "entity_type": "HCP",
     "vid_key": "Network:HCP:214065474881717253",
     "entity": {
         "licenses__v": [{
             "address_vid_key": "Network:Address:210909264435217422",
             "attribute 1": "Value 1",
             "attribute 2": "Value 2",
             " ... ": " ... "
         }]
     },
     "attachments": [{
         "file_name": "196.heif.png",
         "file_caption": "HCP1",   
         "file_content_type": "image/heif",
         "format": "base64",
         "file_source_id": "1688665744000",  
         "file_data":"LDJ9NC1DNFkpN20y4tLmM0JVBERi0xLjQNCjUgMCBvYmoNCjw8DQovVHlwZSAvWE9iamVjdA0KL1N1YnSAwIFIvSW5mbyAxMjYgMCB"
     }, {
         "file_name": "243.heif",
         "file_caption": "HCP2"
         "file_content_type": "image/heif",
         "format": "base64",
         "file_source_id": "1688665758000",  
         "file_data": "bm5gLDJ9NC1DNFkpN20y4tLmM0JVBERi0xLjQNCjUgMCBvYmoNCjw8DQovVHlwZSAvWE9iamVjdA0KL1N1YnR5cGUgMSA"
      }]
 }

Example response

{
  "responseStatus": "SUCCESS",
  "change_request_id": 542116772438868992
}

Example response - image error

{
  "responseStatus": "PARTIAL SUCCESS",
  "change_request_id": 542116772438868992,
  "errors": [
    {
      "type": "Attachment Failure",
      "message": "Unsupported file type."
    }, 
    {
      "type": "Attachment Failure",
      "message": "Exceeded the maximum number of attachments for this DCR."
    }
 }

Retrieve / Batch Retrieve Change Request

New parameter

  • "includeAttachment Info":"true"

Example

https://<DNS>/api/v31.0/change_requests/943700690834537631?includeAttachmentInfo=true

Example response

Response

The following details are returned in the response:

  • file_name - The image name and extension (for example, image1.png)

  • file_caption - A description of the image (optional)

  • file_content_type - The type of file. For example, image/jpeg.

  • file_source_id - An ID for external integration use. (optional)

  • file_status - The status of the image received.

  • name - The Veeva ID of the attachment.

  • file_size - The size of the file.

  • timestamp - The time that the attachment was added.

  • can_send_attachment_to_opendata - Indicates if the OpenData country accepts the attachment (true/false).