// AUTO-GENERATED — do not edit by hand
// Upstream: https://github.com/n8n-io/n8n/blob/master/packages/@n8n/nodes-langchain/nodes/vendors/Microsoft/MicrosoftAgent365Trigger.node.ts
// To implement: copy to ../impl/microsoftagent365trigger.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 Microsoftagent365triggerNode;

static META: NodeMetadata = NodeMetadata {
    name: "microsoftagent365trigger",
    display_name: "Microsoft Agent 365 Trigger",
    version: &[1],
    group: &["transform"],
    description: "Trigger for Microsoft Agent 365",
    inputs: 1,
    outputs: 1,
    properties: &[
    PropertyDef { name: "previewNotice", display_name: "This is an early preview for building Agents with Microsoft Agent 365 and n8n. You need to be part of the <a href=", kind: PropertyKind::Notice, required: false, default: Some("") },
    PropertyDef { name: "systemPrompt", display_name: "System Prompt", kind: PropertyKind::String, required: false, default: Some("") },
    PropertyDef { name: "notice", display_name: "Connect an <a data-action=", kind: PropertyKind::Notice, required: false, default: Some("") },
    PropertyDef { name: "needsFallback", display_name: "Enable Fallback Model", kind: PropertyKind::Boolean, required: false, default: None },
    PropertyDef { name: "fallbackNotice", display_name: "Connect an additional language model on the canvas to use it as a fallback if the main model fails", kind: PropertyKind::Notice, required: false, default: Some("") },
    PropertyDef { name: "useMcpTools", display_name: "Enable Microsoft Work IQ Tools for A365", kind: PropertyKind::Boolean, required: false, default: None },
    PropertyDef { name: "include", display_name: "Tools to Include", kind: PropertyKind::Options, required: false, default: Some("all") },
    PropertyDef { name: "includeTools", display_name: "Tools to Include", kind: PropertyKind::MultiOptions, required: false, default: None },
    PropertyDef { name: "hasOutputParser", display_name: "Require Specific Output Format", kind: PropertyKind::Boolean, required: false, default: None },
    PropertyDef { name: "options", display_name: "Options", kind: PropertyKind::Collection, required: false, default: Some("Hello! I") }
],
    credentials: &[
    CredentialRef { name: "microsoftAgent365Api", required: true }
],
};

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

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

inventory::submit! { NodeFactory::new("microsoftagent365trigger", || Arc::new(Microsoftagent365triggerNode)) }
