Skip to content

Forge API 422 error on task creation - executor config validation #151

@namastex888

Description

@namastex888

Problem

RC32 successfully loads Forge handlers and forge.js module, but Forge API rejects task creation with 422 Unprocessable Entity.

Error Context

▸ Failed to create Forge task: [422] Unprocessable Entity
[DEBUG] execConfig.permissionMode = default
[DEBUG] Added --permission-mode default

Root Cause Analysis Needed

  1. Invalid executor config: "model":"gpt-5-codex" (model doesn't exist)
  2. Invalid permission mode: "default" (might not be valid Forge API value)
  3. Missing required fields in task creation request
  4. Executor profile ID mapping issue

Context

  • RC30: ❌ Wrong routing (commands vs handlers)
  • RC31: ❌ Missing forge.js in npm package
  • RC32: ✅ Both fixed, but Forge API validation fails

Reproduction

export FORGE_BASE_URL=http://localhost:8887
npx -y automagik-genie@next run analyze "Test"

Expected

Forge task created, executor starts

Actual

422 Unprocessable Entity from Forge API

Investigation Checklist

  • Review Forge API schema for task creation
  • Validate executor config against Forge expectations
  • Check executor profile ID mapping
  • Test with minimal valid config
  • Add pre-flight validation before API call

Related

Part of RC30-RC32 autonomous iteration cycle. See /tmp/rc30-rc32-autonomous-cycle-report.md for full context.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions