n8n-nodes-etelecom
Version:
n8n nodes for eTelecom integration
53 lines • 1.68 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.ETelecomApi = exports.eTelecomApi = void 0;
class eTelecomApi {
constructor() {
this.name = 'eTelecomApi';
this.displayName = 'eTelecom API';
this.documentationUrl = 'https://etelecom.vn/docs';
this.properties = [
{
displayName: 'Token',
name: 'token',
type: 'string',
default: '',
typeOptions: {
password: true,
},
required: true,
},
{
displayName: 'Base URL',
name: 'domain',
type: 'string',
default: 'https://api.etelecom.vn/v1',
required: true,
},
];
this.authenticate = {
type: 'generic',
properties: {
headers: {
Authorization: '={{"Bearer " + $credentials.token}}',
},
},
};
this.test = {
request: {
baseURL: '={{$credentials.domain}}',
url: '/shop.Misc/CurrentAccount',
method: 'POST',
headers: {
'Content-Type': 'application/json',
Accept: 'application/json',
Authorization: '={{`Bearer ${$credentials.token}`}}',
},
body: JSON.stringify({}),
},
};
}
}
exports.eTelecomApi = eTelecomApi;
exports.ETelecomApi = eTelecomApi;
//# sourceMappingURL=eTelecomApi.credentials.js.map