Question

Streaming PDF's into creatio in Attachments and Notes

Hi community,

 

For my customers, they have a bulk of pdf's which they want to upload into creatio all at the same time and automatic attachment of those pdf's to the section records.

 

In the below article, I have found that with OData4 streaming is possible but it only enables Reading , modifying and deleting.

https://academy.creatio.com/documents/technic-sdk/7-16/working-stream-data

 

In this below article I haven't found any example of how to stream documents to creatio using OData4 

https://academy.creatio.com/documents/technic-sdk/7-16/creatio-integration-odata-4-protocol

 

Though I have found one community article(link below), but that was too old and one community person has written that with current version writing the C# methods don't work.

https://community.creatio.com/questions/how-upload-attachments-odata 

 

In the below screenshot it has mentioned to look at FileServices and FileRepository schemas which I have got in current version.

 

 

Do I need to write my own custom C# code in source code schema in order to achive the same? If yes then which among FileServices OR FileRepository schemas to use to upload the bulk of pdf's all at the same time and attaching with the records.

 

Many thanks.

Looking forward to your positive reply!

 

Best,

Akshit.

 

Like 0

Like

1 comments

Hi Akshit,

 

The UPLOAD of FileApiService hasn't changed much since Anastasia posted her comment on the community and you can use the FileApiService as an example when developing your custom C# code for files uploading to the system. Here is the link that is formed upon file attaching:

 

http://sitename/0/rest/FileApiService/Upload?fileapi16033613316825&tota…

 

where

 

fileId - an automatically generated Id of the attachment record in the entitySchemaName parameter object

 

parentColumnName - the name of the object where the "Attachments and notes" detail is located (which section does the record to which the file is uploaded represent)

 

parentColumnValue - the ID of the record in the object from parentColumnName

 

entitySchemaName - the name of the object that represents the attachments and notes detail (can be AccountFile, ActivityFile etc.)

 

and the content of the file itself is transferred via fileContent parameter. So please use a ready service an example when developing your own service.

 

Best regards,

Oscar

Show all comments