mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-21 20:00:02 +00:00
add xml body parser for xml webhook support
This commit is contained in:
@@ -7,6 +7,7 @@ import {
|
||||
getConnectionManager,
|
||||
} from 'typeorm';
|
||||
import * as bodyParser from 'body-parser';
|
||||
require('body-parser-xml')(bodyParser);
|
||||
import * as history from 'connect-history-api-fallback';
|
||||
import * as requestPromise from 'request-promise-native';
|
||||
|
||||
@@ -232,6 +233,10 @@ class App {
|
||||
// Support application/json type post data
|
||||
this.app.use(bodyParser.json({ limit: "16mb" }));
|
||||
|
||||
// Support application/xml type post data
|
||||
// @ts-ignore
|
||||
this.app.use(bodyParser.xml({ limit: "16mb" }));
|
||||
|
||||
// Make sure that Vue history mode works properly
|
||||
this.app.use(history({
|
||||
rewrites: [
|
||||
|
||||
Reference in New Issue
Block a user