2025-12-15 09:48:31 -05:00
|
|
|
import { INodeType, INodeTypeDescription, NodeConnectionTypes } from 'n8n-workflow';
|
|
|
|
|
export class VerificarEmail implements INodeType {
|
|
|
|
|
description: INodeTypeDescription = {
|
2025-12-15 15:31:21 -05:00
|
|
|
displayName: 'Verificacion de Validez de Email',
|
2025-12-15 09:48:31 -05:00
|
|
|
name: 'verificarEmail',
|
|
|
|
|
icon: 'file:mail-mail-email.svg',
|
|
|
|
|
group: ['transform'],
|
|
|
|
|
version: 1,
|
|
|
|
|
subtitle: '={{$parameter["operation"] + ": " + $parameter["resource"]}}',
|
|
|
|
|
description: 'Node para verificar emails usando un servicio externo (emailable.com)',
|
|
|
|
|
defaults: {
|
|
|
|
|
name: 'Verficar Email',
|
|
|
|
|
},
|
|
|
|
|
inputs: [NodeConnectionTypes.Main],
|
|
|
|
|
outputs: [NodeConnectionTypes.Main],
|
|
|
|
|
credentials: [
|
|
|
|
|
{
|
2025-12-15 15:31:21 -05:00
|
|
|
name: 'verificarEmailApi',
|
2025-12-15 09:48:31 -05:00
|
|
|
required: true,
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
requestDefaults: {
|
2025-12-15 15:31:21 -05:00
|
|
|
baseURL: 'https://api.emailable.com/v1', // Solo el dominio.
|
2025-12-15 09:48:31 -05:00
|
|
|
headers: {
|
|
|
|
|
Accept: 'application/json',
|
|
|
|
|
'Content-Type': 'application/json',
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
properties: [
|
|
|
|
|
{
|
|
|
|
|
displayName: 'Validar Email',
|
|
|
|
|
name: 'email',
|
|
|
|
|
type: 'string',
|
|
|
|
|
placeholder: 'correo@email.com',
|
|
|
|
|
required: true,
|
|
|
|
|
default: 'dylanbohorquez77@gmail.com',
|
|
|
|
|
routing: {
|
2025-12-15 15:31:21 -05:00
|
|
|
request: {
|
|
|
|
|
url: '/verify',
|
|
|
|
|
qs: {
|
|
|
|
|
email: '={{$value}}',
|
|
|
|
|
},
|
2025-12-15 09:48:31 -05:00
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
usableAsTool: true
|
|
|
|
|
};
|
|
|
|
|
}
|