n8n-nodes-viviscape
Version:
n8n community node for ViviScape API
51 lines (50 loc) • 1.56 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.ViviScapeApi = void 0;
class ViviScapeApi {
constructor() {
this.name = 'viviScapeApi';
this.displayName = 'ViviScape API';
this.documentationUrl = 'https://api.viviscape.io/swagger/docs/v1';
this.properties = [
{
displayName: 'API Key',
name: 'apiKey', // IMPORTANT: lower camelCase
type: 'string',
typeOptions: {
password: true,
},
default: '',
required: true,
description: 'Your ViviScape API key',
},
{
displayName: 'Base URL',
name: 'baseUrl',
type: 'string',
default: 'https://api.viviscape.io',
required: true,
description: 'The base URL for the ViviScape API',
},
];
this.authenticate = {
type: 'generic',
properties: {
headers: {
APIKey: '={{ $credentials.apiKey }}',
},
},
};
this.test = {
request: {
baseURL: '={{ $credentials.baseUrl }}',
url: '/api/v1/account/info',
method: 'GET',
headers: {
APIKey: '={{ $credentials.apiKey }}',
},
},
};
}
}
exports.ViviScapeApi = ViviScapeApi;