Alfresco

How to Integrate Ephesoft and Alfresco

Enterprises possess and receive a whole lot of documents of various types in hard copies. It is a cumbersome task to add to your Alfresco system. By just scanning the documents and transferring to the document library serves an only a limited purpose. If enterprises try to add the metadata or properties manually to each document, the time take may be irrational to this activity.


To automate this process, Alfresco users can integrate Ephesoft which shortens the above time and cuts the cost of managing this process. This blog explains the easier way to integrate Ephesoft and Alfresco.


This configuration is tested with Alfresco 5.x Community Edition.


Integration of Ephesoft with Alfresco is done by configuring CMIS plugin in Ephesoft. This plugin, as the name itself suggests, can be used to push or pull data from CMIS compatible document repositories such as Alfresco. However, even before that, we have to first prepare Ephesoft by mapping attributes.

Read the blog for How to Integrate Alfresco Login API With Standalone Native Android Application
 

Mapping in Ephesoft

Let us take an example of Invoices which are to be scanned in Ephesoft and pushed to Alfresco. We want to fetch five properties from each invoice viz. part number, invoice total, invoice date, state, and city.
The first step is to edit and configure the DLF-Attribute-mapping.properties file. This file can be found at location [EphesoftInstallationDirectory]SharedFolders[Batch-class-Folder]cmis-plugin-mapping/DLF-Attribute-mapping.properties
 

E.g., if Ephesoft is installed in E: drive, the location of a batch file would be
E:EphesoftSharedFolders/BC12/cmis-plugin-mapping/DLF-Attribute-mapping.properties
Ex. My configuration is(add in DLF-Attribute-mapping.properties )
Bill=D:ephesoft:document
Bill.PartNumber=ephesoft:partNumber
Bill.InvoiceTotal=ephesoft:invoiceTotal
Bill.InvoiceDate=ephesoft:invoiceDate
Bill.State=ephesoft:state
Bill.City=ephesoft:city


Here D: define type property of Alfresco model file and P: define aspect property of the model file.
Here Bill is my document type which I have created in the BC12 batch.
Left side properties are all the properties that I have created in my (Ephesoft) Bill Document type to scan from upload document and right side properties are ones which I have created in my model file.


Configuring Alfresco

The next step is to prepare Alfresco for Ephesoft. There are three configuration files that need to be saved in the Alfresco extension directory. This directory is at the location
< Alfresco installation path>tomcat/shared/classes/alfresco/extension


The files to be added are:

  • Model file: This is the main configuration file that contains parameter mapping, it contains properties that will be scanned from the scanned document from Ephesoft and attached with the document generated in alfresco. My model file is
Ex. ephesoftModel.xml <?xml version="1.0" encoding="UTF-8"?>

<model name="ephesoft:custommodel" xmlns="https://www.alfresco.org/model/dictionary/1.0">
    <description>Example ephesoft custom Model</description>
    <author></author>
    <version>1.0</version>
    <imports>
        <import uri="https://www.alfresco.org/model/dictionary/1.0"
            prefix="d" />

        <import uri="https://www.alfresco.org/model/content/1.0" prefix="cm" />
    </imports>
    <namespaces>
        <namespace uri="https://www.ephesoft1.com/model/content/1.0"
            prefix="ephesoft" />
    </namespaces>

    <types>
        <type name="ephesoft:document">
            <title>ephesoft_scan</title>
            <parent>cm:content</parent>
            <properties>
                <property name="ephesoft:invoiceDate">
                    <title>Invoice Date</title>
                    <type>d:text</type>
                    <index enabled="true">
                        <atomic>true</atomic>
                        <stored>true</stored>
                        <tokenised>true</tokenised>
                    </index>
                </property>
                <property name="ephesoft:accountNumber">
                    <title>Account Number</title>
                    <type>d:text</type>
                    <index enabled="true">
                        <atomic>true</atomic>
                        <stored>true</stored>
                        <tokenised>true</tokenised>
                    </index>
                </property>
                <property name="ephesoft:invoiceTotal">
                    <title>Invoice Total</title>
                    <type>d:text</type>
                    <index enabled="true">
                        <atomic>true</atomic>
                        <stored>true</stored>
                        <tokenised>true</tokenised>
                    </index>
                </property>
                <property name="ephesoft:state">
                    <title>State</title>
                    <type>d:text</type>
                    <index enabled="true">
                        <atomic>true</atomic>
                        <stored>true</stored>
                        <tokenised>true</tokenised>
                    </index>
                </property>
                <property name="ephesoft:city">
                    <title>City</title>
                    <type>d:text</type>
                    <index enabled="true">
                        <atomic>true</atomic>
                        <stored>true</stored>
                        <tokenised>true</tokenised>
                    </index>
                </property>
            </properties>
        </type>
    </types>
