n8n-nodes-base
Version:
Base nodes of n8n
51 lines (48 loc) • 1.44 kB
text/typescript
/**
* XML Node - Version 1
* Discriminator: mode=jsonToxml
*/
/** Converts data from JSON to XML */
export type XmlV1JsonToxmlParams = {
mode: 'jsonToxml';
/**
* Name of the property to which to contains the converted XML data
* @default data
*/
dataPropertyName?: string | Expression<string> | PlaceholderValue;
/**
* Options
* @default {}
*/
options?: {
/** Whether to allow using characters from the Unicode surrogate blocks
* @default false
*/
allowSurrogateChars?: boolean | Expression<boolean>;
/** Prefix that is used to access the attributes
* @default $
*/
attrkey?: string | Expression<string> | PlaceholderValue;
/** Whether to wrap text nodes in <![CDATA[ ... ]]> instead of escaping when necessary. Does not add <![CDATA[ ... ]]> if it is not required.
* @default false
*/
cdata?: boolean | Expression<boolean>;
/** Prefix that is used to access the character content
* @default _
*/
charkey?: string | Expression<string> | PlaceholderValue;
/** Whether to omit the XML header
* @default false
*/
headless?: boolean | Expression<boolean>;
/** Root element name to be used
* @default root
*/
rootName?: string | Expression<string> | PlaceholderValue;
};
};
export type XmlV1JsonToxmlNode = {
type: 'n8n-nodes-base.xml';
version: 1;
config: NodeConfig<XmlV1JsonToxmlParams>;
};