I am trying to execute example mentioned in forum to test "Copy a Document

I am trying to execute example mentioned in forum to test "Copy a Document From Appian to SharePoint" functionality using connector functions-

forum.appian.com/.../Connector_Functions

Code / Example from forum connection and API parameters suitable to the my environment-

=load(
local!documentToSend,
a!dashboardLayout(
firstColumnContents: {
a!pickerFieldDocuments(
label: "Document To Send",
maxSelections: 1,
value: local!documentToSend,
saveInto: local!documentToSend
),
if(
isnull(local!documentToSend),
{},
load(
local!shpCopyDocumentFromAppianWriter: bind(
null,
a!shpCopyDocumentFromAppian(
scsExternalSystemKey: "sharepoint",
usePerUserCredentials: true,
hostname: cons!SHAREPOINT_HOSTNAME,
port: cons!SHAREPOINT_PORT,
...

OriginalPostID-112434

OriginalPostID-112434

  Discussion posts and replies are publicly visible

Parents
  • Hi Eduardo and Patty,

    I have ensured to follow all the sets mentioned in the earlier message.

    Here are the changes I have made to the artifacts after importing the application given by you and enabling the loggers.

    I modified-

    APPIAN_SUPPORT_SHAREPOINT_HOSTNAME - http://10.99.42.68
    APPIAN_SUPPORT_SHAREPOINT_PORT - 80
    and finally the following line in the rule AppianSupportSharepointUploadFileInterface because our sharepoint server is hosted on the below location -
    10.99.42.68:80/.../Shared Documents

    Given by you-
    path: "/_api/web/GetFolderByServerRelativeUrl('/Shared%20Documents')/Files/add(url='" &
    document(local!documentToSend[1], "name") & "." & document(local!documentToSend[1], "extension") &"',overwrite=true)"

    Modified by me-
    path: "/sites/testsiteforappian/_api/web/GetFolderByServerRelativeUrl('/Shared%20Documents')/Files/add(url='" &
    document(local!documentToSend[1], "name") & "." & document(local!documentToSend[1], "extension") &"',overwrite=true)"


    The below URL would not work since our sharepoint server is not configured so
    10.99.42.68:80/Shared Documents
Reply
  • Hi Eduardo and Patty,

    I have ensured to follow all the sets mentioned in the earlier message.

    Here are the changes I have made to the artifacts after importing the application given by you and enabling the loggers.

    I modified-

    APPIAN_SUPPORT_SHAREPOINT_HOSTNAME - http://10.99.42.68
    APPIAN_SUPPORT_SHAREPOINT_PORT - 80
    and finally the following line in the rule AppianSupportSharepointUploadFileInterface because our sharepoint server is hosted on the below location -
    10.99.42.68:80/.../Shared Documents

    Given by you-
    path: "/_api/web/GetFolderByServerRelativeUrl('/Shared%20Documents')/Files/add(url='" &
    document(local!documentToSend[1], "name") & "." & document(local!documentToSend[1], "extension") &"',overwrite=true)"

    Modified by me-
    path: "/sites/testsiteforappian/_api/web/GetFolderByServerRelativeUrl('/Shared%20Documents')/Files/add(url='" &
    document(local!documentToSend[1], "name") & "." & document(local!documentToSend[1], "extension") &"',overwrite=true)"


    The below URL would not work since our sharepoint server is not configured so
    10.99.42.68:80/Shared Documents
Children
No Data