mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
feat(Webhook Node): Add notices about using the 'Content-Type' header (#17739)
This commit is contained in:
@@ -23,9 +23,9 @@ import {
|
|||||||
} from 'n8n-workflow';
|
} from 'n8n-workflow';
|
||||||
import type { Readable } from 'stream';
|
import type { Readable } from 'stream';
|
||||||
|
|
||||||
import { formatPrivateKey, generatePairedItemData } from '../../utils/utilities';
|
|
||||||
import { configuredOutputs } from './utils/outputs';
|
|
||||||
import { getBinaryResponse } from './utils/binary';
|
import { getBinaryResponse } from './utils/binary';
|
||||||
|
import { configuredOutputs } from './utils/outputs';
|
||||||
|
import { formatPrivateKey, generatePairedItemData } from '../../utils/utilities';
|
||||||
|
|
||||||
const respondWithProperty: INodeProperties = {
|
const respondWithProperty: INodeProperties = {
|
||||||
displayName: 'Respond With',
|
displayName: 'Respond With',
|
||||||
@@ -252,7 +252,18 @@ export class RespondToWebhook implements INodeType {
|
|||||||
},
|
},
|
||||||
description: 'The name of the node input field with the binary data',
|
description: 'The name of the node input field with the binary data',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
displayName:
|
||||||
|
'To avoid unexpected behavior, add a "Content-Type" response header with the appropriate value',
|
||||||
|
name: 'contentTypeNotice',
|
||||||
|
type: 'notice',
|
||||||
|
default: '',
|
||||||
|
displayOptions: {
|
||||||
|
show: {
|
||||||
|
respondWith: ['text'],
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
displayName: 'Options',
|
displayName: 'Options',
|
||||||
name: 'options',
|
name: 'options',
|
||||||
|
|||||||
@@ -175,6 +175,18 @@ export class Webhook extends Node {
|
|||||||
},
|
},
|
||||||
responseDataProperty,
|
responseDataProperty,
|
||||||
responseBinaryPropertyNameProperty,
|
responseBinaryPropertyNameProperty,
|
||||||
|
{
|
||||||
|
displayName:
|
||||||
|
'If you are sending back a response, add a "Content-Type" response header with the appropriate value to avoid unexpected behavior',
|
||||||
|
name: 'contentTypeNotice',
|
||||||
|
type: 'notice',
|
||||||
|
default: '',
|
||||||
|
displayOptions: {
|
||||||
|
show: {
|
||||||
|
responseMode: ['onReceived'],
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
...optionsProperty,
|
...optionsProperty,
|
||||||
|
|||||||
Reference in New Issue
Block a user