api.v2.attachments module

api.v2.attachments.create_folder_in_user_folder(folder_name=None, reference_id=None, reference_type=None, parent_folder_id=None)[source]

Create subfolder in user folder.

Parameters:
  • folder_name (str) – Folder name
  • reference_id (str) – Reference id
  • reference_type (str) – Reference type
  • parent_folder_id (str) – Parent folder id
Returns:

  • success (bool) – True if completely successful, false if not
  • messages (list of str) – List of human-readable error messages
  • data (dict) – A dict containing the following data representation. ::
    {‘folder_id’: folder_id}

api.v2.attachments.delete_photo(file_id=None)[source]
api.v2.attachments.get_attachments_file_list(reference_id=None, reference_type=None, folder_id=None, order_by='date_added', ascending=False, page=1)[source]

Get Folder’s file list.

Parameters:
  • folder_id (str) – Folder id
  • reference_id (str) – Reference id
  • reference_type (str) – Reference type
  • order_by (str) – Column name to sort by
  • ascending (bool) – Asc/Desc
  • page (int) – Page number
Returns:

  • success (bool) – True if completely successful, false if not

  • messages (list of str) – List of human-readable error messages

  • data (dict) – A dict containing the following data representation. :: {

    “folders”: [], “records”: [

    {

    “isdir”: true, “actualPrintDate”: null, “printState”: “Do Not Print”, “folderId”: null, “emailed”: false, “uploadingToS3”: false, “emailOnly”: false, “url”: “/gateway?file=core.uploads&method=getAttachment&id=a5ba0c19-776a-4cab-aaef-6987784b84a4”, “title”: “Continuation of Coverage - NonPay”, “mimeType”: null, “printDateFmt”: null, “folderName”: null, “readOnly”: true, “private”: false, “dateAddedFmt”: “12/06/2017 03:34 PM”, “itemCount”: 1, “id”: “a5ba0c19-776a-4cab-aaef-6987784b84a4”, “size”: “0.0 bytes”

    },...

    ], “activePage”: 1, “maxPages”: 1, “folderName”: null

    }

api.v2.attachments.get_file_metadata(file_id=None)[source]

Gets the reference ID and receivedMetadata fields associated with the given file ID.

Parameters:file_id (str) – The UUID for the file
Returns:
  • success (bool) – True if completely successful, false otherwise
  • messages (list of str) – Human readable error messages, if any
  • data (dict) – The metadata portion of the data is of variable format, depending on the type of file. It is returned as it is stored in the database. Broadly it will either be a dictionary, or a list of dictionaries:
    {
        "reference_id": "alpha_numeric_file_reference_id",
        "metadata": [
            {
                "relatedToBillWhom": bool,
                "contactId": [
                    "alpha_numeric_contact_id",
                    "alpha_numeric_contact_id"
                ],
                "type": "namedInsured,agent,etc...",
                "name": [
                    "Full Name 1",
                    "Full Name 2"
                ],
                "address": "Street Address <br /> with HTML inclusions"
            },
            {
                ...
            }
        ]
    }
    
api.v2.attachments.move_user_file(file_id=None, to_folder_id=None)[source]

Move file

Parameters:
  • file_id (str) – Moved file id
  • to_folder_id (str) – New folder’s id
Returns:

  • success (bool) – True if successful, false if not
  • messages (list of str) – List of human-readable error messages

api.v2.attachments.remove_attachments(attachment_ids=None)[source]

Removes attachments.

Parameters:attachment_ids (list of str) – List of attachment ids to remove
Returns:
  • success (bool) – True if completely successful, false if not
  • messages (list of str) – List of human-readable error messages
  • data (dict) – A dict containing the following data representation. ::
    {‘returnById’: {
    ‘id1’: True, ‘id2’: False .... }

    }

api.v2.attachments.rename_user_file(file_id=None, file_name=None)[source]

Rename file

Parameters:
  • file_id (str) – Renamed file id
  • file_name (str) – New file name
Returns:

  • success (bool) – True if successful, false if not
  • messages (list of str) – List of human-readable error messages

api.v2.attachments.upload_attachment_to_user_folder(file_data_base64=None, file_type=None, file_name=None, reference_id=None, reference_type=None, folder_id=None)[source]

Upload attachment to user folder.

Parameters:
  • file_data_base64 (str) – Base64 encoded data
  • file_type (str) – File MIME type
  • file_name (str) – Filename
  • reference_id (str) – Reference id
  • reference_type (str) – Reference type
  • folder_id (str) – Folder id (oprtional)
Returns:

  • success (bool) – True if completely successful, false if not
  • messages (list of str) – List of human-readable error messages
  • data (dict) – A dict containing the following data representation. ::
    {‘folder_id’: folder_id}

api.v2.attachments.upload_attachment_unified(file_data_base64=None, file_type=None, file_name=None, reference_id=None, reference_type=None, folder_id=None, revisionId=None)[source]

Upload attachment to user folder.

Parameters:
  • file_data_base64 (str) – Base64 encoded data
  • file_type (str) – File MIME type
  • file_name (str) – Filename
  • reference_id (str) – Reference id
  • reference_type (str) – Reference type
  • folder_id (str) – Folder id (oprtional)
  • revisionId (str) – Revision Id (optional)
Returns:

  • success (bool) – True if successful, false if not
  • messages (list of str) – List of human-readable error messages