// AUTO-GENERATED — do not edit by hand
// Upstream: https://github.com/n8n-io/n8n/blob/master/packages/@n8n/nodes-langchain/nodes/trigger/ChatTrigger/ChatTrigger.node.ts
// To implement: copy to ../impl/allowfileuploads.rs, fill in execute(), add to ../impl/mod.rs
// r8r: rust port of n8n.io
// License: Unlicense

use async_trait::async_trait;
use crate::core::error::NodeError;
use crate::core::types::*;
use crate::engine::{ExecuteCtx, Node, NodeFactory};
use std::sync::Arc;

pub struct AllowfileuploadsNode;

static META: NodeMetadata = NodeMetadata {
    name: "allowfileuploads",
    display_name: "Allow File Uploads",
    version: &[1],
    group: &["transform"],
    description: "Whether to allow file uploads in the chat",
    inputs: 1,
    outputs: 1,
    properties: &[
    PropertyDef { name: "public", display_name: "Make Chat Publicly Available", kind: PropertyKind::Boolean, required: false, default: None },
    PropertyDef { name: "mode", display_name: "Mode", kind: PropertyKind::Options, required: false, default: Some("hostedChat") },
    PropertyDef { name: "hostedChatNotice", display_name: "Chat will be live at the URL above once this workflow is published. Live executions will show up in the ‘executions’ tab", kind: PropertyKind::Notice, required: false, default: Some("") },
    PropertyDef { name: "embeddedChatNotice", display_name: "Follow the instructions <a href=", kind: PropertyKind::Notice, required: false, default: Some("") },
    PropertyDef { name: "authentication", display_name: "Authentication", kind: PropertyKind::Options, required: false, default: Some("none") },
    PropertyDef { name: "initialMessages", display_name: "Initial Message(s)", kind: PropertyKind::String, required: false, default: Some("Hi there! 👋\\nMy name is Nathan. How can I assist you today?") },
    PropertyDef { name: "availableInChat", display_name: "Make Available in n8n Chat Hub", kind: PropertyKind::Boolean, required: false, default: None },
    PropertyDef { name: "availableInChatNotice", display_name: "Your Chat Trigger node is out of date. To update, delete this node and insert a new Chat Trigger node.", kind: PropertyKind::Notice, required: false, default: Some("") },
    PropertyDef { name: "availableInChatNotice", display_name: "Your n8n users will be able to use this agent in <a href=", kind: PropertyKind::Notice, required: false, default: Some("") },
    PropertyDef { name: "agentIcon", display_name: "Agent Icon", kind: PropertyKind::String, required: false, default: None },
    PropertyDef { name: "agentName", display_name: "Agent Name", kind: PropertyKind::String, required: false, default: Some("") },
    PropertyDef { name: "agentDescription", display_name: "Agent Description", kind: PropertyKind::String, required: false, default: Some("") },
    PropertyDef { name: "suggestedPrompts", display_name: "Suggestions", kind: PropertyKind::FixedCollection, required: true, default: Some("") },
    PropertyDef { name: "options", display_name: "Options", kind: PropertyKind::Collection, required: false, default: None },
    PropertyDef { name: "options", display_name: "Options", kind: PropertyKind::Collection, required: false, default: Some("lastNode") },
    PropertyDef { name: "options", display_name: "Options", kind: PropertyKind::Collection, required: false, default: Some("lastNode") },
    PropertyDef { name: "options", display_name: "Options", kind: PropertyKind::Collection, required: false, default: Some("lastNode") },
    PropertyDef { name: "options", display_name: "Options", kind: PropertyKind::Collection, required: false, default: Some("lastNode") }
],
    credentials: &[
    CredentialRef { name: "httpBasicAuth", required: true }
],
};

#[async_trait]
impl Node for AllowfileuploadsNode {
    fn metadata(&self) -> &'static NodeMetadata { &META }

    async fn execute(&self, _ctx: &mut ExecuteCtx<'_>) -> Result<NodeOutput, NodeError> {
        Err(NodeError::NotYetPorted {
            node: "allowfileuploads",
            upstream: "https://github.com/n8n-io/n8n/blob/master/packages/@n8n/nodes-langchain/nodes/trigger/ChatTrigger/ChatTrigger.node.ts",
        })
    }
}

inventory::submit! { NodeFactory::new("allowfileuploads", || Arc::new(AllowfileuploadsNode)) }
