n8n-nodes-digitalsac 0.4.2 → 0.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -26,6 +26,7 @@ Este pacote adiciona um nó personalizado ao n8n para interagir com a API do Dig
|
|
|
26
26
|
- Listar Horários Disponíveis
|
|
27
27
|
- Criar Agendamento
|
|
28
28
|
- Cancelar Agendamento
|
|
29
|
+
- Gerar Link do Calendário (.ics)
|
|
29
30
|
|
|
30
31
|
## Instalação
|
|
31
32
|
|
|
@@ -329,6 +330,15 @@ Onde:
|
|
|
329
330
|
}
|
|
330
331
|
```
|
|
331
332
|
|
|
333
|
+
### Gerar link de calendário para um agendamento
|
|
334
|
+
1. Adicione um nó **Digitalsac**
|
|
335
|
+
- Operação: **Gerar Link do Calendário (.ics)**
|
|
336
|
+
- ID do Agendamento: `123`
|
|
337
|
+
2. O retorno pode ser usado para:
|
|
338
|
+
- Enviar o link direto para o cliente
|
|
339
|
+
- Fazer download automático do arquivo .ics
|
|
340
|
+
- Integrar com outros sistemas de calendário
|
|
341
|
+
|
|
332
342
|
## Funcionalidades de Agendamento
|
|
333
343
|
|
|
334
344
|
### Listar Serviços
|
|
@@ -420,6 +430,33 @@ Cancela um agendamento existente.
|
|
|
420
430
|
}
|
|
421
431
|
```
|
|
422
432
|
|
|
433
|
+
### Gerar Link do Calendário (.ics)
|
|
434
|
+
Gera um link para download do arquivo .ics (calendário) de um agendamento específico.
|
|
435
|
+
1. Selecione a operação **Gerar Link do Calendário (.ics)**
|
|
436
|
+
2. Preencha:
|
|
437
|
+
- **ID do Agendamento**: ID do agendamento para gerar o link do calendário
|
|
438
|
+
|
|
439
|
+
**Retorno exemplo:**
|
|
440
|
+
```json
|
|
441
|
+
{
|
|
442
|
+
"status": 1,
|
|
443
|
+
"link": "https://seudominio.com/schedules/123/ics",
|
|
444
|
+
"scheduleId": 123,
|
|
445
|
+
"info": {
|
|
446
|
+
"cliente": "João Silva",
|
|
447
|
+
"servico": "Consulta Médica",
|
|
448
|
+
"data": "2025-01-15T14:30:00.000Z",
|
|
449
|
+
"funcionario": "Dr. Pedro Santos"
|
|
450
|
+
}
|
|
451
|
+
}
|
|
452
|
+
```
|
|
453
|
+
|
|
454
|
+
**Uso do link:**
|
|
455
|
+
- O link gerado pode ser usado diretamente para download do arquivo .ics
|
|
456
|
+
- O arquivo .ics contém todas as informações do agendamento
|
|
457
|
+
- Pode ser importado em qualquer aplicativo de calendário (Google Calendar, Outlook, Apple Calendar, etc.)
|
|
458
|
+
- É útil para integração com sistemas externos ou envio para clientes
|
|
459
|
+
|
|
423
460
|
## Suporte
|
|
424
461
|
|
|
425
462
|
Para suporte, entre em contato com [contato@digitalsac.io](mailto:contato@digitalsac.io).
|
|
@@ -50,6 +50,7 @@ class Digitalsac {
|
|
|
50
50
|
{ name: 'Listar Agendamentos', value: 'listSchedules' },
|
|
51
51
|
{ name: 'Criar Agendamento', value: 'createSchedule' },
|
|
52
52
|
{ name: 'Cancelar Agendamento', value: 'cancelSchedule' },
|
|
53
|
+
{ name: 'Gerar Link do Calendário (.ics)', value: 'calendarLink' },
|
|
53
54
|
],
|
|
54
55
|
default: 'validateWhatsapp',
|
|
55
56
|
},
|
|
@@ -419,6 +420,18 @@ class Digitalsac {
|
|
|
419
420
|
},
|
|
420
421
|
description: 'ID do agendamento a ser cancelado',
|
|
421
422
|
},
|
|
423
|
+
{
|
|
424
|
+
displayName: 'ID do Agendamento',
|
|
425
|
+
name: 'calendarScheduleId',
|
|
426
|
+
type: 'number',
|
|
427
|
+
default: 0,
|
|
428
|
+
displayOptions: {
|
|
429
|
+
show: {
|
|
430
|
+
operation: ['calendarLink'],
|
|
431
|
+
},
|
|
432
|
+
},
|
|
433
|
+
description: 'ID do agendamento para gerar o link do calendário',
|
|
434
|
+
},
|
|
422
435
|
],
|
|
423
436
|
};
|
|
424
437
|
}
|
|
@@ -768,6 +781,10 @@ class Digitalsac {
|
|
|
768
781
|
json: true,
|
|
769
782
|
};
|
|
770
783
|
break;
|
|
784
|
+
case 'calendarLink':
|
|
785
|
+
const calendarScheduleId = this.getNodeParameter('calendarScheduleId', i);
|
|
786
|
+
url = `/typebot/calendar-link?scheduleId=${calendarScheduleId}`;
|
|
787
|
+
break;
|
|
771
788
|
}
|
|
772
789
|
// Se as opções não foram definidas no switch, defina-as aqui para operações GET
|
|
773
790
|
if (!options.method) {
|
|
@@ -57,6 +57,7 @@ export class Digitalsac implements INodeType {
|
|
|
57
57
|
{ name: 'Listar Agendamentos', value: 'listSchedules' },
|
|
58
58
|
{ name: 'Criar Agendamento', value: 'createSchedule' },
|
|
59
59
|
{ name: 'Cancelar Agendamento', value: 'cancelSchedule' },
|
|
60
|
+
{ name: 'Gerar Link do Calendário (.ics)', value: 'calendarLink' },
|
|
60
61
|
],
|
|
61
62
|
default: 'validateWhatsapp',
|
|
62
63
|
},
|
|
@@ -426,6 +427,18 @@ export class Digitalsac implements INodeType {
|
|
|
426
427
|
},
|
|
427
428
|
description: 'ID do agendamento a ser cancelado',
|
|
428
429
|
},
|
|
430
|
+
{
|
|
431
|
+
displayName: 'ID do Agendamento',
|
|
432
|
+
name: 'calendarScheduleId',
|
|
433
|
+
type: 'number',
|
|
434
|
+
default: 0,
|
|
435
|
+
displayOptions: {
|
|
436
|
+
show: {
|
|
437
|
+
operation: ['calendarLink'],
|
|
438
|
+
},
|
|
439
|
+
},
|
|
440
|
+
description: 'ID do agendamento para gerar o link do calendário',
|
|
441
|
+
},
|
|
429
442
|
],
|
|
430
443
|
};
|
|
431
444
|
|
|
@@ -798,6 +811,12 @@ export class Digitalsac implements INodeType {
|
|
|
798
811
|
json: true,
|
|
799
812
|
};
|
|
800
813
|
break;
|
|
814
|
+
|
|
815
|
+
case 'calendarLink':
|
|
816
|
+
const calendarScheduleId = this.getNodeParameter('calendarScheduleId', i) as number;
|
|
817
|
+
|
|
818
|
+
url = `/typebot/calendar-link?scheduleId=${calendarScheduleId}`;
|
|
819
|
+
break;
|
|
801
820
|
}
|
|
802
821
|
|
|
803
822
|
// Se as opções não foram definidas no switch, defina-as aqui para operações GET
|