feat: add n8n APort verification node#111
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8e8b29de47
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const decision = String(getDecisionValue(response)).toLowerCase(); | ||
| return ["allow", "allowed", "approve", "approved", "pass", "passed"].includes( | ||
| decision |
There was a problem hiding this comment.
Route decision-object approvals as approved
When the APort API returns the decision shape used elsewhere in this repo (tools/cli/src/index.js reads result.data?.decision || result.decision and then decision.allow), this code converts the whole { allow: true, ... } object to "[object Object]", so successful verifications are sent to the Denied output. Please handle response.decision.allow === true (and the nested data.decision variant if this node receives the wrapped response) before stringifying the decision value.
Useful? React with 👍 / 👎.
Summary
n8n-nodes-aportcommunity-node package underexamples/agent-frameworks/n8n.APort Verifynode that verifies a passport against a policy pack and routes items to Approved, Denied, or Error outputs.Verification
npm testnpm pack --dry-runpackage.jsonandworkflows/aport-verify-routing.jsonwith Node.js JSON.parseRefs #4 and #31.
Bounty note: this targets the n8n custom node / policy-check scopes in #4 and #31. I am not asking for duplicate payout if the maintainers treat those issues as overlapping. Preferred payout details can be shared privately by @onlyoasis if accepted.