diff --git a/certified-connectors/Asite (AUS)/Readme.md b/certified-connectors/Asite (AUS)/Readme.md new file mode 100644 index 0000000000..15588319b7 --- /dev/null +++ b/certified-connectors/Asite (AUS)/Readme.md @@ -0,0 +1,35 @@ +# About + +Asite is an open construction platform that enables organizations with comprehensive range of solutions connect dispersed teams across the lifecycle of capital assets by collaborate, plan, design, and build with seamless information sharing across the entire supply chain which helps capital project owners stay at the forefront of innovation, maintaining a golden thread of information. + +The Asite connector helps to build a connection between two systems for file exchange. The connector collaborates both systems by uploading and downloading files based on triggers. + +# Pre-requisites + +- An active Asite CDE Subscription +- An active Microsoft Power Automate subscription +- An active workflow configuration in Asite platform, configured workflow trigger with the type "Microsoft Flow" + +# Actions + +Following are the internal and external actions used during connection flow to share a file + +| **Name** | **Trigger / Action Name** | **API EndPoint** | **Description** | **Visibility** | +| -------- | ------------------------- | ---------------- | --------------- | -------------- | +| Select Project Name || /workspaceList | It will list out all the Asite's projects where you have access. | Internal | +| Select Folder Name || /folderAndFileList | It will list out all the accessible folders based on your access from the selected Project. | Internal | +| When a workflow is triggered on file(s) | Trigger | /asitePullDataWebhook | This operation triggers a flow when a file is uploaded/updated on the project. The trigger is fired to include sub-folders based on the workflow configuration. | Important | +| Get file content | Action | /downloadFileByUrl | Retrieves the file content from Asite | Important | +| List of configured Triggers from Asite Platform | | /triggerList | To display list of configured Triggers from Asite Platform | Internal | +| Delete configured trigger || /deleteAsitePullDataWebhook/{id}/{nameOfClass} | To Delete configured trigger | Internal | +| Get Dynamic Schema based on project and folder | | /getFolderAttributes | Get Dynamic Schema based on project and folder | Internal | +| Set file metadata | Action | /saveMetadataForUpload | Retrieves standard and custom metadata | Important | +| Create file | Action | /uploadFileFromExternalSystem | Upload a file in Asite project folder. | Important | +| Get dynamic schema based on project Id and trigger Id || /getFolderAttributesFromTrigger | Get dynamic schema based on project Id and trigger Id | Internal | +| Select Folder Name || /getSubFolderList | List out all the accessible folders based on your access from the above selected Project. | Internal | +| When a workflow is triggered on App(s) | Trigger | /asitePullAppFormDataWebhook | This operation triggers a flow when a form is created/updated on the project. Configure separate flows for each App. | Important | +| Get dynamic schema based on project Id and trigger Id | Action | /getFormAttributesFromTrigger | Get dynamic schema based on project Id and trigger Id | Internal | + +# Reference Link: + +Please refer help document for authorize connector and configure flow. [Click here](https://adoddleqa2ak.asite.com/adoddle%20online%20help/Asite_Integration_via_Microsoft_Power_Automate.htm) \ No newline at end of file diff --git a/certified-connectors/Asite (AUS)/apiDefinition.swagger.json b/certified-connectors/Asite (AUS)/apiDefinition.swagger.json new file mode 100644 index 0000000000..af615802cd --- /dev/null +++ b/certified-connectors/Asite (AUS)/apiDefinition.swagger.json @@ -0,0 +1,1163 @@ +{ + "swagger": "2.0", + "info": { + "title": "Asite (AUS)", + "description": "Transform how your teams work together with the Asite connector, the ultimate collaboration solution to build connections between business systems.", + "version": "1.0.0", + "contact": { + "name": "Asite Solutions Limited", + "url": "https://www.asite.com/contact-support", + "email": "support@asite.com" + } + }, + "host": "integrationd.asite.com", + "basePath": "/api", + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://www.asite.com/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://www.asite.com/legal-terms-of-use#privacy" + }, + { + "propertyName": "Categories", + "propertyValue": "Collaboration;Content and Files" + } + ], + "schemes": [ + "https" + ], + "consumes": [ + "application/json", + "application/x-www-form-urlencoded" + ], + "produces": [ + "application/json" + ], + "paths": { + "/workspaceList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "projectName": { + "type": "string", + "description": "projectName" + }, + "cloudUrl": { + "type": "string", + "description": "cloudUrl" + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "operationId": "GET_ASITE_PROJECT_LIST", + "summary": "Select Project Name", + "description": "List out all the Asite's projects where you have access. Please contact support@asite.com for access on required project.", + "x-ms-visibility": "internal", + "consumes": [ + "application/x-www-form-urlencoded" + ], + "parameters": [ + { + "name": "getJsonResult", + "in": "query", + "required": true, + "type": "boolean" + }, + { + "name": "Accept", + "in": "header", + "type": "string", + "required": true + } + ] + } + }, + "/folderAndFileList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "object", + "properties": { + "folderData": { + "type": "array", + "items": { + "type": "object", + "properties": { + "folder_title": { + "type": "string", + "description": "Please select Folder Name followed by Project name." + }, + "folderId": { + "type": "string", + "description": "Unique identification of folder." + } + } + }, + "description": "There is array of folder data." + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Select Folder Name", + "description": "List out all the accessible folders based on your access from the above selected Project.", + "operationId": "GET_ASITE_FOLDER_LIST", + "x-ms-visibility": "internal", + "consumes": [ + "application/x-www-form-urlencoded" + ], + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "isWorkspace", + "in": "query", + "required": true, + "type": "integer" + }, + { + "name": "isFolderDataReq", + "in": "query", + "required": true, + "type": "boolean" + }, + { + "name": "Accept", + "in": "header", + "type": "string", + "required": true + } + ] + } + }, + "/getSubFolderList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "folder_title": { + "type": "string", + "description": "Please select Folder Name followed by Project name." + }, + "folderId": { + "type": "string", + "description": "Unique identification of folder." + }, + "folderPath": { + "type": "string", + "description": "Unique identification of folder path." + }, + "hasSubFolder": { + "type": "boolean", + "description": "identification of sub-folder." + } + } + }, + "description": "There is array of folder data." + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Select Folder Name", + "description": "List out all the accessible folders based on your access from the above selected Project.", + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "x-ms-visibility": "internal", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "folderId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "hasSubFolder", + "in": "query", + "required": true, + "type": "boolean" + } + ] + } + }, + "/asitePullDataWebhook": { + "x-ms-notification-content": { + "description": "When a workflow is triggered on file(s)", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "triggerId": { + "parameter": "resourceId" + }, + "Accept": "*/*" + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "triggerId": { + "parameterReference": "body/resourceId" + }, + "Accept": { + "value": "*/*" + } + } + } + } + }, + "post": { + "responses": { + "201": { + "description": "Created" + } + }, + "summary": "When a workflow is triggered on file(s)", + "description": "This operation triggers a flow when a file is uploaded/updated on the project. The trigger is fired to include sub-folders based on the workflow configuration.", + "operationId": "ASITE_TRIGGER_EVENT", + "x-ms-trigger": "single", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "type": "string", + "required": true, + "in": "query", + "description": "Select a Project", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + }, + "x-ms-summary": "Project Name" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "webhookUrl": { + "type": "string", + "description": "Webhook URL", + "x-ms-notification-url": true, + "x-ms-visibility": "internal", + "x-ms-summary": "Webhook URL" + }, + "resourceId": { + "type": "string", + "description": "Select a Trigger configured for selected project", + "x-ms-summary": "Trigger Name", + "x-ms-dynamic-values": { + "operationId": "ASITE_TRIGGER_LIST", + "value-title": "triggerName", + "value-path": "triggerId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "ruleContext": 3 + } + }, + "x-ms-dynamic-list": { + "operationId": "ASITE_TRIGGER_LIST", + "itemValuePath": "triggerId", + "itemTitlePath": "triggerName", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "ruleContext": { + "value": 3 + } + } + } + }, + "resourceType": { + "type": "integer", + "description": "Resource Type", + "x-ms-summary": "Resource Type", + "x-ms-visibility": "internal", + "default": 1 + } + }, + "required": [ + "webhookUrl", + "resourceId", + "resourceType" + ] + } + } + ] + } + }, + "/downloadFileByUrl": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "format": "binary", + "description": "The content of the file.", + "type": "string", + "x-ms-summary": "File Content" + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Get file content", + "description": "Retrieves the file content from Asite.", + "operationId": "FILE_DOWNLOAD_BY_URL", + "parameters": [ + { + "name": "downloadUrl", + "in": "query", + "required": true, + "type": "string", + "description": "Select 'DirectLink' metadata to download a file", + "x-ms-summary": "URL Selection" + } + ] + } + }, + "/triggerList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "triggerId": { + "type": "integer", + "format": "int32", + "description": "Trigger ID" + }, + "triggerName": { + "type": "string", + "description": "Trigger Name" + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "List of configured Triggers from Asite Platform", + "description": "List of configured Triggers from Asite Platform", + "operationId": "ASITE_TRIGGER_LIST", + "x-ms-visibility": "internal", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "ruleContext", + "in": "query", + "required": true, + "type": "integer" + }, + { + "name": "namespaceId", + "in": "query", + "required": false, + "type": "integer" + } + ] + } + }, + "/deleteAsitePullDataWebhook/{id}/{nameOfClass}": { + "delete": { + "responses": { + "200": { + "description": "OK, Success" + } + }, + "summary": "Delete configured trigger", + "description": "Delete configured trigger", + "operationId": "DELETE_TRIGGER_WEBHOOK", + "x-ms-visibility": "internal", + "parameters": [ + { + "name": "id", + "in": "path", + "required": true, + "x-ms-url-encoding": "single", + "type": "string" + }, + { + "name": "nameOfClass", + "in": "path", + "required": true, + "x-ms-url-encoding": "single", + "type": "string" + } + ] + } + }, + "/getFolderAttributes": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Get Dynamic Schema based on project and folder", + "description": "Get Dynamic Schema based on project and folder", + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "x-ms-visibility": "internal", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "folderId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "isRequiredField", + "in": "query", + "required": true, + "type": "boolean", + "default": false + } + ] + } + }, + "/saveMetadataForUpload": { + "post": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "string", + "title": "Metadata Id" + } + } + }, + "summary": "Set file metadata", + "description": "Retrieves the defined file meta-data and sets the values during the file upload process. Note: it is mandatory to set this action before the Create file action is triggered.", + "operationId": "SET_FILE_METADATA", + "parameters": [ + { + "name": "projectId", + "description": "Select a Project", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Project Name", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + } + }, + { + "name": "folderId", + "description": "Select a Folder", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Folder Name", + "x-ms-dynamic-values": { + "capability": "file-picker", + "value-title": "folder_title", + "value-path": "folderId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "fileFilter": [], + "hasSubFolder": true + } + }, + "x-ms-dynamic-tree": { + "settings": { + "canSelectParentNodes": true, + "canSelectLeafNodes": false + }, + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "itemsPath": "folderData", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "selectedItemValuePath": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + } + } + }, + { + "name": "items", + "in": "body", + "required": true, + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "parameter": "folderId" + }, + "Accept": "*/*", + "isRequiredField": true + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "parameterReference": "folderId" + }, + "Accept": { + "value": "*/*" + }, + "isRequiredField": { + "value": true + } + } + } + } + } + ] + } + }, + "/uploadFileFromExternalSystem": { + "post": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "parameter": "folderId" + }, + "Accept": "*/*", + "isRequiredField": false + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "parameterReference": "folderId" + }, + "Accept": { + "value": "*/*" + }, + "isRequiredField": { + "value": false + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Create file", + "description": "Upload a file in Asite project folder.", + "operationId": "UPLOAD_BINARY_FILE", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "projectId", + "description": "Select a Project", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Project Name", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + } + }, + { + "name": "folderId", + "description": "Select a Folder", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Folder Name", + "x-ms-dynamic-values": { + "capability": "file-picker", + "value-title": "folder_title", + "value-path": "folderId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "fileFilter": [], + "hasSubFolder": true + } + }, + "x-ms-dynamic-tree": { + "settings": { + "canSelectParentNodes": true, + "canSelectLeafNodes": false + }, + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "itemsPath": "folderData", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "selectedItemValuePath": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + } + } + }, + { + "name": "fileName", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "File Name", + "description": "Enter File name with file type extension" + }, + { + "name": "metadataId", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "File Metadata", + "description": "Select Metadata ID from Dynamic Content section" + }, + { + "name": "fileBinary", + "in": "body", + "x-ms-summary": "File Content", + "required": true, + "schema": { + "type": "string", + "format": "binary", + "description": "Binary file content" + } + } + ] + } + }, + "/getFolderAttributesFromTrigger": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + } + }, + "summary": "Get dynamic schema based on project Id and trigger Id", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "triggerId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string" + } + ], + "description": "Get dynamic schema based on project Id and trigger Id", + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "x-ms-visibility": "internal" + } + }, + "/asitePullAppFormDataWebhook": { + "x-ms-notification-content": { + "description": "When a workflow is triggered on App(s)", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "triggerId": { + "parameter": "resourceId" + }, + "Accept": "*/*" + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "triggerId": { + "parameterReference": "body/resourceId" + }, + "Accept": { + "value": "*/*" + } + } + } + } + }, + "post": { + "responses": { + "201": { + "description": "Created" + } + }, + "summary": "When a workflow is triggered on App(s)", + "description": "This operation triggers a flow when a form is created/updated on the project. Configure separate flows for each App.", + "operationId": "ASITE_TRIGGER_EVENT_APP_FORM", + "x-ms-trigger": "single", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "type": "string", + "required": true, + "in": "query", + "description": "Select a Project", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + }, + "x-ms-summary": "Project Name" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "webhookUrl": { + "type": "string", + "description": "Webhook URL", + "x-ms-notification-url": true, + "x-ms-visibility": "internal", + "x-ms-summary": "Webhook URL" + }, + "resourceId": { + "type": "string", + "description": "Select a Trigger configured for selected project", + "x-ms-summary": "Trigger Name", + "x-ms-dynamic-values": { + "operationId": "ASITE_TRIGGER_LIST", + "value-title": "triggerName", + "value-path": "triggerId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "ruleContext": 3, + "namespaceId": 2 + } + }, + "x-ms-dynamic-list": { + "operationId": "ASITE_TRIGGER_LIST", + "itemValuePath": "triggerId", + "itemTitlePath": "triggerName", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "ruleContext": { + "value": 3 + }, + "namespaceId": { + "value": 2 + } + } + } + }, + "resourceType": { + "type": "integer", + "description": "Resource Type", + "x-ms-summary": "Resource Type", + "x-ms-visibility": "internal", + "default": 1 + } + }, + "required": [ + "webhookUrl", + "resourceId", + "resourceType" + ] + } + } + ] + } + }, + "/getFormAttributesFromTrigger": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + } + }, + "summary": "Get dynamic schema based on project Id and trigger Id", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "triggerId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string" + } + ], + "description": "Get dynamic schema based on project Id and trigger Id", + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "x-ms-visibility": "internal" + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": { + "oauth2_auth": { + "type": "oauth2", + "flow": "accessCode", + "authorizationUrl": "https://oauthd.asite.com/oauth/authorize", + "tokenUrl": "https://oauthd.asite.com/oauth/token", + "scopes": { + "DOCUMENT_READ DOCUMENT_WRITE": "DOCUMENT_READ DOCUMENT_WRITE" + } + } + }, + "security": [ + { + "oauth2_auth": [ + "DOCUMENT_READ DOCUMENT_WRITE" + ] + } + ], + "tags": [], + "x-ms-capabilities": { + "file-picker": { + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "value-property": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + }, + "value-title": "folder_title", + "value-path": "folderId", + "value-media-property": "MediaType", + "value-folder-property": "hasSubFolder" + } + } +} \ No newline at end of file diff --git a/certified-connectors/Asite (AUS)/apiProperties.json b/certified-connectors/Asite (AUS)/apiProperties.json new file mode 100644 index 0000000000..7cba7f21d0 --- /dev/null +++ b/certified-connectors/Asite (AUS)/apiProperties.json @@ -0,0 +1,56 @@ +{ + "properties": { + "connectionParameters": { + "token": { + "type": "oauthSetting", + "oAuthSettings": { + "identityProvider": "oauth2", + "clientId": "{{ client id }}", + "scopes": [ + "DOCUMENT_READ DOCUMENT_WRITE" + ], + "redirectMode": "Global", + "properties": { + "IsFirstParty": "False" + }, + "customParameters": { + "authorizationUrl": { + "value": "https://oauthd.asite.com/oauth/authorize" + }, + "tokenUrl": { + "value": "https://oauthd.asite.com/oauth/token" + }, + "refreshUrl": { + "value": "https://oauthd.asite.com/oauth/token" + } + } + } + } + }, + "iconBrandColor": "#1F344A", + "capabilities": [], + "policyTemplateInstances": [ + { + "templateId": "dynamichosturl", + "title": "set Host URL", + "parameters": { + "x-ms-apimTemplateParameter.urlTemplate": "@queryParameters('projectId')", + "x-ms-apimTemplate-operationName": [ + "GET_ASITE_FOLDER_LIST", + "ASITE_TRIGGER_LIST", + "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "SET_FILE_METADATA", + "UPLOAD_BINARY_FILE", + "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "ASITE_TRIGGER_EVENT", + "ASITE_TRIGGER_EVENT_APP_FORM", + "GET_ASITE_SUB_FOLDER_LIST" + ] + } + } + ], + "publisher": "Asite Solutions Limited", + "stackOwner": "Asite Solutions Limited" + } +} diff --git a/certified-connectors/Asite (EU)/Readme.md b/certified-connectors/Asite (EU)/Readme.md new file mode 100644 index 0000000000..15588319b7 --- /dev/null +++ b/certified-connectors/Asite (EU)/Readme.md @@ -0,0 +1,35 @@ +# About + +Asite is an open construction platform that enables organizations with comprehensive range of solutions connect dispersed teams across the lifecycle of capital assets by collaborate, plan, design, and build with seamless information sharing across the entire supply chain which helps capital project owners stay at the forefront of innovation, maintaining a golden thread of information. + +The Asite connector helps to build a connection between two systems for file exchange. The connector collaborates both systems by uploading and downloading files based on triggers. + +# Pre-requisites + +- An active Asite CDE Subscription +- An active Microsoft Power Automate subscription +- An active workflow configuration in Asite platform, configured workflow trigger with the type "Microsoft Flow" + +# Actions + +Following are the internal and external actions used during connection flow to share a file + +| **Name** | **Trigger / Action Name** | **API EndPoint** | **Description** | **Visibility** | +| -------- | ------------------------- | ---------------- | --------------- | -------------- | +| Select Project Name || /workspaceList | It will list out all the Asite's projects where you have access. | Internal | +| Select Folder Name || /folderAndFileList | It will list out all the accessible folders based on your access from the selected Project. | Internal | +| When a workflow is triggered on file(s) | Trigger | /asitePullDataWebhook | This operation triggers a flow when a file is uploaded/updated on the project. The trigger is fired to include sub-folders based on the workflow configuration. | Important | +| Get file content | Action | /downloadFileByUrl | Retrieves the file content from Asite | Important | +| List of configured Triggers from Asite Platform | | /triggerList | To display list of configured Triggers from Asite Platform | Internal | +| Delete configured trigger || /deleteAsitePullDataWebhook/{id}/{nameOfClass} | To Delete configured trigger | Internal | +| Get Dynamic Schema based on project and folder | | /getFolderAttributes | Get Dynamic Schema based on project and folder | Internal | +| Set file metadata | Action | /saveMetadataForUpload | Retrieves standard and custom metadata | Important | +| Create file | Action | /uploadFileFromExternalSystem | Upload a file in Asite project folder. | Important | +| Get dynamic schema based on project Id and trigger Id || /getFolderAttributesFromTrigger | Get dynamic schema based on project Id and trigger Id | Internal | +| Select Folder Name || /getSubFolderList | List out all the accessible folders based on your access from the above selected Project. | Internal | +| When a workflow is triggered on App(s) | Trigger | /asitePullAppFormDataWebhook | This operation triggers a flow when a form is created/updated on the project. Configure separate flows for each App. | Important | +| Get dynamic schema based on project Id and trigger Id | Action | /getFormAttributesFromTrigger | Get dynamic schema based on project Id and trigger Id | Internal | + +# Reference Link: + +Please refer help document for authorize connector and configure flow. [Click here](https://adoddleqa2ak.asite.com/adoddle%20online%20help/Asite_Integration_via_Microsoft_Power_Automate.htm) \ No newline at end of file diff --git a/certified-connectors/Asite (EU)/apiDefinition.swagger.json b/certified-connectors/Asite (EU)/apiDefinition.swagger.json new file mode 100644 index 0000000000..d97c7ece34 --- /dev/null +++ b/certified-connectors/Asite (EU)/apiDefinition.swagger.json @@ -0,0 +1,1163 @@ +{ + "swagger": "2.0", + "info": { + "title": "Asite (EU)", + "description": "Transform how your teams work together with the Asite connector, the ultimate collaboration solution to build connections between business systems.", + "version": "1.0.0", + "contact": { + "name": "Asite Solutions Limited", + "url": "https://www.asite.com/contact-support", + "email": "support@asite.com" + } + }, + "host": "integrationf.asite.com", + "basePath": "/api", + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://www.asite.com/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://www.asite.com/legal-terms-of-use#privacy" + }, + { + "propertyName": "Categories", + "propertyValue": "Collaboration;Content and Files" + } + ], + "schemes": [ + "https" + ], + "consumes": [ + "application/json", + "application/x-www-form-urlencoded" + ], + "produces": [ + "application/json" + ], + "paths": { + "/workspaceList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "projectName": { + "type": "string", + "description": "projectName" + }, + "cloudUrl": { + "type": "string", + "description": "cloudUrl" + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "operationId": "GET_ASITE_PROJECT_LIST", + "summary": "Select Project Name", + "description": "List out all the Asite's projects where you have access. Please contact support@asite.com for access on required project.", + "x-ms-visibility": "internal", + "consumes": [ + "application/x-www-form-urlencoded" + ], + "parameters": [ + { + "name": "getJsonResult", + "in": "query", + "required": true, + "type": "boolean" + }, + { + "name": "Accept", + "in": "header", + "type": "string", + "required": true + } + ] + } + }, + "/folderAndFileList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "object", + "properties": { + "folderData": { + "type": "array", + "items": { + "type": "object", + "properties": { + "folder_title": { + "type": "string", + "description": "Please select Folder Name followed by Project name." + }, + "folderId": { + "type": "string", + "description": "Unique identification of folder." + } + } + }, + "description": "There is array of folder data." + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Select Folder Name", + "description": "List out all the accessible folders based on your access from the above selected Project.", + "operationId": "GET_ASITE_FOLDER_LIST", + "x-ms-visibility": "internal", + "consumes": [ + "application/x-www-form-urlencoded" + ], + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "isWorkspace", + "in": "query", + "required": true, + "type": "integer" + }, + { + "name": "isFolderDataReq", + "in": "query", + "required": true, + "type": "boolean" + }, + { + "name": "Accept", + "in": "header", + "type": "string", + "required": true + } + ] + } + }, + "/getSubFolderList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "folder_title": { + "type": "string", + "description": "Please select Folder Name followed by Project name." + }, + "folderId": { + "type": "string", + "description": "Unique identification of folder." + }, + "folderPath": { + "type": "string", + "description": "Unique identification of folder path." + }, + "hasSubFolder": { + "type": "boolean", + "description": "identification of sub-folder." + } + } + }, + "description": "There is array of folder data." + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Select Folder Name", + "description": "List out all the accessible folders based on your access from the above selected Project.", + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "x-ms-visibility": "internal", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "folderId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "hasSubFolder", + "in": "query", + "required": true, + "type": "boolean" + } + ] + } + }, + "/asitePullDataWebhook": { + "x-ms-notification-content": { + "description": "When a workflow is triggered on file(s)", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "triggerId": { + "parameter": "resourceId" + }, + "Accept": "*/*" + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "triggerId": { + "parameterReference": "body/resourceId" + }, + "Accept": { + "value": "*/*" + } + } + } + } + }, + "post": { + "responses": { + "201": { + "description": "Created" + } + }, + "summary": "When a workflow is triggered on file(s)", + "description": "This operation triggers a flow when a file is uploaded/updated on the project. The trigger is fired to include sub-folders based on the workflow configuration.", + "operationId": "ASITE_TRIGGER_EVENT", + "x-ms-trigger": "single", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "type": "string", + "required": true, + "in": "query", + "description": "Select a Project", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + }, + "x-ms-summary": "Project Name" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "webhookUrl": { + "type": "string", + "description": "Webhook URL", + "x-ms-notification-url": true, + "x-ms-visibility": "internal", + "x-ms-summary": "Webhook URL" + }, + "resourceId": { + "type": "string", + "description": "Select a Trigger configured for selected project", + "x-ms-summary": "Trigger Name", + "x-ms-dynamic-values": { + "operationId": "ASITE_TRIGGER_LIST", + "value-title": "triggerName", + "value-path": "triggerId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "ruleContext": 3 + } + }, + "x-ms-dynamic-list": { + "operationId": "ASITE_TRIGGER_LIST", + "itemValuePath": "triggerId", + "itemTitlePath": "triggerName", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "ruleContext": { + "value": 3 + } + } + } + }, + "resourceType": { + "type": "integer", + "description": "Resource Type", + "x-ms-summary": "Resource Type", + "x-ms-visibility": "internal", + "default": 1 + } + }, + "required": [ + "webhookUrl", + "resourceId", + "resourceType" + ] + } + } + ] + } + }, + "/downloadFileByUrl": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "format": "binary", + "description": "The content of the file.", + "type": "string", + "x-ms-summary": "File Content" + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Get file content", + "description": "Retrieves the file content from Asite.", + "operationId": "FILE_DOWNLOAD_BY_URL", + "parameters": [ + { + "name": "downloadUrl", + "in": "query", + "required": true, + "type": "string", + "description": "Select 'DirectLink' metadata to download a file", + "x-ms-summary": "URL Selection" + } + ] + } + }, + "/triggerList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "triggerId": { + "type": "integer", + "format": "int32", + "description": "Trigger ID" + }, + "triggerName": { + "type": "string", + "description": "Trigger Name" + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "List of configured Triggers from Asite Platform", + "description": "List of configured Triggers from Asite Platform", + "operationId": "ASITE_TRIGGER_LIST", + "x-ms-visibility": "internal", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "ruleContext", + "in": "query", + "required": true, + "type": "integer" + }, + { + "name": "namespaceId", + "in": "query", + "required": false, + "type": "integer" + } + ] + } + }, + "/deleteAsitePullDataWebhook/{id}/{nameOfClass}": { + "delete": { + "responses": { + "200": { + "description": "OK, Success" + } + }, + "summary": "Delete configured trigger", + "description": "Delete configured trigger", + "operationId": "DELETE_TRIGGER_WEBHOOK", + "x-ms-visibility": "internal", + "parameters": [ + { + "name": "id", + "in": "path", + "required": true, + "x-ms-url-encoding": "single", + "type": "string" + }, + { + "name": "nameOfClass", + "in": "path", + "required": true, + "x-ms-url-encoding": "single", + "type": "string" + } + ] + } + }, + "/getFolderAttributes": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Get Dynamic Schema based on project and folder", + "description": "Get Dynamic Schema based on project and folder", + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "x-ms-visibility": "internal", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "folderId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "isRequiredField", + "in": "query", + "required": true, + "type": "boolean", + "default": false + } + ] + } + }, + "/saveMetadataForUpload": { + "post": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "string", + "title": "Metadata Id" + } + } + }, + "summary": "Set file metadata", + "description": "Retrieves the defined file meta-data and sets the values during the file upload process. Note: it is mandatory to set this action before the Create file action is triggered.", + "operationId": "SET_FILE_METADATA", + "parameters": [ + { + "name": "projectId", + "description": "Select a Project", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Project Name", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + } + }, + { + "name": "folderId", + "description": "Select a Folder", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Folder Name", + "x-ms-dynamic-values": { + "capability": "file-picker", + "value-title": "folder_title", + "value-path": "folderId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "fileFilter": [], + "hasSubFolder": true + } + }, + "x-ms-dynamic-tree": { + "settings": { + "canSelectParentNodes": true, + "canSelectLeafNodes": false + }, + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "itemsPath": "folderData", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "selectedItemValuePath": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + } + } + }, + { + "name": "items", + "in": "body", + "required": true, + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "parameter": "folderId" + }, + "Accept": "*/*", + "isRequiredField": true + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "parameterReference": "folderId" + }, + "Accept": { + "value": "*/*" + }, + "isRequiredField": { + "value": true + } + } + } + } + } + ] + } + }, + "/uploadFileFromExternalSystem": { + "post": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "parameter": "folderId" + }, + "Accept": "*/*", + "isRequiredField": false + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "parameterReference": "folderId" + }, + "Accept": { + "value": "*/*" + }, + "isRequiredField": { + "value": false + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Create file", + "description": "Upload a file in Asite project folder.", + "operationId": "UPLOAD_BINARY_FILE", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "projectId", + "description": "Select a Project", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Project Name", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + } + }, + { + "name": "folderId", + "description": "Select a Folder", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Folder Name", + "x-ms-dynamic-values": { + "capability": "file-picker", + "value-title": "folder_title", + "value-path": "folderId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "fileFilter": [], + "hasSubFolder": true + } + }, + "x-ms-dynamic-tree": { + "settings": { + "canSelectParentNodes": true, + "canSelectLeafNodes": false + }, + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "itemsPath": "folderData", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "selectedItemValuePath": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + } + } + }, + { + "name": "fileName", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "File Name", + "description": "Enter File name with file type extension" + }, + { + "name": "metadataId", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "File Metadata", + "description": "Select Metadata ID from Dynamic Content section" + }, + { + "name": "fileBinary", + "in": "body", + "x-ms-summary": "File Content", + "required": true, + "schema": { + "type": "string", + "format": "binary", + "description": "Binary file content" + } + } + ] + } + }, + "/getFolderAttributesFromTrigger": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + } + }, + "summary": "Get dynamic schema based on project Id and trigger Id", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "triggerId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string" + } + ], + "description": "Get dynamic schema based on project Id and trigger Id", + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "x-ms-visibility": "internal" + } + }, + "/asitePullAppFormDataWebhook": { + "x-ms-notification-content": { + "description": "When a workflow is triggered on App(s)", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "triggerId": { + "parameter": "resourceId" + }, + "Accept": "*/*" + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "triggerId": { + "parameterReference": "body/resourceId" + }, + "Accept": { + "value": "*/*" + } + } + } + } + }, + "post": { + "responses": { + "201": { + "description": "Created" + } + }, + "summary": "When a workflow is triggered on App(s)", + "description": "This operation triggers a flow when a form is created/updated on the project. Configure separate flows for each App.", + "operationId": "ASITE_TRIGGER_EVENT_APP_FORM", + "x-ms-trigger": "single", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "type": "string", + "required": true, + "in": "query", + "description": "Select a Project", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + }, + "x-ms-summary": "Project Name" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "webhookUrl": { + "type": "string", + "description": "Webhook URL", + "x-ms-notification-url": true, + "x-ms-visibility": "internal", + "x-ms-summary": "Webhook URL" + }, + "resourceId": { + "type": "string", + "description": "Select a Trigger configured for selected project", + "x-ms-summary": "Trigger Name", + "x-ms-dynamic-values": { + "operationId": "ASITE_TRIGGER_LIST", + "value-title": "triggerName", + "value-path": "triggerId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "ruleContext": 3, + "namespaceId": 2 + } + }, + "x-ms-dynamic-list": { + "operationId": "ASITE_TRIGGER_LIST", + "itemValuePath": "triggerId", + "itemTitlePath": "triggerName", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "ruleContext": { + "value": 3 + }, + "namespaceId": { + "value": 2 + } + } + } + }, + "resourceType": { + "type": "integer", + "description": "Resource Type", + "x-ms-summary": "Resource Type", + "x-ms-visibility": "internal", + "default": 1 + } + }, + "required": [ + "webhookUrl", + "resourceId", + "resourceType" + ] + } + } + ] + } + }, + "/getFormAttributesFromTrigger": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + } + }, + "summary": "Get dynamic schema based on project Id and trigger Id", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "triggerId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string" + } + ], + "description": "Get dynamic schema based on project Id and trigger Id", + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "x-ms-visibility": "internal" + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": { + "oauth2_auth": { + "type": "oauth2", + "flow": "accessCode", + "authorizationUrl": "https://oauthf.asite.com/oauth/authorize", + "tokenUrl": "https://oauthf.asite.com/oauth/token", + "scopes": { + "DOCUMENT_READ DOCUMENT_WRITE": "DOCUMENT_READ DOCUMENT_WRITE" + } + } + }, + "security": [ + { + "oauth2_auth": [ + "DOCUMENT_READ DOCUMENT_WRITE" + ] + } + ], + "tags": [], + "x-ms-capabilities": { + "file-picker": { + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "value-property": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + }, + "value-title": "folder_title", + "value-path": "folderId", + "value-media-property": "MediaType", + "value-folder-property": "hasSubFolder" + } + } +} \ No newline at end of file diff --git a/certified-connectors/Asite (EU)/apiProperties.json b/certified-connectors/Asite (EU)/apiProperties.json new file mode 100644 index 0000000000..04f38c9857 --- /dev/null +++ b/certified-connectors/Asite (EU)/apiProperties.json @@ -0,0 +1,56 @@ +{ + "properties": { + "connectionParameters": { + "token": { + "type": "oauthSetting", + "oAuthSettings": { + "identityProvider": "oauth2", + "clientId": "{{ client id }}", + "scopes": [ + "DOCUMENT_READ DOCUMENT_WRITE" + ], + "redirectMode": "Global", + "properties": { + "IsFirstParty": "False" + }, + "customParameters": { + "authorizationUrl": { + "value": "https://oauthf.asite.com/oauth/authorize" + }, + "tokenUrl": { + "value": "https://oauthf.asite.com/oauth/token" + }, + "refreshUrl": { + "value": "https://oauthf.asite.com/oauth/token" + } + } + } + } + }, + "iconBrandColor": "#1F344A", + "capabilities": [], + "policyTemplateInstances": [ + { + "templateId": "dynamichosturl", + "title": "set Host URL", + "parameters": { + "x-ms-apimTemplateParameter.urlTemplate": "@queryParameters('projectId')", + "x-ms-apimTemplate-operationName": [ + "GET_ASITE_FOLDER_LIST", + "ASITE_TRIGGER_LIST", + "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "SET_FILE_METADATA", + "UPLOAD_BINARY_FILE", + "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "ASITE_TRIGGER_EVENT", + "ASITE_TRIGGER_EVENT_APP_FORM", + "GET_ASITE_SUB_FOLDER_LIST" + ] + } + } + ], + "publisher": "Asite Solutions Limited", + "stackOwner": "Asite Solutions Limited" + } +} diff --git a/certified-connectors/Asite (US)/Readme.md b/certified-connectors/Asite (US)/Readme.md new file mode 100644 index 0000000000..15588319b7 --- /dev/null +++ b/certified-connectors/Asite (US)/Readme.md @@ -0,0 +1,35 @@ +# About + +Asite is an open construction platform that enables organizations with comprehensive range of solutions connect dispersed teams across the lifecycle of capital assets by collaborate, plan, design, and build with seamless information sharing across the entire supply chain which helps capital project owners stay at the forefront of innovation, maintaining a golden thread of information. + +The Asite connector helps to build a connection between two systems for file exchange. The connector collaborates both systems by uploading and downloading files based on triggers. + +# Pre-requisites + +- An active Asite CDE Subscription +- An active Microsoft Power Automate subscription +- An active workflow configuration in Asite platform, configured workflow trigger with the type "Microsoft Flow" + +# Actions + +Following are the internal and external actions used during connection flow to share a file + +| **Name** | **Trigger / Action Name** | **API EndPoint** | **Description** | **Visibility** | +| -------- | ------------------------- | ---------------- | --------------- | -------------- | +| Select Project Name || /workspaceList | It will list out all the Asite's projects where you have access. | Internal | +| Select Folder Name || /folderAndFileList | It will list out all the accessible folders based on your access from the selected Project. | Internal | +| When a workflow is triggered on file(s) | Trigger | /asitePullDataWebhook | This operation triggers a flow when a file is uploaded/updated on the project. The trigger is fired to include sub-folders based on the workflow configuration. | Important | +| Get file content | Action | /downloadFileByUrl | Retrieves the file content from Asite | Important | +| List of configured Triggers from Asite Platform | | /triggerList | To display list of configured Triggers from Asite Platform | Internal | +| Delete configured trigger || /deleteAsitePullDataWebhook/{id}/{nameOfClass} | To Delete configured trigger | Internal | +| Get Dynamic Schema based on project and folder | | /getFolderAttributes | Get Dynamic Schema based on project and folder | Internal | +| Set file metadata | Action | /saveMetadataForUpload | Retrieves standard and custom metadata | Important | +| Create file | Action | /uploadFileFromExternalSystem | Upload a file in Asite project folder. | Important | +| Get dynamic schema based on project Id and trigger Id || /getFolderAttributesFromTrigger | Get dynamic schema based on project Id and trigger Id | Internal | +| Select Folder Name || /getSubFolderList | List out all the accessible folders based on your access from the above selected Project. | Internal | +| When a workflow is triggered on App(s) | Trigger | /asitePullAppFormDataWebhook | This operation triggers a flow when a form is created/updated on the project. Configure separate flows for each App. | Important | +| Get dynamic schema based on project Id and trigger Id | Action | /getFormAttributesFromTrigger | Get dynamic schema based on project Id and trigger Id | Internal | + +# Reference Link: + +Please refer help document for authorize connector and configure flow. [Click here](https://adoddleqa2ak.asite.com/adoddle%20online%20help/Asite_Integration_via_Microsoft_Power_Automate.htm) \ No newline at end of file diff --git a/certified-connectors/Asite (US)/apiDefinition.swagger.json b/certified-connectors/Asite (US)/apiDefinition.swagger.json new file mode 100644 index 0000000000..7a81079532 --- /dev/null +++ b/certified-connectors/Asite (US)/apiDefinition.swagger.json @@ -0,0 +1,1163 @@ +{ + "swagger": "2.0", + "info": { + "title": "Asite (US)", + "description": "Transform how your teams work together with the Asite connector, the ultimate collaboration solution to build connections between business systems.", + "version": "1.0.0", + "contact": { + "name": "Asite Solutions Limited", + "url": "https://www.asite.com/contact-support", + "email": "support@asite.com" + } + }, + "host": "integrationb.asite.com", + "basePath": "/api", + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://www.asite.com/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://www.asite.com/legal-terms-of-use#privacy" + }, + { + "propertyName": "Categories", + "propertyValue": "Collaboration;Content and Files" + } + ], + "schemes": [ + "https" + ], + "consumes": [ + "application/json", + "application/x-www-form-urlencoded" + ], + "produces": [ + "application/json" + ], + "paths": { + "/workspaceList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "projectName": { + "type": "string", + "description": "projectName" + }, + "cloudUrl": { + "type": "string", + "description": "cloudUrl" + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "operationId": "GET_ASITE_PROJECT_LIST", + "summary": "Select Project Name", + "description": "List out all the Asite's projects where you have access. Please contact support@asite.com for access on required project.", + "x-ms-visibility": "internal", + "consumes": [ + "application/x-www-form-urlencoded" + ], + "parameters": [ + { + "name": "getJsonResult", + "in": "query", + "required": true, + "type": "boolean" + }, + { + "name": "Accept", + "in": "header", + "type": "string", + "required": true + } + ] + } + }, + "/folderAndFileList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "object", + "properties": { + "folderData": { + "type": "array", + "items": { + "type": "object", + "properties": { + "folder_title": { + "type": "string", + "description": "Please select Folder Name followed by Project name." + }, + "folderId": { + "type": "string", + "description": "Unique identification of folder." + } + } + }, + "description": "There is array of folder data." + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Select Folder Name", + "description": "List out all the accessible folders based on your access from the above selected Project.", + "operationId": "GET_ASITE_FOLDER_LIST", + "x-ms-visibility": "internal", + "consumes": [ + "application/x-www-form-urlencoded" + ], + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "isWorkspace", + "in": "query", + "required": true, + "type": "integer" + }, + { + "name": "isFolderDataReq", + "in": "query", + "required": true, + "type": "boolean" + }, + { + "name": "Accept", + "in": "header", + "type": "string", + "required": true + } + ] + } + }, + "/getSubFolderList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "folder_title": { + "type": "string", + "description": "Please select Folder Name followed by Project name." + }, + "folderId": { + "type": "string", + "description": "Unique identification of folder." + }, + "folderPath": { + "type": "string", + "description": "Unique identification of folder path." + }, + "hasSubFolder": { + "type": "boolean", + "description": "identification of sub-folder." + } + } + }, + "description": "There is array of folder data." + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Select Folder Name", + "description": "List out all the accessible folders based on your access from the above selected Project.", + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "x-ms-visibility": "internal", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "folderId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "hasSubFolder", + "in": "query", + "required": true, + "type": "boolean" + } + ] + } + }, + "/asitePullDataWebhook": { + "x-ms-notification-content": { + "description": "When a workflow is triggered on file(s)", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "triggerId": { + "parameter": "resourceId" + }, + "Accept": "*/*" + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "triggerId": { + "parameterReference": "body/resourceId" + }, + "Accept": { + "value": "*/*" + } + } + } + } + }, + "post": { + "responses": { + "201": { + "description": "Created" + } + }, + "summary": "When a workflow is triggered on file(s)", + "description": "This operation triggers a flow when a file is uploaded/updated on the project. The trigger is fired to include sub-folders based on the workflow configuration.", + "operationId": "ASITE_TRIGGER_EVENT", + "x-ms-trigger": "single", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "type": "string", + "required": true, + "in": "query", + "description": "Select a Project", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + }, + "x-ms-summary": "Project Name" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "webhookUrl": { + "type": "string", + "description": "Webhook URL", + "x-ms-notification-url": true, + "x-ms-visibility": "internal", + "x-ms-summary": "Webhook URL" + }, + "resourceId": { + "type": "string", + "description": "Select a Trigger configured for selected project", + "x-ms-summary": "Trigger Name", + "x-ms-dynamic-values": { + "operationId": "ASITE_TRIGGER_LIST", + "value-title": "triggerName", + "value-path": "triggerId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "ruleContext": 3 + } + }, + "x-ms-dynamic-list": { + "operationId": "ASITE_TRIGGER_LIST", + "itemValuePath": "triggerId", + "itemTitlePath": "triggerName", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "ruleContext": { + "value": 3 + } + } + } + }, + "resourceType": { + "type": "integer", + "description": "Resource Type", + "x-ms-summary": "Resource Type", + "x-ms-visibility": "internal", + "default": 1 + } + }, + "required": [ + "webhookUrl", + "resourceId", + "resourceType" + ] + } + } + ] + } + }, + "/downloadFileByUrl": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "format": "binary", + "description": "The content of the file.", + "type": "string", + "x-ms-summary": "File Content" + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Get file content", + "description": "Retrieves the file content from Asite.", + "operationId": "FILE_DOWNLOAD_BY_URL", + "parameters": [ + { + "name": "downloadUrl", + "in": "query", + "required": true, + "type": "string", + "description": "Select 'DirectLink' metadata to download a file", + "x-ms-summary": "URL Selection" + } + ] + } + }, + "/triggerList": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "triggerId": { + "type": "integer", + "format": "int32", + "description": "Trigger ID" + }, + "triggerName": { + "type": "string", + "description": "Trigger Name" + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "List of configured Triggers from Asite Platform", + "description": "List of configured Triggers from Asite Platform", + "operationId": "ASITE_TRIGGER_LIST", + "x-ms-visibility": "internal", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "ruleContext", + "in": "query", + "required": true, + "type": "integer" + }, + { + "name": "namespaceId", + "in": "query", + "required": false, + "type": "integer" + } + ] + } + }, + "/deleteAsitePullDataWebhook/{id}/{nameOfClass}": { + "delete": { + "responses": { + "200": { + "description": "OK, Success" + } + }, + "summary": "Delete configured trigger", + "description": "Delete configured trigger", + "operationId": "DELETE_TRIGGER_WEBHOOK", + "x-ms-visibility": "internal", + "parameters": [ + { + "name": "id", + "in": "path", + "required": true, + "x-ms-url-encoding": "single", + "type": "string" + }, + { + "name": "nameOfClass", + "in": "path", + "required": true, + "x-ms-url-encoding": "single", + "type": "string" + } + ] + } + }, + "/getFolderAttributes": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Get Dynamic Schema based on project and folder", + "description": "Get Dynamic Schema based on project and folder", + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "x-ms-visibility": "internal", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "folderId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "isRequiredField", + "in": "query", + "required": true, + "type": "boolean", + "default": false + } + ] + } + }, + "/saveMetadataForUpload": { + "post": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "string", + "title": "Metadata Id" + } + } + }, + "summary": "Set file metadata", + "description": "Retrieves the defined file meta-data and sets the values during the file upload process. Note: it is mandatory to set this action before the Create file action is triggered.", + "operationId": "SET_FILE_METADATA", + "parameters": [ + { + "name": "projectId", + "description": "Select a Project", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Project Name", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + } + }, + { + "name": "folderId", + "description": "Select a Folder", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Folder Name", + "x-ms-dynamic-values": { + "capability": "file-picker", + "value-title": "folder_title", + "value-path": "folderId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "fileFilter": [], + "hasSubFolder": true + } + }, + "x-ms-dynamic-tree": { + "settings": { + "canSelectParentNodes": true, + "canSelectLeafNodes": false + }, + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "itemsPath": "folderData", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "selectedItemValuePath": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + } + } + }, + { + "name": "items", + "in": "body", + "required": true, + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "parameter": "folderId" + }, + "Accept": "*/*", + "isRequiredField": true + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "parameterReference": "folderId" + }, + "Accept": { + "value": "*/*" + }, + "isRequiredField": { + "value": true + } + } + } + } + } + ] + } + }, + "/uploadFileFromExternalSystem": { + "post": { + "responses": { + "200": { + "description": "OK, Success", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "parameter": "folderId" + }, + "Accept": "*/*", + "isRequiredField": false + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "parameterReference": "folderId" + }, + "Accept": { + "value": "*/*" + }, + "isRequiredField": { + "value": false + } + } + } + } + }, + "400": { + "description": "BAD REQUEST, Invalid request" + } + }, + "summary": "Create file", + "description": "Upload a file in Asite project folder.", + "operationId": "UPLOAD_BINARY_FILE", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "projectId", + "description": "Select a Project", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Project Name", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + } + }, + { + "name": "folderId", + "description": "Select a Folder", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "Folder Name", + "x-ms-dynamic-values": { + "capability": "file-picker", + "value-title": "folder_title", + "value-path": "folderId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "fileFilter": [], + "hasSubFolder": true + } + }, + "x-ms-dynamic-tree": { + "settings": { + "canSelectParentNodes": true, + "canSelectLeafNodes": false + }, + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "itemsPath": "folderData", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "itemValuePath": "folderId", + "itemTitlePath": "folder_title", + "itemFullTitlePath": "folderPath", + "itemIsParent": "true", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "folderId": { + "selectedItemValuePath": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + } + } + }, + { + "name": "fileName", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "File Name", + "description": "Enter File name with file type extension" + }, + { + "name": "metadataId", + "in": "query", + "required": true, + "type": "string", + "x-ms-summary": "File Metadata", + "description": "Select Metadata ID from Dynamic Content section" + }, + { + "name": "fileBinary", + "in": "body", + "x-ms-summary": "File Content", + "required": true, + "schema": { + "type": "string", + "format": "binary", + "description": "Binary file content" + } + } + ] + } + }, + "/getFolderAttributesFromTrigger": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + } + }, + "summary": "Get dynamic schema based on project Id and trigger Id", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "triggerId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string" + } + ], + "description": "Get dynamic schema based on project Id and trigger Id", + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "x-ms-visibility": "internal" + } + }, + "/asitePullAppFormDataWebhook": { + "x-ms-notification-content": { + "description": "When a workflow is triggered on App(s)", + "schema": { + "type": "object", + "x-ms-dynamic-schema": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "triggerId": { + "parameter": "resourceId" + }, + "Accept": "*/*" + } + }, + "x-ms-dynamic-properties": { + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "triggerId": { + "parameterReference": "body/resourceId" + }, + "Accept": { + "value": "*/*" + } + } + } + } + }, + "post": { + "responses": { + "201": { + "description": "Created" + } + }, + "summary": "When a workflow is triggered on App(s)", + "description": "This operation triggers a flow when a form is created/updated on the project. Configure separate flows for each App.", + "operationId": "ASITE_TRIGGER_EVENT_APP_FORM", + "x-ms-trigger": "single", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string", + "x-ms-visibility": "internal", + "default": "*/*" + }, + { + "name": "projectId", + "type": "string", + "required": true, + "in": "query", + "description": "Select a Project", + "x-ms-dynamic-values": { + "operationId": "GET_ASITE_PROJECT_LIST", + "value-title": "projectName", + "value-path": "cloudUrl", + "parameters": { + "getJsonResult": true, + "Accept": "*/*" + } + }, + "x-ms-dynamic-list": { + "operationId": "GET_ASITE_PROJECT_LIST", + "itemValuePath": "cloudUrl", + "itemTitlePath": "projectName", + "parameters": { + "getJsonResult": { + "value": true + }, + "Accept": { + "value": "*/*" + } + } + }, + "x-ms-summary": "Project Name" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "webhookUrl": { + "type": "string", + "description": "Webhook URL", + "x-ms-notification-url": true, + "x-ms-visibility": "internal", + "x-ms-summary": "Webhook URL" + }, + "resourceId": { + "type": "string", + "description": "Select a Trigger configured for selected project", + "x-ms-summary": "Trigger Name", + "x-ms-dynamic-values": { + "operationId": "ASITE_TRIGGER_LIST", + "value-title": "triggerName", + "value-path": "triggerId", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "ruleContext": 3, + "namespaceId": 2 + } + }, + "x-ms-dynamic-list": { + "operationId": "ASITE_TRIGGER_LIST", + "itemValuePath": "triggerId", + "itemTitlePath": "triggerName", + "parameters": { + "projectId": { + "parameterReference": "projectId" + }, + "ruleContext": { + "value": 3 + }, + "namespaceId": { + "value": 2 + } + } + } + }, + "resourceType": { + "type": "integer", + "description": "Resource Type", + "x-ms-summary": "Resource Type", + "x-ms-visibility": "internal", + "default": 1 + } + }, + "required": [ + "webhookUrl", + "resourceId", + "resourceType" + ] + } + } + ] + } + }, + "/getFormAttributesFromTrigger": { + "get": { + "responses": { + "200": { + "description": "OK, Success", + "schema": {} + } + }, + "summary": "Get dynamic schema based on project Id and trigger Id", + "parameters": [ + { + "name": "projectId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "triggerId", + "in": "query", + "required": true, + "type": "string" + }, + { + "name": "Accept", + "in": "header", + "required": true, + "type": "string" + } + ], + "description": "Get dynamic schema based on project Id and trigger Id", + "operationId": "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "x-ms-visibility": "internal" + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": { + "oauth2_auth": { + "type": "oauth2", + "flow": "accessCode", + "authorizationUrl": "https://oauthb.asite.com/oauth/authorize", + "tokenUrl": "https://oauthb.asite.com/oauth/token", + "scopes": { + "DOCUMENT_READ DOCUMENT_WRITE": "DOCUMENT_READ DOCUMENT_WRITE" + } + } + }, + "security": [ + { + "oauth2_auth": [ + "DOCUMENT_READ DOCUMENT_WRITE" + ] + } + ], + "tags": [], + "x-ms-capabilities": { + "file-picker": { + "open": { + "operationId": "GET_ASITE_FOLDER_LIST", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "isFolderDataReq": { + "value": true + }, + "isWorkspace": { + "value": 1 + }, + "Accept": { + "value": "*/*" + } + } + }, + "browse": { + "operationId": "GET_ASITE_SUB_FOLDER_LIST", + "parameters": { + "projectId": { + "parameter": "projectId" + }, + "folderId": { + "value-property": "folderId" + }, + "hasSubFolder": { + "value": true + } + } + }, + "value-title": "folder_title", + "value-path": "folderId", + "value-media-property": "MediaType", + "value-folder-property": "hasSubFolder" + } + } +} \ No newline at end of file diff --git a/certified-connectors/Asite (US)/apiProperties.json b/certified-connectors/Asite (US)/apiProperties.json new file mode 100644 index 0000000000..a8247c877f --- /dev/null +++ b/certified-connectors/Asite (US)/apiProperties.json @@ -0,0 +1,56 @@ +{ + "properties": { + "connectionParameters": { + "token": { + "type": "oauthSetting", + "oAuthSettings": { + "identityProvider": "oauth2", + "clientId": "{{ client id }}", + "scopes": [ + "DOCUMENT_READ DOCUMENT_WRITE" + ], + "redirectMode": "Global", + "properties": { + "IsFirstParty": "False" + }, + "customParameters": { + "authorizationUrl": { + "value": "https://oauthb.asite.com/oauth/authorize" + }, + "tokenUrl": { + "value": "https://oauthb.asite.com/oauth/token" + }, + "refreshUrl": { + "value": "https://oauthb.asite.com/oauth/token" + } + } + } + } + }, + "iconBrandColor": "#1F344A", + "capabilities": [], + "policyTemplateInstances": [ + { + "templateId": "dynamichosturl", + "title": "set Host URL", + "parameters": { + "x-ms-apimTemplateParameter.urlTemplate": "@queryParameters('projectId')", + "x-ms-apimTemplate-operationName": [ + "GET_ASITE_FOLDER_LIST", + "ASITE_TRIGGER_LIST", + "GET_CUSTOM_ATTR_DYNAMIC_SCHEMA", + "SET_FILE_METADATA", + "UPLOAD_BINARY_FILE", + "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID", + "GET_DYNAMIC_SCHEMA_PROJECTID_TRIGGERID_FOR_FORM", + "ASITE_TRIGGER_EVENT", + "ASITE_TRIGGER_EVENT_APP_FORM", + "GET_ASITE_SUB_FOLDER_LIST" + ] + } + } + ], + "publisher": "Asite Solutions Limited", + "stackOwner": "Asite Solutions Limited" + } +}