UNPKG

n8n-nodes-sap-service-layer

Version:

n8n custom node for SAP Service Layer integration

73 lines (72 loc) 2.27 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.SapServiceLayerApi = void 0; class SapServiceLayerApi { constructor() { this.name = 'sapServiceLayerApi'; this.displayName = 'PlantScanner - SAP Service Layer API'; this.documentationUrl = 'https://developers.plantscanner.io'; this.properties = [ { displayName: 'Service Layer URL', name: 'url', type: 'string', default: 'https://sl-eqnx.datacore.com.br:31218/b1s/v1', required: true, }, { displayName: 'Company DB', name: 'companyDB', type: 'string', default: '', required: true, }, { displayName: 'Username', name: 'username', type: 'string', default: '', required: true, }, { displayName: 'Password', name: 'password', type: 'string', typeOptions: { password: true, }, default: '', required: true, }, { displayName: 'Language', name: 'language', type: 'number', default: 1, required: false, }, ]; this.authenticate = { type: 'generic', properties: { headers: { 'Content-Type': 'application/json', }, }, }; this.test = { request: { method: 'POST', url: '={{$credentials.url}}/Login', body: { CompanyDB: '={{$credentials.companyDB}}', UserName: '={{$credentials.username}}', Password: '={{$credentials.password}}', Language: '={{$credentials.language || 1}}', }, skipSslCertificateValidation: true, }, }; } } exports.SapServiceLayerApi = SapServiceLayerApi;