</model>

 2) Context File: After that, register that model file in *-context.xml. 
My context file is ephesoft-model-context.xml
			
			<?xml version='1.0' encoding='UTF-8'?> 
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'https://www.springframework.org/dtd/spring-beans.dtd'> 
    <beans> 
    <bean id="extension.dictionaryBootstrap" parent="dictionaryModelBootstrap" 
    depends-on="dictionaryBootstrap"> <property name="models"> 
        <list> 
            <value>alfresco/extension/ephesoftModel.xml</value> 
        </list> 
    </property> 
</bean> 
</beans>
			

Configuring the CMIS plugin in Ephesoft
This is for exporting data from Ephesoft to Alfresco.


Open your Create Batch on ephesoft. Ex BC12
Now Go To Modules->Export-CMIS Export

 

export-cmis-export


CMIS Root Folder Name: This folder will be created in Alfresco.
CMIS Server URL: This is Alfresco Cmis server URL.

This URL may be different depending upon the Alfresco version.

E.g. https://:/alfresco/api/-default-/public/cmis/versions/1.0/atom My url is https://x.x.x.x:8080/alfresco/api/-default-/public/cmis/versions/1.0/atom CMIS url was changed since Alfresco Community Edition 4.2.d.


https://localhost:8080/alfresco/api/-default-/public/cmis/versions/1.0/atom

If you would rather use CMIS 1.1, the URL is:
https://localhost:8080/alfresco/api/-default-/public/cmis/versions/1.1/atom


CMIS Server Username & CMIS Server User Password: these are Alfresco login credentials


CMIS Server Repository Id: This is a unique id of Alfresco repository.
We can get this from below URL
https://:/alfresco/api/-default-/public/cmis/versions/1.1/browser


This is how you will be able to integrate Ephesoft and Alfresco.
For further details or queries, feel free to contact us.

Alfresco Development

Alfresco

Alfresco Development: How It Helps Businesses and Why It's Beneficial

Learn about Alfresco development and its benefits for businesses. Discover how leveraging Alfresco can enhance efficiency and collaboration.

Alfresco ECM Consultants

Alfresco

Alfresco ECM Consultants Unveil Secrets to Success

Mastering Alfresco Development: Essential Tips for Success in ECM Solutions" provides crucial insights and strategies for developers to excel in creating robust ECM solutions using the Alfresco platform. With essential tips and best practices, this resource is indispensable for both novice and experienced developers seeking to harness Alfresco's full potential for ECM projects.

Transform Your Business With Digital Enterprise Solutions

Contact us

Our Offices

INDIA AHMEDABAD, INDIA

401, One World West, Nr. Ambli T-Junction 200, S P Ring Road, Bopal, Ahmedabad, Gujarat 380058

UK
UK

Kemp House 160 City Road, London, United Kingdom EC1V 2NX

GERMANY GERMANY

Nürnberger Str. 46 90579 Langenzenn Deutschland

AUSTRALIA AUSTRALIA

Level 36 Riparian Plaza, 71 Eagle Street, Brisbane, QLD 4000

USA USA

4411 Suwanee Dam road, Bld. 300 Ste. 350 Suwanee GA, 30024

SOUTH AFRICA SOUTH AFRICA

Cube Work Space, 24 Hans Strijdom Avenue, Cape Town

UAE DUBAI, UAE

B 503 Sama Tower, Sheikh Zayed Road, United Arab Emirates

country-flag CANADA

34 Applegrove Ct. Brampton ON L6R 2Y8