UNPKG

n8n-nodes-base

Version:

Base nodes of n8n

15 lines 632 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.addUser = addUser; const transport_1 = require("../../../transport"); async function addUser(index) { const channelId = this.getNodeParameter('channelId', index); const body = {}; const qs = {}; const requestMethod = 'POST'; const endpoint = `channels/${channelId}/members`; body.user_id = this.getNodeParameter('userId', index); const responseData = await transport_1.apiRequest.call(this, requestMethod, endpoint, body, qs); return this.helpers.returnJsonArray(responseData); } //# sourceMappingURL=execute.js.map