n8n-nodes-evolution-api
Advanced tools
Comparing version 0.1.35 to 0.1.36
@@ -183,2 +183,29 @@ "use strict"; | ||
} | ||
if (resource === 'messages-api' && operation === 'sendVideo') { | ||
const credentials = await this.getCredentials('httpbinApi'); | ||
const serverUrl = credentials['server-url']; | ||
const apiKey = credentials.apikey; | ||
const instanceName = this.getNodeParameter('instanceName', 0); | ||
const remoteJid = this.getNodeParameter('remoteJid', 0); | ||
const media = this.getNodeParameter('media', 0); | ||
const mimetype = this.getNodeParameter('mimetype', 0); | ||
const caption = this.getNodeParameter('caption', 0); | ||
const options = { | ||
method: 'POST', | ||
headers: { | ||
'Content-Type': 'application/json', | ||
apikey: apiKey, | ||
}, | ||
uri: `${serverUrl}/message/sendMedia/${instanceName}`, | ||
body: { | ||
number: remoteJid, | ||
'mediatype': 'video', | ||
media: media, | ||
mimetype: mimetype, | ||
caption: caption, | ||
}, | ||
json: true, | ||
}; | ||
responseData = await this.helpers.request(options); | ||
} | ||
return [this.helpers.returnJsonArray(responseData)]; | ||
@@ -185,0 +212,0 @@ } |
@@ -150,4 +150,7 @@ "use strict"; | ||
number: '={{$node["Número"].number}}', | ||
midia: '={{$node["Video"].midia}}', | ||
text: '={{$node["Mensagem"].text}}', | ||
mediatype: 'video', | ||
mimetype: '={{$node["Mimetype"].mimetype || "video/mp4"}}', | ||
caption: '={{$node["Caption"].caption || "Teste de caption"}}', | ||
media: '={{$node["Imagem"].media}}', | ||
fileName: '={{$node["FileName"].fileName || "Video.mp4"}}', | ||
}, | ||
@@ -524,2 +527,15 @@ }, | ||
{ | ||
displayName: 'Caption', | ||
name: 'caption', | ||
type: 'string', | ||
default: '', | ||
description: 'Texto a ser enviado junto a imagem', | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendImage'], | ||
}, | ||
}, | ||
}, | ||
{ | ||
displayName: 'Mimetype', | ||
@@ -538,2 +554,55 @@ name: 'mimetype', | ||
{ | ||
displayName: 'Nome Do Arquivo', | ||
name: 'fileName', | ||
type: 'string', | ||
default: 'Imagem.png', | ||
description: 'Nome do arquivo da imagem', | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendImage'], | ||
}, | ||
}, | ||
}, | ||
{ | ||
displayName: 'Nome Da Instância', | ||
name: 'instanceName', | ||
type: 'string', | ||
default: '', | ||
description: 'Digite o nome da instância que vai enviar o vídeo', | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendVideo'], | ||
}, | ||
}, | ||
}, | ||
{ | ||
displayName: 'Número Do Destinatário', | ||
name: 'remoteJid', | ||
type: 'string', | ||
default: '', | ||
required: true, | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendVideo'], | ||
}, | ||
}, | ||
}, | ||
{ | ||
displayName: 'Vídeo', | ||
name: 'media', | ||
type: 'string', | ||
default: '', | ||
required: true, | ||
description: 'URL ou base64 do vídeo', | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendVideo'], | ||
}, | ||
}, | ||
}, | ||
{ | ||
displayName: 'Caption', | ||
@@ -543,7 +612,7 @@ name: 'caption', | ||
default: '', | ||
description: 'Texto a ser enviado junto a imagem', | ||
description: 'Texto a ser enviado junto ao vídeo', | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendImage'], | ||
operation: ['sendVideo'], | ||
}, | ||
@@ -553,11 +622,24 @@ }, | ||
{ | ||
displayName: 'Mimetype', | ||
name: 'mimetype', | ||
type: 'string', | ||
default: 'video/mp4', | ||
description: 'Tipo MIME do vídeo', | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendVideo'], | ||
}, | ||
}, | ||
}, | ||
{ | ||
displayName: 'Nome Do Arquivo', | ||
name: 'fileName', | ||
type: 'string', | ||
default: 'Imagem.png', | ||
description: 'Nome do arquivo da imagem', | ||
default: 'Video.mp4', | ||
description: 'Nome do arquivo do vídeo', | ||
displayOptions: { | ||
show: { | ||
resource: ['messages-api'], | ||
operation: ['sendImage'], | ||
operation: ['sendVideo'], | ||
}, | ||
@@ -564,0 +646,0 @@ }, |
{ | ||
"name": "n8n-nodes-evolution-api", | ||
"version": "0.1.35", | ||
"version": "0.1.36", | ||
"description": "Api não oficial do WhatsApp", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
{ | ||
"name": "n8n-nodes-evolution-api", | ||
"version": "0.1.35", | ||
"version": "0.1.36", | ||
"description": "Api não oficial do WhatsApp", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -1,46 +0,21 @@ | ||
![Banner image](https://user-images.githubusercontent.com/10284570/173569848-c624317f-42b1-45a6-ab09-f0ea3c247648.png) | ||
**[ Features do Node ]** | ||
# n8n-nodes-starter | ||
This repo contains example nodes to help you get started building your own custom integrations for [n8n](n8n.io). It includes the node linter and other dependencies. | ||
To make your custom node available to the community, you must create it as an npm package, and [submit it to the npm registry](https://docs.npmjs.com/packages-and-modules/contributing-packages-to-the-registry). | ||
## Prerequisites | ||
You need the following installed on your development machine: | ||
* [git](https://git-scm.com/downloads) | ||
* Node.js and pnpm. Minimum version Node 18. You can find instructions on how to install both using nvm (Node Version Manager) for Linux, Mac, and WSL [here](https://github.com/nvm-sh/nvm). For Windows users, refer to Microsoft's guide to [Install NodeJS on Windows](https://docs.microsoft.com/en-us/windows/dev-environment/javascript/nodejs-on-windows). | ||
* Install n8n with: | ||
``` | ||
pnpm install n8n -g | ||
``` | ||
* Recommended: follow n8n's guide to [set up your development environment](https://docs.n8n.io/integrations/creating-nodes/build/node-development-environment/). | ||
## Using this starter | ||
These are the basic steps for working with the starter. For detailed guidance on creating and publishing nodes, refer to the [documentation](https://docs.n8n.io/integrations/creating-nodes/). | ||
1. [Generate a new repository](https://github.com/n8n-io/n8n-nodes-starter/generate) from this template repository. | ||
2. Clone your new repo: | ||
``` | ||
git clone https://github.com/<your organization>/<your-repo-name>.git | ||
``` | ||
3. Run `pnpm i` to install dependencies. | ||
4. Open the project in your editor. | ||
5. Browse the examples in `/nodes` and `/credentials`. Modify the examples, or replace them with your own nodes. | ||
6. Update the `package.json` to match your details. | ||
7. Run `pnpm lint` to check for errors or `pnpm lintfix` to automatically fix errors when possible. | ||
8. Test your node locally. Refer to [Run your node locally](https://docs.n8n.io/integrations/creating-nodes/test/run-node-locally/) for guidance. | ||
9. Replace this README with documentation for your node. Use the [README_TEMPLATE](README_TEMPLATE.md) to get started. | ||
10. Update the LICENSE file to use your details. | ||
11. [Publish](https://docs.npmjs.com/packages-and-modules/contributing-packages-to-the-registry) your package to npm. | ||
## More information | ||
Refer to our [documentation on creating nodes](https://docs.n8n.io/integrations/creating-nodes/) for detailed information on building your own nodes. | ||
## License | ||
[MIT](https://github.com/n8n-io/n8n-nodes-starter/blob/master/LICENSE.md) | ||
Instancias: <br> | ||
✅ Criação de Instancias Básicas;<br> (by Orion) | ||
✅ Criação de Instancias com Proxy;<br> (by Orion) | ||
✅ Busca por instancias (com e sem filtro);<br> (by Orion) | ||
❌ Configurações da instancia;<br> | ||
❌ Conexão de instância;<br> | ||
❌ Reiniciar instancia;<br> | ||
❌ Desconectar instancia;<br> | ||
❌ Deletar instancia;<br> | ||
<br> | ||
Mensagens:<br> | ||
✅ Enviar mensagem de texto;<br> (by Orion) | ||
✅ Enviar mensagem de imagem;<br> (by Orion) | ||
✅ Enviar mensagem de video;<br> (by Orion) | ||
❌ Enviar mensagem de audio;<br> | ||
❌ Enviar mensagem de documentos;<br> | ||
❌ Enviar mensagem de status;<br> | ||
❌ Enviar mensagem de enquete;<br> | ||
❌ Enviar mensagem de lista;<br> |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
83370
1035
22