Skip to content

Rename flowID in flow execution to executionId#2213

Merged
ThaminduDilshan merged 1 commit intoasgardeo:mainfrom
NutharaNR:fix/rename-flowid-in-flow-execution
Apr 10, 2026
Merged

Rename flowID in flow execution to executionId#2213
ThaminduDilshan merged 1 commit intoasgardeo:mainfrom
NutharaNR:fix/rename-flowid-in-flow-execution

Conversation

@NutharaNR
Copy link
Copy Markdown
Contributor

@NutharaNR NutharaNR commented Apr 6, 2026

Purpose

The flow execution response structure is confusing due to the use of two different flow IDs: one for the flow definition and one for the runtime flow execution instance.

This improvement rename flowId to executionId in flow execution context.

⚠️ Breaking Changes

🔧 Summary of Breaking Changes

The flowId in the flow execution context has been renamed to executionId. This change is consistently applied across API request and response parameters in flow/execute endpoint, replacing all occurrences of flowId with executionId. To maintain alignment, the method parameters in both FlowExecServiceInterface and flowStoreInterface have also been updated accordingly.

The following models are impacted by this change:

  • NodeContext
  • EngineContext
  • FlowContextDB

💥 Impact

Any call/process goes through flow/execute endpoint or flow execution engine or executors expect the new value executionId to be present.

🔄 Migration Guide

N/A

Approach

N/A

Related Issues

Related PRs

Checklist

  • Followed the contribution guidelines.
  • Manual test round performed and verified.
  • Documentation provided. (Add links if there are any)
    • Ran Vale and fixed all errors and warnings : Vale warning for recognizing executionId as misspelled is ignored.
  • Tests provided. (Add links if there are any)
    • Unit Tests
    • Integration Tests
  • Breaking changes. (Fill if applicable)
    • Breaking changes section filled.
    • breaking change label added.

Security checks

  • Followed secure coding standards in WSO2 Secure Coding Guidelines
  • Confirmed that this PR doesn't commit any keys, passwords, tokens, usernames, or other secrets.

Summary by CodeRabbit

  • New Features

    • The flow identifier is now named executionId (replaces flowId) in API payloads and client/UI flows.
  • Bug Fixes

    • Error messages updated to reference "flow execution ID" for clearer diagnostics.
  • Documentation

    • Docs, examples, samples, and guides updated to use executionId throughout.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 6, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Renames the runtime flow identifier from flowId/FlowID to executionId/ExecutionID across API schemas, backend models, service/store interfaces, logger keys, observability keys, executor code, frontend samples, docs, mocks, and tests.

Changes

Cohort / File(s) Summary
API / OpenAPI / Docs
api/flow-execution.yaml, docs/static/api/next/combined.yaml, ARCHITECTURE.md, README.md, docs/content/.../passkeys.mdx, samples/api/postman/..., tests/e2e/...
OpenAPI schemas, examples and documentation updated: flowIdexecutionId in requests/responses, examples, and redirects/query params.
Flow models, service & store
backend/internal/flow/flowexec/model.go, .../service.go, .../store.go, .../handler.go, .../engine.go, .../error_constants.go, .../flowexec/*_test.go
Model fields/JSON tags and service/store method signatures renamed (FlowIDExecutionID / flowIdexecutionId), error constant renamed, mocks and engine/handler code updated to propagate ExecutionID.
Core NodeContext & engine
backend/internal/flow/core/model.go, backend/internal/flow/core/executor.go, backend/internal/flow/core/prompt_node.go, backend/internal/flow/core/task_execution_node.go, backend/internal/flow/core/..._test.go
NodeContext.FlowIDNodeContext.ExecutionID and logger enrichment switched to LoggerKeyExecutionID; tests updated to set ExecutionID.
Executors + invite link changes
backend/internal/flow/executor/... (e.g., attribute_collector.go, email_executor.go, invite_executor.go, oauth_executor.go, sms_*, passkey_*, provisioning_*, etc.), .../_test.go
Per-execution logging keys switched to use ctx.ExecutionID/LoggerKeyExecutionID; invite link generation query param changed from flowIdexecutionId; extensive test fixtures updated.
Observability & logging constants
backend/internal/system/log/constants.go, backend/internal/system/observability/event/datakeys.go, backend/internal/oauth/oauth2/constants/constants.go
Logger key and observability data key renamed to ExecutionID; OAuth constant FlowIDExecutionID updated.
Integration tests & utilities
tests/integration/..., tests/integration/flow/common/*, tests/integration/testutils/*, tests/integration/testutils/oauth2_utils.go
Integration helpers, models and test utilities updated to accept/send executionId and use ExecutionID in structs and flow-completion calls.
Frontend samples & services
samples/apps/react-vanilla-sample/src/..., frontend/apps/thunder-gate/src/pages/AcceptInvitePage.tsx
Client types, component state, service function params, sessionStorage keys and sample flows updated to use executionId.
Misc / deps
frontend/pnpm-workspace.yaml
Dependency pin bump: @asgardeo/react 0.21.3 → 0.22.0.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related issues

Possibly related PRs

Suggested reviewers

  • senthalan
  • brionmario
  • thiva-k
  • rajithacharith
🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 14.29% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description check ✅ Passed The PR description covers the required sections: Purpose clearly explains the renaming rationale, Breaking Changes section details the impact and affected models, and a Checklist confirms completion of key steps including documentation and breaking changes flagging.
Title check ✅ Passed The PR title states 'Rename flowID in flow execution to executionId', which accurately describes the primary change: renaming the flow execution identifier from flowID to executionId across API schemas, backend models, and tests.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Comment thread api/flow-execution.yaml Outdated
@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch 2 times, most recently from 4d84f3c to c588d9d Compare April 6, 2026 12:31
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 6, 2026

Codecov Report

❌ Patch coverage is 88.88889% with 16 lines in your changes missing coverage. Please review.
✅ Project coverage is 89.52%. Comparing base (426fc29) to head (e77dbe1).
⚠️ Report is 8 commits behind head on main.

Files with missing lines Patch % Lines
backend/internal/flow/flowexec/service.go 60.00% 10 Missing and 6 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2213      +/-   ##
==========================================
- Coverage   89.53%   89.52%   -0.01%     
==========================================
  Files         913      913              
  Lines       60588    60593       +5     
==========================================
+ Hits        54245    54246       +1     
- Misses       4705     4710       +5     
+ Partials     1638     1637       -1     
Flag Coverage Δ
backend-integration-postgres 53.23% <65.97%> (-0.04%) ⬇️
backend-integration-sqlite 53.26% <65.97%> (-0.02%) ⬇️
backend-unit 83.99% <67.36%> (+<0.01%) ⬆️
frontend-apps-console-unit 90.17% <ø> (ø)
frontend-apps-gate-unit 97.35% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch 4 times, most recently from a6d7120 to 9f3d801 Compare April 8, 2026 06:48
@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch 4 times, most recently from 521b148 to 1c7e492 Compare April 9, 2026 08:46
@NutharaNR NutharaNR marked this pull request as ready for review April 9, 2026 10:09
@NutharaNR NutharaNR requested a review from senthalan April 9, 2026 10:17
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 10

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (6)
docs/static/api/next/combined.yaml (1)

1791-1857: ⚠️ Potential issue | 🟠 Major

/flow/execute examples and schemas are out of sync (executionId vs flowId)

The examples now use executionId, but the declared schemas in this same spec still require/property-name flowId (e.g., SubSequentFlowRequest, IncompleteFlowResponse, CompleteFlowResponse, ErrorFlowResponse). This creates an invalid contract for generated clients and validators.

Please apply the rename in the source OpenAPI spec (api/flow-execution.yaml) for both required lists and property names, then regenerate docs/static/api/next/combined.yaml instead of hand-editing this file.

Based on learnings: docs/static/api/next/combined.yaml is auto-generated and contract changes should be made in source OpenAPI files, not via direct edits. As per coding guidelines: /flow/execute must use executionId consistently across both schemas and examples for subsequent request and all 200 response variants.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/static/api/next/combined.yaml` around lines 1791 - 1857, The examples
for POST /flow/execute use executionId but the source schemas still
define/require flowId (SubSequentFlowRequest, IncompleteFlowResponse,
CompleteFlowResponse, ErrorFlowResponse), causing a contract mismatch; to fix,
update the source OpenAPI file api/flow-execution.yaml to rename the flowId
property to executionId (and update any required lists) for the mentioned
schemas and any subsequent-request schemas, then regenerate
docs/static/api/next/combined.yaml (do not hand-edit combined.yaml) so the
examples and schemas are consistent for /flow/execute.
backend/internal/oauth/oauth2/authz/service.go (1)

257-292: ⚠️ Potential issue | 🟠 Major

🔴 Documentation Required: This PR introduces a user-facing change (e.g., new/modified API endpoint, configuration option, authentication flow, or SDK behavior) but does not include corresponding documentation updates under docs/. Please update the relevant documentation before merging.

Line 291 changes the authorization flow/query contract to executionId (replacing flowId). Please document this rename in the API/auth flow docs (at minimum docs/content/apis.mdx and related API examples such as docs/static/api/next/combined.yaml, including /flow/execute request/response examples where the same identifier is exposed).

As per coding guidelines, user-facing API/auth-flow changes in **/*.go must include matching updates under docs/.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/oauth/oauth2/authz/service.go` around lines 257 - 292, The
change replaces the previously exposed flow identifier name (flowId) with
executionID/executionId in the authorization flow and query contract (see usage
of executionID, queryParams[oauth2const.ExecutionID], and any references to flow
execution such as the /flow/execute endpoint); update documentation accordingly
by renaming occurrences of flowId to executionId in API docs (at minimum
docs/content/apis.mdx) and in API spec/examples (e.g.,
docs/static/api/next/combined.yaml and any /flow/execute request/response
examples), ensuring examples, parameter descriptions, and SDK/docs snippets show
the new identifier name and any required request/response shapes that expose it.
backend/internal/flow/flowexec/handler.go (1)

53-80: ⚠️ Potential issue | 🟠 Major

🔴 Documentation Required for /flow/execute identifier rename

This handler now processes and returns executionId (Line 53, Line 68, Line 80), which is a user-facing API contract change. I don’t see corresponding documentation updates in the provided changeset.

🔴 Documentation Required: This PR introduces a user-facing change
(e.g., new/modified API endpoint, configuration option, authentication flow, or SDK behavior)
but does not include corresponding documentation updates under docs/.
Please update the relevant documentation before merging.

Please document the /flow/execute request/response field rename (flowIdexecutionId) in:

  • docs/content/apis.mdx (API contract/reference),
  • relevant flow-execution guide content under docs/content/guides/,
  • and ensure generated docs artifacts (e.g., docs/static/api/next/combined.yaml) are synced.

As per coding guidelines **/*.go: “If ANY user-facing API/auth/config/SDK change is detected and docs updates are missing under docs/, flag this as a major issue.”

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/flow/flowexec/handler.go` around lines 53 - 80, The code
changes rename the public API field from flowId to executionId (see
FlowResponse.ExecutionID, the handler in handler.go and the call to
h.flowExecService.Execute that now uses executionID), so update user-facing
documentation to match: modify the /flow/execute request/response examples and
schema in docs/content/apis.mdx, update any flow-execution guide pages under
docs/content/guides/ to use executionId everywhere (including sample payloads
and SDK examples), and regenerate/sync the generated docs artifact (e.g.,
docs/static/api/next/combined.yaml) so the published API spec reflects the new
executionId field.
backend/internal/flow/flowexec/engine.go (1)

935-942: ⚠️ Potential issue | 🟠 Major

Use one trace identifier consistently for all flow lifecycle events.

publishFlowStartedEvent/publishFlowFailedEvent still use ctx.TraceID, while other flow/node events now use ctx.ExecutionID as the event trace ID. This splits a single flow execution across different trace IDs and weakens correlation.

🔧 Proposed fix
 func publishFlowStartedEvent(ctx *EngineContext, obsSvc observability.ObservabilityServiceInterface) {
@@
 	evt := event.NewEvent(
-		ctx.TraceID, // Use TraceID from context
+		ctx.ExecutionID, // Use ExecutionID as TraceID
 		string(event.EventTypeFlowStarted),
 		event.ComponentFlowEngine,
 	).
@@
 func publishFlowFailedEvent(ctx *EngineContext, svcErr *serviceerror.ServiceError,
 	flowStartTime int64, flowEndTime int64, obsSvc observability.ObservabilityServiceInterface) {
@@
 	evt := event.NewEvent(
-		ctx.TraceID, // Use TraceID from context
+		ctx.ExecutionID, // Use ExecutionID as TraceID
 		string(event.EventTypeFlowFailed),
 		event.ComponentFlowEngine,
 	).

Also applies to: 996-1003

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/flow/flowexec/engine.go` around lines 935 - 942,
publishFlowStartedEvent and publishFlowFailedEvent create events using
ctx.TraceID while other flow/node events use ctx.ExecutionID, splitting a single
flow execution across different trace IDs; update the event construction in
publishFlowStartedEvent and publishFlowFailedEvent (the event.NewEvent(...)
calls) to use ctx.ExecutionID as the event trace identifier instead of
ctx.TraceID so all lifecycle events share the same trace ID, and verify the same
change is applied to the similar block around the other occurrence referenced
(the lines around the second event.NewEvent usage).
api/flow-execution.yaml (2)

216-219: ⚠️ Potential issue | 🟡 Minor

Use COMPLETE in the complete-response schema example.

CompleteFlowResponse.flowStatus still advertises PROMPT_ONLY, while the response example above uses COMPLETE. That leaves generated docs with conflicting contract examples for the same schema.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@api/flow-execution.yaml` around lines 216 - 219, The schema for
CompleteFlowResponse currently sets flowStatus example to "PROMPT_ONLY" which
conflicts with the earlier response example that uses "COMPLETE"; update the
flowStatus example value to "COMPLETE" (or otherwise align both examples) in the
flowStatus property of the CompleteFlowResponse schema so the documented
contract is consistent—look for the flowStatus property definition in the flow
execution schema and change its example string to "COMPLETE".

40-48: ⚠️ Potential issue | 🟠 Major

Document the field the backend actually deserializes.

SubSequentFlowRequest still uses actionId, but the backend request model is FlowRequest.Action with json:"action" in backend/internal/flow/flowexec/model.go, and the integration helper in tests/integration/testutils/oauth2_utils.go posts "action". Clients generated from this spec will send the wrong key and lose the selected action on subsequent /flow/execute calls. Rename the schema/example field to action, or make the backend accept both names.

Also applies to: 164-167

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@api/flow-execution.yaml` around lines 40 - 48, The OpenAPI example uses
"actionId" but the backend deserializes FlowRequest.Action (json:"action")
causing mismatches; update the API spec examples and any SubSequentFlowRequest
schema in api/flow-execution.yaml to use the key "action" (e.g., replace
actionId with action in the subSequentRequestExample and the other occurrence
noted around lines 164-167) so generated clients send "action" like
tests/integration/testutils/oauth2_utils.go and match
backend/internal/flow/flowexec/model.go, or alternatively add support for both
keys in the backend deserialization if you prefer backward compatibility.
🧹 Nitpick comments (11)
tests/integration/oauth/authz/authz_test.go (1)

841-842: Update assertion text to match the renamed field.

Line 842 still says “Expected flow ID” while Line 841 validates ExecutionID. Please align the message to avoid debugging confusion.

Suggested patch
-			if flowStep.ExecutionID == "" {
-				ts.T().Fatalf("Expected flow ID, got empty string")
+			if flowStep.ExecutionID == "" {
+				ts.T().Fatalf("Expected execution ID, got empty string")
 			}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/oauth/authz/authz_test.go` around lines 841 - 842, Update
the test assertion message to reference the renamed field ExecutionID: change
the ts.T().Fatalf message that currently reads "Expected flow ID, got empty
string" to something like "Expected execution ID, got empty string" (or
"Expected ExecutionID, got empty string") so it matches the checked symbol
flowStep.ExecutionID and reduces confusion when ts.T().Fatalf is triggered.
tests/integration/flow/registration/github_registration_test.go (1)

482-482: Use executionID naming in test messages/locals for consistency.

The assertions and locals still use Flow ID/flowID while the field is now ExecutionID. Aligning names will reduce confusion in failures and maintenance.

♻️ Proposed naming cleanup
- ts.Require().NotEmpty(flowStep.ExecutionID, "Flow ID should not be empty")
+ ts.Require().NotEmpty(flowStep.ExecutionID, "Execution ID should not be empty")

- flowID := flowStep.ExecutionID
+ executionID := flowStep.ExecutionID

- completeFlowStep, err := common.CompleteFlow(flowID, inputs, "")
+ completeFlowStep, err := common.CompleteFlow(executionID, inputs, "")

Also applies to: 518-518, 520-520, 585-585, 603-603

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/registration/github_registration_test.go` at line 482,
Assertions and local variables still use "Flow ID"/flowID while the struct field
is ExecutionID; update all test message strings and any local variable names to
use "executionID" (and the camelCase executionID variable) for consistency.
Locate occurrences around the ts.Require().NotEmpty(flowStep.ExecutionID, ...)
and related assertions (e.g., lines referenced where flowStep.ExecutionID is
checked) and replace message text "Flow ID" with "executionID" and rename any
local flowID variables to executionID so test failures and locals match the
flowStep.ExecutionID field.
tests/integration/flow/authentication/multi_action_input_binding_test.go (1)

409-427: Use lowerCamelCase for the local variable at Line 409

ExecutionID is a local variable; in Go it should be executionID for idiomatic unexported naming.

♻️ Suggested rename
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	flowStep, err = common.CompleteFlow(ExecutionID, nil, "action_google")
+	flowStep, err = common.CompleteFlow(executionID, nil, "action_google")
...
-	flowStep, err = common.CompleteFlow(ExecutionID, inputs, "")
+	flowStep, err = common.CompleteFlow(executionID, inputs, "")

Based on learnings: “In asgardeo/thunder Go code, follow Go naming conventions: exported identifiers use CamelCase … and unexported identifiers use lowerCamelCase.”

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/multi_action_input_binding_test.go`
around lines 409 - 427, The local variable ExecutionID is using exported-style
CamelCase; rename it to executionID throughout this test to follow Go unexported
naming conventions—update the declaration (ExecutionID := flowStep.ExecutionID)
and all uses in this snippet and subsequent calls such as
common.CompleteFlow(executionID, ...), ensuring references to ExecutionID,
ExecutionID variable passed into CompleteFlow, and any assertions or helper
calls use executionID consistently.
tests/integration/flow/authentication/sensitive_input_cleanup_test.go (1)

255-255: Update stale assertion message terminology

At Line 255, the assertion still says "Flow ID should not be empty" while the field is now ExecutionID. Consider updating the message to avoid confusion during failures.

✏️ Suggested text fix
-	ts.Require().NotEmpty(flowStep.ExecutionID, "Flow ID should not be empty")
+	ts.Require().NotEmpty(flowStep.ExecutionID, "Execution ID should not be empty")
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/sensitive_input_cleanup_test.go` at
line 255, Update the stale assertion message for the NotEmpty check on
flowStep.ExecutionID: change the message string from "Flow ID should not be
empty" to something referencing ExecutionID (e.g., "ExecutionID should not be
empty") so test failures clearly point to the ExecutionID field; locate the
assertion call ts.Require().NotEmpty(flowStep.ExecutionID, ...) in the
sensitive_input_cleanup_test.go test and replace the message accordingly.
tests/integration/flow/authentication/authz_test.go (1)

355-355: Use “Execution ID” in assertion failure messages.

The checks are correct, but the messages still refer to “Flow ID”.

Also applies to: 399-399, 435-435

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/authz_test.go` at line 355, Update the
test assertion messages to refer to "Execution ID" instead of "Flow ID": change
the failure message passed to ts.Require().NotEmpty for the flowStep.ExecutionID
checks (calls to ts.Require().NotEmpty(flowStep.ExecutionID, ...)) so they read
"Execution ID should not be empty" at each occurrence (the current occurrences
around the tests at the three noted spots).
tests/integration/flow/authentication/basic_auth_test.go (1)

315-315: Update stale assertion messages to “Execution ID”.

These assertions now validate ExecutionID, but the failure text still says “Flow ID”, which is confusing in test failures.

Also applies to: 412-412, 430-430, 479-479, 516-516, 574-574

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/basic_auth_test.go` at line 315, Update
the stale assertion messages that read "Flow ID should not be empty" to
"Execution ID should not be empty" wherever ts.Require().NotEmpty is checking
flowStep.ExecutionID (e.g., the calls using
ts.Require().NotEmpty(flowStep.ExecutionID, ...)); change the message string in
each occurrence (lines around the current one plus the other listed occurrences)
so failures clearly reference "Execution ID".
tests/integration/flow/authentication/google_auth_test.go (2)

335-335: Update stale assertion text to “Execution ID”.

These assertions validate ExecutionID, but the messages still mention “Flow ID”.

Also applies to: 386-386

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/google_auth_test.go` at line 335,
Update the assertion messages that reference the wrong label: change the
descriptive text in the NotEmpty assertions that check flowStep.ExecutionID
(e.g., ts.Require().NotEmpty(flowStep.ExecutionID, "...")) to read "Execution ID
should not be empty" (and similarly update the other occurrence around the
second location) so the message matches the actual field being validated.

388-388: Use lowerCamelCase for local executionID variables.

Lines 388, 433, 451, and 486 declare local variables as ExecutionID, which violates Go naming conventions. Local variables should use lowerCamelCase.

♻️ Proposed fix
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
-	completeFlowStep, err := common.CompleteFlow(ExecutionID, inputs, "")
+	completeFlowStep, err := common.CompleteFlow(executionID, inputs, "")
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/google_auth_test.go` at line 388, The
local variable name `ExecutionID` violates Go's lowerCamelCase convention;
rename the local variable to `executionID` wherever it's declared from
`flowStep.ExecutionID` (the occurrences currently named `ExecutionID` in
google_auth_test.go) and update all subsequent uses in the same scope
(assertions, function calls, etc.) to the new name `executionID` to keep
consistency with Go naming conventions.
tests/integration/flow/authentication/conditional_exec_auth_test.go (2)

383-394: Consider lowercase for local variable naming.

The changes correctly use flowStep.ExecutionID, but the local variable ExecutionID uses PascalCase. Go convention is lowerCamelCase for local variables.

💅 Optional: Use lowerCamelCase for local variable
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
 	redirectURLStr := flowStep.Data.RedirectURL

 	// Step 2: Simulate user authorization at Google
 	authCode, err := testutils.SimulateFederatedOAuthFlow(redirectURLStr)
 	ts.Require().NoError(err, "Failed to simulate Google authorization")

 	// Step 3: Complete the flow with the authorization code
 	inputs := map[string]string{
 		"code": authCode,
 	}
-	flowStep, err = common.CompleteFlow(ExecutionID, inputs, "")
+	flowStep, err = common.CompleteFlow(executionID, inputs, "")
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/conditional_exec_auth_test.go` around
lines 383 - 394, The local variable ExecutionID should be renamed to follow Go's
lowerCamelCase convention (e.g., executionID); update its declaration that
currently assigns flowStep.ExecutionID and all subsequent uses (notably the call
to common.CompleteFlow(ExecutionID, ...)) to use executionID instead so the code
follows Go naming conventions.

428-452: Same naming convention applies to the second test.

💅 Optional: Use lowerCamelCase for local variable
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
 	redirectURLStr := flowStep.Data.RedirectURL
 	...
-	flowStep, err = common.CompleteFlow(ExecutionID, inputs, "")
+	flowStep, err = common.CompleteFlow(executionID, inputs, "")
 	...
-	flowStep, err = common.CompleteFlow(ExecutionID, ouInputs, "")
+	flowStep, err = common.CompleteFlow(executionID, ouInputs, "")
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/conditional_exec_auth_test.go` around
lines 428 - 452, Rename the local variable ExecutionID to lowerCamelCase
executionID throughout this test (and apply the same change in the second test
mentioned) to match the project's naming convention; update all references where
executionID is passed to common.CompleteFlow and any assertions that reference
ExecutionID so the identifier is consistent (e.g., the assignments from
flowStep.ExecutionID, the calls to common.CompleteFlow(ExecutionID, ...) and any
subsequent uses).
backend/internal/flow/flowexec/service.go (1)

338-341: Rename the guard errors to execution ID.

These branches validate executionID, but the returned errors still say flow ID cannot be empty. That makes the rename incomplete in logs and internal error chains.

Also applies to: 364-366, 384-386

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/flow/flowexec/service.go` around lines 338 - 341, The guard
error messages still say "flow ID cannot be empty" even though the parameter is
executionID; update all such validation error strings to "execution ID cannot be
empty" (e.g., in removeContext on s *flowExecService) and any other functions in
the same file that validate executionID (the other two guard branches flagged in
the review). Find the fmt.Errorf calls that return "flow ID cannot be empty" and
change the message text to "execution ID cannot be empty" so logs and error
chains consistently reference execution ID.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@backend/internal/flow/core/model.go`:
- Line 33: The API identifier was renamed from flowId/FlowID to
executionId/ExecutionID and the docs under docs/ need corresponding updates:
search for occurrences of flowId and FlowID and update examples and schema in
docs/static/api/next/combined.yaml (ensure the /flow/execute request/response
examples and schema use executionId) and update docs/content/apis.mdx (or the
specific API reference page) to describe the new executionId field and replace
example payloads accordingly; make sure both request and response examples, any
parameter descriptions, and example JSON bodies reflect ExecutionID/executionId
and preserve the same semantics.

In `@backend/internal/flow/executor/constants.go`:
- Line 103: Update the TODO comment that mentions executionID to fix the typo
and grammar: change "TODO: Check whether executionID need to be added her." to
"TODO: Check whether executionID needs to be added here." — locate the comment
near the executionID mention in constants.go and replace the sentence
accordingly.
- Around line 103-104: Add the execution instance identifier to the
nonUserAttributes filter: update the nonUserAttributes slice to include
"executionId" (camelCase, lowercase 'e') alongside existing entries like
"flowID" so execution identifiers are excluded from user attributes during
provisioning, and update the TODO comment to state that executionId must be
added rather than merely checked; modify the declaration of nonUserAttributes in
constants.go accordingly (refer to the nonUserAttributes variable).

In `@backend/internal/flow/flowexec/error_constants.go`:
- Line 51: Update the stale comment above the ErrorInvalidExecutionID constant
so it references "execution ID" instead of "flow ID"; locate the declaration for
ErrorInvalidExecutionID in this file and change the comment to something like
"ErrorInvalidExecutionID defines the error response for invalid execution ID
errors" so the comment matches the renamed constant and its message.

In `@backend/internal/flow/flowexec/service.go`:
- Around line 80-82: The public request/response field was renamed from flowId
to executionId (see Execute in flowexec/service.go and the /flow/execute
contract), but docs weren't updated; update docs/content/apis.mdx and the
relevant guide under docs/content/guides/ to replace flowId with executionId in
the /flow/execute API spec and examples, add a short migration note advising
clients to rename the request/response field and how to map old flowId to new
executionId, and ensure any sample payloads, OpenAPI snippets, and SDK usage
examples reflect executionId consistently.

In `@backend/internal/oauth/oauth2/authz/handler_test.go`:
- Around line 200-202: The tests and code rename the OAuth authorize/login
correlation query parameter from flowId to executionId (see
oauth2const.ExecutionID used in handler_test.go and the /oauth2/authorize
handling), but the PR lacks user-facing docs updates; update
docs/content/apis.mdx (OAuth authorize behavior) and the relevant guides under
docs/content/guides/ to state that the query param is now executionId (replacing
flowId), include example authorize/login URLs, migration notes for clients, and
adjust any samples or SDK snippets to use oauth2?executionId=<value> so docs
match the code change.

In `@tests/integration/flow/authentication/github_auth_test.go`:
- Line 323: The assertion messages still refer to "Flow ID" while the field is
now ExecutionID; update the NotEmpty assertion message(s) that check
flowStep.ExecutionID (both occurrences including the one around line 323 and the
one around line 371) to say "ExecutionID should not be empty" (or similar) so
the message matches the renamed identifier used in the test (search for
ts.Require().NotEmpty(flowStep.ExecutionID, ...) and replace the second argument
accordingly).

In `@tests/integration/flow/common/utils.go`:
- Around line 143-147: The flow execution API changed: subsequent /flow/execute
requests/responses use executionId instead of flowId; update the docs and
OpenAPI examples to reflect this change. Find the client/test usage in
CompleteFlow where executionId is set and ensure all API reference narrative,
example request/response payloads (incomplete/complete/display-only/error flows)
and any example subsequent requests show executionId consistently; also update
the API changelog entry to mention the change. Ensure example schemas and sample
payloads in the OpenAPI/combined examples are updated so generated docs and SDKs
reflect executionId in both requests and responses.

In `@tests/integration/flow/registration/github_registration_test.go`:
- Line 520: Tests show the public continuation identifier for /flow/execute
changed from flowId to executionId (see flowID := flowStep.ExecutionID in
github_registration_test.go); update the user-facing docs and API spec to
reflect this rename: modify the API guide (apis.mdx) to describe the executionId
field and its semantics, update the combined.yaml API schema and any example
request/response snippets for /flow/execute to use executionId instead of
flowId, and adjust API reference examples that mention flowId so they use
executionId. Ensure examples, request/response schemas, and any SDK snippets are
consistent with the new field name.

In
`@tests/integration/flow/registration/google_registration_with_role_group_test.go`:
- Line 440: The assertion message uses an outdated term "Flow ID" for
flowStep.ExecutionID; update the assertion call (ts.Require().NotEmpty
referencing flowStep.ExecutionID) to use a correct, clear message such as
"Execution ID should not be empty" so the failure text matches the actual field
being tested.

---

Outside diff comments:
In `@api/flow-execution.yaml`:
- Around line 216-219: The schema for CompleteFlowResponse currently sets
flowStatus example to "PROMPT_ONLY" which conflicts with the earlier response
example that uses "COMPLETE"; update the flowStatus example value to "COMPLETE"
(or otherwise align both examples) in the flowStatus property of the
CompleteFlowResponse schema so the documented contract is consistent—look for
the flowStatus property definition in the flow execution schema and change its
example string to "COMPLETE".
- Around line 40-48: The OpenAPI example uses "actionId" but the backend
deserializes FlowRequest.Action (json:"action") causing mismatches; update the
API spec examples and any SubSequentFlowRequest schema in
api/flow-execution.yaml to use the key "action" (e.g., replace actionId with
action in the subSequentRequestExample and the other occurrence noted around
lines 164-167) so generated clients send "action" like
tests/integration/testutils/oauth2_utils.go and match
backend/internal/flow/flowexec/model.go, or alternatively add support for both
keys in the backend deserialization if you prefer backward compatibility.

In `@backend/internal/flow/flowexec/engine.go`:
- Around line 935-942: publishFlowStartedEvent and publishFlowFailedEvent create
events using ctx.TraceID while other flow/node events use ctx.ExecutionID,
splitting a single flow execution across different trace IDs; update the event
construction in publishFlowStartedEvent and publishFlowFailedEvent (the
event.NewEvent(...) calls) to use ctx.ExecutionID as the event trace identifier
instead of ctx.TraceID so all lifecycle events share the same trace ID, and
verify the same change is applied to the similar block around the other
occurrence referenced (the lines around the second event.NewEvent usage).

In `@backend/internal/flow/flowexec/handler.go`:
- Around line 53-80: The code changes rename the public API field from flowId to
executionId (see FlowResponse.ExecutionID, the handler in handler.go and the
call to h.flowExecService.Execute that now uses executionID), so update
user-facing documentation to match: modify the /flow/execute request/response
examples and schema in docs/content/apis.mdx, update any flow-execution guide
pages under docs/content/guides/ to use executionId everywhere (including sample
payloads and SDK examples), and regenerate/sync the generated docs artifact
(e.g., docs/static/api/next/combined.yaml) so the published API spec reflects
the new executionId field.

In `@backend/internal/oauth/oauth2/authz/service.go`:
- Around line 257-292: The change replaces the previously exposed flow
identifier name (flowId) with executionID/executionId in the authorization flow
and query contract (see usage of executionID,
queryParams[oauth2const.ExecutionID], and any references to flow execution such
as the /flow/execute endpoint); update documentation accordingly by renaming
occurrences of flowId to executionId in API docs (at minimum
docs/content/apis.mdx) and in API spec/examples (e.g.,
docs/static/api/next/combined.yaml and any /flow/execute request/response
examples), ensuring examples, parameter descriptions, and SDK/docs snippets show
the new identifier name and any required request/response shapes that expose it.

In `@docs/static/api/next/combined.yaml`:
- Around line 1791-1857: The examples for POST /flow/execute use executionId but
the source schemas still define/require flowId (SubSequentFlowRequest,
IncompleteFlowResponse, CompleteFlowResponse, ErrorFlowResponse), causing a
contract mismatch; to fix, update the source OpenAPI file
api/flow-execution.yaml to rename the flowId property to executionId (and update
any required lists) for the mentioned schemas and any subsequent-request
schemas, then regenerate docs/static/api/next/combined.yaml (do not hand-edit
combined.yaml) so the examples and schemas are consistent for /flow/execute.

---

Nitpick comments:
In `@backend/internal/flow/flowexec/service.go`:
- Around line 338-341: The guard error messages still say "flow ID cannot be
empty" even though the parameter is executionID; update all such validation
error strings to "execution ID cannot be empty" (e.g., in removeContext on s
*flowExecService) and any other functions in the same file that validate
executionID (the other two guard branches flagged in the review). Find the
fmt.Errorf calls that return "flow ID cannot be empty" and change the message
text to "execution ID cannot be empty" so logs and error chains consistently
reference execution ID.

In `@tests/integration/flow/authentication/authz_test.go`:
- Line 355: Update the test assertion messages to refer to "Execution ID"
instead of "Flow ID": change the failure message passed to ts.Require().NotEmpty
for the flowStep.ExecutionID checks (calls to
ts.Require().NotEmpty(flowStep.ExecutionID, ...)) so they read "Execution ID
should not be empty" at each occurrence (the current occurrences around the
tests at the three noted spots).

In `@tests/integration/flow/authentication/basic_auth_test.go`:
- Line 315: Update the stale assertion messages that read "Flow ID should not be
empty" to "Execution ID should not be empty" wherever ts.Require().NotEmpty is
checking flowStep.ExecutionID (e.g., the calls using
ts.Require().NotEmpty(flowStep.ExecutionID, ...)); change the message string in
each occurrence (lines around the current one plus the other listed occurrences)
so failures clearly reference "Execution ID".

In `@tests/integration/flow/authentication/conditional_exec_auth_test.go`:
- Around line 383-394: The local variable ExecutionID should be renamed to
follow Go's lowerCamelCase convention (e.g., executionID); update its
declaration that currently assigns flowStep.ExecutionID and all subsequent uses
(notably the call to common.CompleteFlow(ExecutionID, ...)) to use executionID
instead so the code follows Go naming conventions.
- Around line 428-452: Rename the local variable ExecutionID to lowerCamelCase
executionID throughout this test (and apply the same change in the second test
mentioned) to match the project's naming convention; update all references where
executionID is passed to common.CompleteFlow and any assertions that reference
ExecutionID so the identifier is consistent (e.g., the assignments from
flowStep.ExecutionID, the calls to common.CompleteFlow(ExecutionID, ...) and any
subsequent uses).

In `@tests/integration/flow/authentication/google_auth_test.go`:
- Line 335: Update the assertion messages that reference the wrong label: change
the descriptive text in the NotEmpty assertions that check flowStep.ExecutionID
(e.g., ts.Require().NotEmpty(flowStep.ExecutionID, "...")) to read "Execution ID
should not be empty" (and similarly update the other occurrence around the
second location) so the message matches the actual field being validated.
- Line 388: The local variable name `ExecutionID` violates Go's lowerCamelCase
convention; rename the local variable to `executionID` wherever it's declared
from `flowStep.ExecutionID` (the occurrences currently named `ExecutionID` in
google_auth_test.go) and update all subsequent uses in the same scope
(assertions, function calls, etc.) to the new name `executionID` to keep
consistency with Go naming conventions.

In `@tests/integration/flow/authentication/multi_action_input_binding_test.go`:
- Around line 409-427: The local variable ExecutionID is using exported-style
CamelCase; rename it to executionID throughout this test to follow Go unexported
naming conventions—update the declaration (ExecutionID := flowStep.ExecutionID)
and all uses in this snippet and subsequent calls such as
common.CompleteFlow(executionID, ...), ensuring references to ExecutionID,
ExecutionID variable passed into CompleteFlow, and any assertions or helper
calls use executionID consistently.

In `@tests/integration/flow/authentication/sensitive_input_cleanup_test.go`:
- Line 255: Update the stale assertion message for the NotEmpty check on
flowStep.ExecutionID: change the message string from "Flow ID should not be
empty" to something referencing ExecutionID (e.g., "ExecutionID should not be
empty") so test failures clearly point to the ExecutionID field; locate the
assertion call ts.Require().NotEmpty(flowStep.ExecutionID, ...) in the
sensitive_input_cleanup_test.go test and replace the message accordingly.

In `@tests/integration/flow/registration/github_registration_test.go`:
- Line 482: Assertions and local variables still use "Flow ID"/flowID while the
struct field is ExecutionID; update all test message strings and any local
variable names to use "executionID" (and the camelCase executionID variable) for
consistency. Locate occurrences around the
ts.Require().NotEmpty(flowStep.ExecutionID, ...) and related assertions (e.g.,
lines referenced where flowStep.ExecutionID is checked) and replace message text
"Flow ID" with "executionID" and rename any local flowID variables to
executionID so test failures and locals match the flowStep.ExecutionID field.

In `@tests/integration/oauth/authz/authz_test.go`:
- Around line 841-842: Update the test assertion message to reference the
renamed field ExecutionID: change the ts.T().Fatalf message that currently reads
"Expected flow ID, got empty string" to something like "Expected execution ID,
got empty string" (or "Expected ExecutionID, got empty string") so it matches
the checked symbol flowStep.ExecutionID and reduces confusion when ts.T().Fatalf
is triggered.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 09ad6e5d-1538-4b1e-9bd0-18533027d247

📥 Commits

Reviewing files that changed from the base of the PR and between 0d7360b and 1c7e492.

⛔ Files ignored due to path filters (2)
  • backend/tests/mocks/flow/flowexecmock/FlowExecServiceInterface_mock.go is excluded by !**/*_mock.go
  • backend/tests/mocks/flow/flowexecmock/flowStoreInterface_mock.go is excluded by !**/*_mock.go
📒 Files selected for processing (98)
  • api/flow-execution.yaml
  • backend/internal/flow/core/executor.go
  • backend/internal/flow/core/executor_test.go
  • backend/internal/flow/core/model.go
  • backend/internal/flow/core/node_test.go
  • backend/internal/flow/core/prompt_node.go
  • backend/internal/flow/core/prompt_node_test.go
  • backend/internal/flow/core/representation_node_test.go
  • backend/internal/flow/core/task_execution_node.go
  • backend/internal/flow/core/task_execution_node_test.go
  • backend/internal/flow/executor/attribute_collector.go
  • backend/internal/flow/executor/attribute_collector_test.go
  • backend/internal/flow/executor/attribute_uniqueness_validator.go
  • backend/internal/flow/executor/attribute_uniqueness_validator_test.go
  • backend/internal/flow/executor/auth_assert_executor.go
  • backend/internal/flow/executor/auth_assert_executor_test.go
  • backend/internal/flow/executor/authz_executor.go
  • backend/internal/flow/executor/authz_executor_test.go
  • backend/internal/flow/executor/basic_auth_executor.go
  • backend/internal/flow/executor/basic_auth_executor_test.go
  • backend/internal/flow/executor/consent_executor.go
  • backend/internal/flow/executor/consent_executor_test.go
  • backend/internal/flow/executor/constants.go
  • backend/internal/flow/executor/credential_setter.go
  • backend/internal/flow/executor/credential_setter_test.go
  • backend/internal/flow/executor/email_executor.go
  • backend/internal/flow/executor/email_executor_test.go
  • backend/internal/flow/executor/federated_auth_resolver_executor.go
  • backend/internal/flow/executor/federated_auth_resolver_executor_test.go
  • backend/internal/flow/executor/http_request_executor.go
  • backend/internal/flow/executor/http_request_executor_test.go
  • backend/internal/flow/executor/identifying_executor.go
  • backend/internal/flow/executor/identifying_executor_test.go
  • backend/internal/flow/executor/invite_executor.go
  • backend/internal/flow/executor/invite_executor_test.go
  • backend/internal/flow/executor/oauth_executor.go
  • backend/internal/flow/executor/oauth_executor_test.go
  • backend/internal/flow/executor/oidc_auth_executor.go
  • backend/internal/flow/executor/oidc_auth_executor_test.go
  • backend/internal/flow/executor/ou_executor.go
  • backend/internal/flow/executor/ou_executor_test.go
  • backend/internal/flow/executor/ou_resolver_executor.go
  • backend/internal/flow/executor/ou_resolver_executor_test.go
  • backend/internal/flow/executor/passkey_executor.go
  • backend/internal/flow/executor/passkey_executor_test.go
  • backend/internal/flow/executor/permission_validator.go
  • backend/internal/flow/executor/permission_validator_test.go
  • backend/internal/flow/executor/provisioning_executor.go
  • backend/internal/flow/executor/provisioning_executor_test.go
  • backend/internal/flow/executor/sms_auth_executor.go
  • backend/internal/flow/executor/sms_auth_executor_test.go
  • backend/internal/flow/executor/sms_executor.go
  • backend/internal/flow/executor/sms_executor_test.go
  • backend/internal/flow/executor/user_type_resolver.go
  • backend/internal/flow/executor/user_type_resolver_test.go
  • backend/internal/flow/flowexec/FlowExecServiceInterface_mock_test.go
  • backend/internal/flow/flowexec/engine.go
  • backend/internal/flow/flowexec/engine_event_enabled_test.go
  • backend/internal/flow/flowexec/error_constants.go
  • backend/internal/flow/flowexec/flowStoreInterface_mock_test.go
  • backend/internal/flow/flowexec/handler.go
  • backend/internal/flow/flowexec/model.go
  • backend/internal/flow/flowexec/model_test.go
  • backend/internal/flow/flowexec/service.go
  • backend/internal/flow/flowexec/service_test.go
  • backend/internal/flow/flowexec/store.go
  • backend/internal/flow/flowexec/store_test.go
  • backend/internal/oauth/oauth2/authz/handler_test.go
  • backend/internal/oauth/oauth2/authz/service.go
  • backend/internal/oauth/oauth2/authz/service_test.go
  • backend/internal/oauth/oauth2/constants/constants.go
  • backend/internal/system/log/constants.go
  • backend/internal/system/observability/event/datakeys.go
  • docs/static/api/next/combined.yaml
  • tests/integration/flow/authentication/assurance_test.go
  • tests/integration/flow/authentication/attribute_collect_test.go
  • tests/integration/flow/authentication/authz_test.go
  • tests/integration/flow/authentication/basic_auth_test.go
  • tests/integration/flow/authentication/conditional_exec_auth_test.go
  • tests/integration/flow/authentication/github_auth_test.go
  • tests/integration/flow/authentication/google_auth_test.go
  • tests/integration/flow/authentication/multi_action_input_binding_test.go
  • tests/integration/flow/authentication/prompt_actions_test.go
  • tests/integration/flow/authentication/sensitive_input_cleanup_test.go
  • tests/integration/flow/authentication/sms_auth_test.go
  • tests/integration/flow/authentication/verbose_meta_test.go
  • tests/integration/flow/common/model.go
  • tests/integration/flow/common/utils.go
  • tests/integration/flow/registration/basic_registration_test.go
  • tests/integration/flow/registration/github_registration_test.go
  • tests/integration/flow/registration/google_registration_test.go
  • tests/integration/flow/registration/google_registration_with_role_group_test.go
  • tests/integration/flow/registration/http_request_executor_runtime_data_test.go
  • tests/integration/flow/registration/ou_registration_test.go
  • tests/integration/flow/registration/sms_registration_test.go
  • tests/integration/oauth/authz/authz_test.go
  • tests/integration/testutils/models.go
  • tests/integration/testutils/oauth2_utils.go

Comment thread backend/internal/flow/core/model.go
Comment thread backend/internal/flow/executor/constants.go Outdated
Comment thread backend/internal/flow/executor/constants.go Outdated
Comment thread backend/internal/flow/flowexec/error_constants.go Outdated
Comment thread backend/internal/flow/flowexec/service.go
Comment thread backend/internal/oauth/oauth2/authz/handler_test.go
Comment thread tests/integration/flow/authentication/github_auth_test.go Outdated
Comment thread tests/integration/flow/common/utils.go
Comment thread tests/integration/flow/registration/github_registration_test.go
Comment thread tests/integration/flow/registration/google_registration_with_role_group_test.go Outdated
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (1)
samples/api/postman/authentication/authentication_demo.json (1)

1984-1988: Consider renaming the collection variable too.

The API field is now executionId, but this sample still persists it under exec_flow_id. Renaming the variable and its later consumers would make the collection match the new contract end-to-end.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@samples/api/postman/authentication/authentication_demo.json` around lines
1984 - 1988, The sample persists the API's executionId under the old collection
variable name "exec_flow_id"; update the pm.collectionVariables.set call to use
a matching name (e.g., "executionId") and update all consumers that read this
variable (pm.collectionVariables.get or any references) so the collection
variable key and its usage align with the new API field; search for occurrences
of "exec_flow_id" and replace them with the new variable name while keeping the
value set from jsonResponse.executionId.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@samples/api/postman/authentication/authentication_demo.json`:
- Around line 58-64: The script extracts executionId via
url.searchParams.get("executionId") but doesn't fail if it's missing, so add a
guard after retrieving executionId: if executionId is null/empty, immediately
fail the pre-request/test using Postman's failure helpers (e.g.,
pm.test/pm.expect or pm.fail) and do not call pm.environment.set for
executionId; keep setting authId as before but ensure you log and fail fast when
executionId is absent so subsequent requests don't proceed with a null value.
- Line 2858: The request body in the Postman sample (the "raw" field for the
/flow/execute sample containing "executionId" and "inputs" with
"username"/"password") includes a JavaScript-style comment // "mobileNumber":
... which makes the JSON invalid; remove the inline comment or convert it to a
valid JSON element (either delete the mobileNumber line or add it as a real
key/value) so the "raw" string is valid JSON before sending; update the raw
payload string accordingly in the authentication_demo.json sample.

---

Nitpick comments:
In `@samples/api/postman/authentication/authentication_demo.json`:
- Around line 1984-1988: The sample persists the API's executionId under the old
collection variable name "exec_flow_id"; update the pm.collectionVariables.set
call to use a matching name (e.g., "executionId") and update all consumers that
read this variable (pm.collectionVariables.get or any references) so the
collection variable key and its usage align with the new API field; search for
occurrences of "exec_flow_id" and replace them with the new variable name while
keeping the value set from jsonResponse.executionId.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: ed5000ae-02d4-4053-8ef0-b3af610344e1

📥 Commits

Reviewing files that changed from the base of the PR and between 1c7e492 and f290ab4.

📒 Files selected for processing (8)
  • ARCHITECTURE.md
  • README.md
  • docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx
  • docs/static/api/next/combined.yaml
  • samples/api/postman/authentication/README.md
  • samples/api/postman/authentication/authentication_demo.json
  • samples/api/postman/authentication/environment.json
  • tests/e2e/tests/sample-app-authentication/README-MFA.md
✅ Files skipped from review due to trivial changes (4)
  • samples/api/postman/authentication/environment.json
  • samples/api/postman/authentication/README.md
  • README.md
  • ARCHITECTURE.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • docs/static/api/next/combined.yaml

Comment thread samples/api/postman/authentication/authentication_demo.json
Comment thread samples/api/postman/authentication/authentication_demo.json
@ThaminduDilshan ThaminduDilshan added Type/Improvement breaking change The feature/ improvement will alter the existing behaviour labels Apr 10, 2026
Comment thread backend/internal/flow/executor/constants.go Outdated
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

♻️ Duplicate comments (1)
backend/internal/flow/flowexec/service.go (1)

43-45: ⚠️ Potential issue | 🟠 Major

Documentation still needs to land with this breaking API rename.

Already raised on an earlier revision, but this change still renames the public /flow/execute request/response identifier without the matching contract/guide/sample updates. Please update the source OpenAPI spec and the user-facing guides/samples that carry this field (api/flow-execution.yaml, docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx, and samples/api/postman/authentication/README.md) before merge.

As per coding guidelines, "🔴 Documentation Required: This PR introduces a user-facing change (e.g., new/modified API endpoint, configuration option, authentication flow, or SDK behavior) but does not include corresponding documentation updates under docs/." Based on learnings, docs/static/api/next/combined.yaml is auto-generated from the source OpenAPI files and should not be hand-edited.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/flow/flowexec/service.go` around lines 43 - 45, The public
API field/identifier renamed by the Flow service (see Execute/InitiateFlow
change) must be propagated to the source OpenAPI and user docs: update
api/flow-execution.yaml to use the new request/response identifier names, then
regenerate the combined spec (docs/static/api/next/combined.yaml must NOT be
edited directly); update the user-facing references in
docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx and
the samples/api/postman/authentication/README.md to reflect the new field names
and any example payloads, and run the OpenAPI/spec generation step to verify the
combined.yaml and samples align with the new API contract before merging.
🧹 Nitpick comments (3)
samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx (1)

346-348: Potential stale closure: use data.executionId for consistency.

This line uses the executionId state variable, but processAuthResponse doesn't include executionId in its dependency array (line 377). Since setExecutionId(data.executionId || '') is called just above at line 266, the state variable won't have the updated value yet due to React's async state updates.

In init() (line 453) and initPromptSignupDecision() (line 549), the pattern correctly uses data.executionId directly from the response. Consider using the same pattern here for consistency and correctness.

♻️ Suggested fix
-                submitAuthDecision(executionId, singleAction.ref)
+                submitAuthDecision(data.executionId || '', singleAction.ref)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx` around lines 346 -
348, The call to submitAuthDecision and subsequent processAuthResponse uses the
stale executionId state; instead, read the executionId from the server response
and pass that through: in the promise handler for submitAuthDecision (the then
block receiving result), extract result.data.executionId and pass it to
processAuthResponse (and to any further calls that currently use the executionId
state). Update references around submitAuthDecision(...) and
processAuthResponse(...) so they use result.data.executionId (and keep
singleAction.ref as before) to avoid relying on the async React state update.
samples/apps/react-vanilla-sample/src/services/authService.ts (2)

370-375: JSDoc description is inconsistent with the renamed parameter.

The parameter is renamed to executionId but the description still says "The flow ID". Update for consistency with the rename.

📝 Suggested fix
 /**
  * Submits the user's selected authentication option when multiple options are available.
  * 
- * `@param` {string} executionId - The flow ID received from the initiateNativeAuth response.
+ * `@param` {string} executionId - The execution ID received from the initiateNativeAuth response.
  * `@param` {string} actionId - The ID of the selected authentication action.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@samples/apps/react-vanilla-sample/src/services/authService.ts` around lines
370 - 375, Update the JSDoc for submitAuthDecision so the parameter description
matches the renamed parameter: replace the phrase "The flow ID received from the
initiateNativeAuth response." with a description that references executionId
(e.g., "The execution ID received from the initiateNativeAuth response.") and
ensure the other param docs (actionId, inputs) remain accurate for the
submitAuthDecision function.

410-416: JSDoc description is inconsistent with the renamed parameter.

Same issue as above - the description still refers to "flow ID".

📝 Suggested fix
 /**
  * Submits the native authentication form data to the server.
  * 
- * `@param` {string} executionId - The flow ID received from the initiateNativeAuth response.
+ * `@param` {string} executionId - The execution ID received from the initiateNativeAuth response.
  * `@param` {object} payload - The payload containing the form data or other required information.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@samples/apps/react-vanilla-sample/src/services/authService.ts` around lines
410 - 416, The JSDoc for submitNativeAuth still refers to "flow ID" while the
parameter has been renamed to executionId; update the function comment to
describe executionId consistently (e.g., "executionId - The execution ID
returned from initiateNativeAuth") and make corresponding wording changes in the
param description and `@returns` section if needed so the docs match the
submitNativeAuth(executionId: string, ...) signature.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@backend/internal/flow/flowexec/engine.go`:
- Around line 823-829: Several events are using ctx.TraceID while node events
and publishFlowCompletedEvent use ctx.ExecutionID, causing trace split; update
publishFlowStartedEvent and publishFlowFailedEvent (and the other occurrences
noted around the blocks at 894-900, 935-942, 996-1003) so they set the event
TraceID to ctx.ExecutionID instead of ctx.TraceID. Locate the event construction
calls in publishFlowStartedEvent and publishFlowFailedEvent that pass
ctx.TraceID (and any similar builder calls) and replace them with
ctx.ExecutionID, keeping all other WithStatus/WithData calls unchanged so the
whole flow lifecycle shares the same trace id.

In `@backend/internal/oauth/oauth2/constants/constants.go`:
- Line 89: The change renames the public flow execution identifier to
ExecutionID ("executionId"), which is a user-facing auth/API behavior change;
update documentation to reflect this rename and how clients must pass/propagate
it: add/modify docs/content/apis.mdx to document the /flow/execute API using
"executionId" in requests/responses, update
docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx to
show carrying "executionId" across flow steps with examples and required fields,
and update observability guidance in
docs/content/community/contributing/contributing-code/backend-development/observability.md
to note the new flow correlation key name ("executionId") and any impacts on
logs/metrics/tracing. Ensure references use the constant name ExecutionID when
describing the code-level identifier and include any migration notes for
clients.

In `@tests/integration/oauth/authz/authz_test.go`:
- Around line 841-842: The test assertion message is stale: it checks
flowStep.ExecutionID but the failure text says "flow ID"; update the Fatalf
message in the test (the block checking flowStep.ExecutionID) to reference
"ExecutionID" (e.g., "Expected ExecutionID, got empty string") so failure output
matches the actual field being asserted; locate the assertion that reads
ts.T().Fatalf("Expected flow ID, got empty string") and change the message to
mention ExecutionID.

---

Duplicate comments:
In `@backend/internal/flow/flowexec/service.go`:
- Around line 43-45: The public API field/identifier renamed by the Flow service
(see Execute/InitiateFlow change) must be propagated to the source OpenAPI and
user docs: update api/flow-execution.yaml to use the new request/response
identifier names, then regenerate the combined spec
(docs/static/api/next/combined.yaml must NOT be edited directly); update the
user-facing references in
docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx and
the samples/api/postman/authentication/README.md to reflect the new field names
and any example payloads, and run the OpenAPI/spec generation step to verify the
combined.yaml and samples align with the new API contract before merging.

---

Nitpick comments:
In `@samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx`:
- Around line 346-348: The call to submitAuthDecision and subsequent
processAuthResponse uses the stale executionId state; instead, read the
executionId from the server response and pass that through: in the promise
handler for submitAuthDecision (the then block receiving result), extract
result.data.executionId and pass it to processAuthResponse (and to any further
calls that currently use the executionId state). Update references around
submitAuthDecision(...) and processAuthResponse(...) so they use
result.data.executionId (and keep singleAction.ref as before) to avoid relying
on the async React state update.

In `@samples/apps/react-vanilla-sample/src/services/authService.ts`:
- Around line 370-375: Update the JSDoc for submitAuthDecision so the parameter
description matches the renamed parameter: replace the phrase "The flow ID
received from the initiateNativeAuth response." with a description that
references executionId (e.g., "The execution ID received from the
initiateNativeAuth response.") and ensure the other param docs (actionId,
inputs) remain accurate for the submitAuthDecision function.
- Around line 410-416: The JSDoc for submitNativeAuth still refers to "flow ID"
while the parameter has been renamed to executionId; update the function comment
to describe executionId consistently (e.g., "executionId - The execution ID
returned from initiateNativeAuth") and make corresponding wording changes in the
param description and `@returns` section if needed so the docs match the
submitNativeAuth(executionId: string, ...) signature.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: d1bbe764-c776-4559-b069-2fb0f19a7b20

📥 Commits

Reviewing files that changed from the base of the PR and between f290ab4 and a47c727.

⛔ Files ignored due to path filters (13)
  • backend/tests/mocks/flow/flowexecmock/FlowExecServiceInterface_mock.go is excluded by !**/*_mock.go
  • backend/tests/mocks/flow/flowexecmock/flowStoreInterface_mock.go is excluded by !**/*_mock.go
  • docs/__backup__/README.md is excluded by !docs/__backup__/**
  • docs/__backup__/authentication/server-orchestrated-flow/authentication.md is excluded by !docs/__backup__/**
  • docs/__backup__/authorization/flow-based-authorization.md is excluded by !docs/__backup__/**
  • docs/__backup__/flows/flow-execution.md is excluded by !docs/__backup__/**
  • docs/__backup__/observability/events.md is excluded by !docs/__backup__/**
  • docs/__backup__/registration/server-orchestrated-flow/registration.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/features/public-clients.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/authorization-code.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/client-credentials.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/token-exchange.md is excluded by !docs/__backup__/**
  • frontend/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (112)
  • ARCHITECTURE.md
  • README.md
  • api/flow-execution.yaml
  • backend/internal/flow/core/executor.go
  • backend/internal/flow/core/executor_test.go
  • backend/internal/flow/core/model.go
  • backend/internal/flow/core/node_test.go
  • backend/internal/flow/core/prompt_node.go
  • backend/internal/flow/core/prompt_node_test.go
  • backend/internal/flow/core/representation_node_test.go
  • backend/internal/flow/core/task_execution_node.go
  • backend/internal/flow/core/task_execution_node_test.go
  • backend/internal/flow/executor/attribute_collector.go
  • backend/internal/flow/executor/attribute_collector_test.go
  • backend/internal/flow/executor/attribute_uniqueness_validator.go
  • backend/internal/flow/executor/attribute_uniqueness_validator_test.go
  • backend/internal/flow/executor/auth_assert_executor.go
  • backend/internal/flow/executor/auth_assert_executor_test.go
  • backend/internal/flow/executor/authz_executor.go
  • backend/internal/flow/executor/authz_executor_test.go
  • backend/internal/flow/executor/basic_auth_executor.go
  • backend/internal/flow/executor/basic_auth_executor_test.go
  • backend/internal/flow/executor/consent_executor.go
  • backend/internal/flow/executor/consent_executor_test.go
  • backend/internal/flow/executor/credential_setter.go
  • backend/internal/flow/executor/credential_setter_test.go
  • backend/internal/flow/executor/email_executor.go
  • backend/internal/flow/executor/email_executor_test.go
  • backend/internal/flow/executor/federated_auth_resolver_executor.go
  • backend/internal/flow/executor/federated_auth_resolver_executor_test.go
  • backend/internal/flow/executor/http_request_executor.go
  • backend/internal/flow/executor/http_request_executor_test.go
  • backend/internal/flow/executor/identifying_executor.go
  • backend/internal/flow/executor/identifying_executor_test.go
  • backend/internal/flow/executor/invite_executor.go
  • backend/internal/flow/executor/invite_executor_test.go
  • backend/internal/flow/executor/oauth_executor.go
  • backend/internal/flow/executor/oauth_executor_test.go
  • backend/internal/flow/executor/oidc_auth_executor.go
  • backend/internal/flow/executor/oidc_auth_executor_test.go
  • backend/internal/flow/executor/ou_executor.go
  • backend/internal/flow/executor/ou_executor_test.go
  • backend/internal/flow/executor/ou_resolver_executor.go
  • backend/internal/flow/executor/ou_resolver_executor_test.go
  • backend/internal/flow/executor/passkey_executor.go
  • backend/internal/flow/executor/passkey_executor_test.go
  • backend/internal/flow/executor/permission_validator.go
  • backend/internal/flow/executor/permission_validator_test.go
  • backend/internal/flow/executor/provisioning_executor.go
  • backend/internal/flow/executor/provisioning_executor_test.go
  • backend/internal/flow/executor/sms_auth_executor.go
  • backend/internal/flow/executor/sms_auth_executor_test.go
  • backend/internal/flow/executor/sms_executor.go
  • backend/internal/flow/executor/sms_executor_test.go
  • backend/internal/flow/executor/user_type_resolver.go
  • backend/internal/flow/executor/user_type_resolver_test.go
  • backend/internal/flow/flowexec/FlowExecServiceInterface_mock_test.go
  • backend/internal/flow/flowexec/engine.go
  • backend/internal/flow/flowexec/engine_event_enabled_test.go
  • backend/internal/flow/flowexec/error_constants.go
  • backend/internal/flow/flowexec/flowStoreInterface_mock_test.go
  • backend/internal/flow/flowexec/handler.go
  • backend/internal/flow/flowexec/model.go
  • backend/internal/flow/flowexec/model_test.go
  • backend/internal/flow/flowexec/service.go
  • backend/internal/flow/flowexec/service_test.go
  • backend/internal/flow/flowexec/store.go
  • backend/internal/flow/flowexec/store_test.go
  • backend/internal/oauth/oauth2/authz/handler_test.go
  • backend/internal/oauth/oauth2/authz/service.go
  • backend/internal/oauth/oauth2/authz/service_test.go
  • backend/internal/oauth/oauth2/constants/constants.go
  • backend/internal/system/log/constants.go
  • backend/internal/system/observability/event/datakeys.go
  • docs/content/community/contributing/contributing-code/backend-development/observability.md
  • docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx
  • docs/static/api/next/combined.yaml
  • frontend/apps/thunder-gate/src/pages/AcceptInvitePage.tsx
  • frontend/pnpm-workspace.yaml
  • samples/api/postman/authentication/README.md
  • samples/api/postman/authentication/authentication_demo.json
  • samples/api/postman/authentication/environment.json
  • samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx
  • samples/apps/react-vanilla-sample/src/services/authService.ts
  • tests/e2e/tests/sample-app-authentication/README-MFA.md
  • tests/e2e/utils/thunder-setup/mfa-setup.ts
  • tests/integration/flow/authentication/assurance_test.go
  • tests/integration/flow/authentication/attribute_collect_test.go
  • tests/integration/flow/authentication/authz_test.go
  • tests/integration/flow/authentication/basic_auth_test.go
  • tests/integration/flow/authentication/conditional_exec_auth_test.go
  • tests/integration/flow/authentication/github_auth_test.go
  • tests/integration/flow/authentication/google_auth_test.go
  • tests/integration/flow/authentication/multi_action_input_binding_test.go
  • tests/integration/flow/authentication/prompt_actions_test.go
  • tests/integration/flow/authentication/sensitive_input_cleanup_test.go
  • tests/integration/flow/authentication/sms_auth_test.go
  • tests/integration/flow/authentication/verbose_meta_test.go
  • tests/integration/flow/common/model.go
  • tests/integration/flow/common/utils.go
  • tests/integration/flow/registration/basic_registration_test.go
  • tests/integration/flow/registration/github_registration_test.go
  • tests/integration/flow/registration/google_registration_test.go
  • tests/integration/flow/registration/google_registration_with_role_group_test.go
  • tests/integration/flow/registration/http_request_executor_runtime_data_test.go
  • tests/integration/flow/registration/ou_registration_test.go
  • tests/integration/flow/registration/sms_registration_test.go
  • tests/integration/oauth/authz/authz_test.go
  • tests/integration/oauth/token/refresh_token_test.go
  • tests/integration/oauth/userinfo/userinfo_test.go
  • tests/integration/testutils/models.go
  • tests/integration/testutils/oauth2_utils.go
✅ Files skipped from review due to trivial changes (42)
  • backend/internal/flow/core/prompt_node.go
  • backend/internal/flow/executor/consent_executor.go
  • backend/internal/flow/core/node_test.go
  • backend/internal/flow/executor/ou_resolver_executor.go
  • backend/internal/flow/executor/oidc_auth_executor.go
  • backend/internal/flow/core/task_execution_node.go
  • backend/internal/flow/executor/federated_auth_resolver_executor.go
  • backend/internal/flow/executor/credential_setter.go
  • backend/internal/flow/executor/sms_executor.go
  • docs/content/community/contributing/contributing-code/backend-development/observability.md
  • backend/internal/flow/executor/identifying_executor.go
  • frontend/pnpm-workspace.yaml
  • backend/internal/flow/executor/basic_auth_executor.go
  • backend/internal/flow/executor/attribute_uniqueness_validator_test.go
  • frontend/apps/thunder-gate/src/pages/AcceptInvitePage.tsx
  • backend/internal/flow/executor/ou_executor_test.go
  • backend/internal/flow/executor/email_executor.go
  • README.md
  • backend/internal/flow/executor/provisioning_executor.go
  • backend/internal/flow/executor/sms_executor_test.go
  • backend/internal/flow/executor/user_type_resolver.go
  • samples/api/postman/authentication/environment.json
  • backend/internal/flow/executor/basic_auth_executor_test.go
  • backend/internal/flow/core/task_execution_node_test.go
  • samples/api/postman/authentication/README.md
  • backend/internal/flow/flowexec/engine_event_enabled_test.go
  • tests/e2e/tests/sample-app-authentication/README-MFA.md
  • docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx
  • backend/internal/oauth/oauth2/authz/handler_test.go
  • tests/integration/flow/authentication/conditional_exec_auth_test.go
  • tests/integration/flow/authentication/prompt_actions_test.go
  • tests/integration/flow/registration/google_registration_test.go
  • backend/internal/flow/executor/http_request_executor_test.go
  • tests/integration/flow/authentication/multi_action_input_binding_test.go
  • backend/internal/flow/executor/oidc_auth_executor_test.go
  • tests/integration/flow/authentication/basic_auth_test.go
  • backend/internal/flow/executor/auth_assert_executor_test.go
  • backend/internal/oauth/oauth2/authz/service_test.go
  • backend/internal/flow/executor/user_type_resolver_test.go
  • backend/internal/flow/executor/provisioning_executor_test.go
  • docs/static/api/next/combined.yaml
  • backend/internal/flow/flowexec/flowStoreInterface_mock_test.go
🚧 Files skipped from review as they are similar to previous changes (44)
  • backend/internal/flow/executor/authz_executor.go
  • ARCHITECTURE.md
  • backend/internal/flow/core/model.go
  • backend/internal/flow/executor/permission_validator.go
  • backend/internal/flow/core/executor_test.go
  • backend/internal/flow/executor/passkey_executor.go
  • backend/internal/flow/executor/attribute_uniqueness_validator.go
  • backend/internal/flow/executor/invite_executor_test.go
  • backend/internal/flow/executor/http_request_executor.go
  • backend/internal/flow/executor/permission_validator_test.go
  • backend/internal/flow/executor/identifying_executor_test.go
  • backend/internal/oauth/oauth2/authz/service.go
  • backend/internal/flow/executor/attribute_collector_test.go
  • backend/internal/system/log/constants.go
  • backend/internal/flow/executor/email_executor_test.go
  • backend/internal/flow/executor/ou_resolver_executor_test.go
  • backend/internal/flow/executor/sms_auth_executor_test.go
  • backend/internal/flow/executor/auth_assert_executor.go
  • backend/internal/flow/executor/invite_executor.go
  • tests/integration/flow/registration/google_registration_with_role_group_test.go
  • backend/internal/flow/executor/sms_auth_executor.go
  • backend/internal/flow/flowexec/error_constants.go
  • backend/internal/system/observability/event/datakeys.go
  • tests/integration/flow/authentication/github_auth_test.go
  • tests/integration/flow/registration/http_request_executor_runtime_data_test.go
  • tests/integration/flow/common/model.go
  • backend/internal/flow/flowexec/model_test.go
  • tests/integration/flow/registration/ou_registration_test.go
  • tests/integration/flow/registration/github_registration_test.go
  • backend/internal/flow/flowexec/store_test.go
  • tests/integration/flow/registration/sms_registration_test.go
  • tests/integration/testutils/models.go
  • backend/internal/flow/executor/consent_executor_test.go
  • tests/integration/flow/authentication/attribute_collect_test.go
  • api/flow-execution.yaml
  • backend/internal/flow/core/prompt_node_test.go
  • tests/integration/testutils/oauth2_utils.go
  • backend/internal/flow/flowexec/model.go
  • backend/internal/flow/flowexec/store.go
  • samples/api/postman/authentication/authentication_demo.json
  • backend/internal/flow/executor/oauth_executor.go
  • tests/integration/flow/common/utils.go
  • backend/internal/flow/flowexec/FlowExecServiceInterface_mock_test.go
  • backend/internal/flow/executor/passkey_executor_test.go

Comment thread backend/internal/flow/flowexec/engine.go
Comment thread backend/internal/oauth/oauth2/constants/constants.go
Comment thread tests/integration/oauth/authz/authz_test.go Outdated
@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch from a47c727 to 70de5b8 Compare April 10, 2026 08:49
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

♻️ Duplicate comments (1)
tests/integration/oauth/authz/authz_test.go (1)

841-842: ⚠️ Potential issue | 🟡 Minor

Assertion message is stale for ExecutionID check.

Line 841 validates flowStep.ExecutionID, but Line 842 still says “flow ID”, which can mislead debugging output.

Suggested patch
 if flowStep.ExecutionID == "" {
-	ts.T().Fatalf("Expected flow ID, got empty string")
+	ts.T().Fatalf("Expected execution ID, got empty string")
 }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/oauth/authz/authz_test.go` around lines 841 - 842, Update
the assertion message for the ExecutionID check in the test (the if block that
inspects flowStep.ExecutionID in authz_test.go) so it accurately references
"ExecutionID" instead of the stale "flow ID" wording; modify the Fatalf call
message to say something like "Expected ExecutionID, got empty string" to
improve clarity when the test fails.
🧹 Nitpick comments (5)
backend/internal/flow/executor/passkey_executor_test.go (1)

132-144: LGTM! Change is consistent with the production code rename.

The helper function correctly sets ExecutionID instead of the old FlowID field, aligning with the broader rename in core.NodeContext and the production code in passkey_executor.go that uses ctx.ExecutionID for logging.

Optional nit: The constant testPasskeyFlowID (line 44) could be renamed to testPasskeyExecutionID for naming consistency with the new field name it populates.

,

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/flow/executor/passkey_executor_test.go` around lines 132 -
144, Rename the test constant testPasskeyFlowID to testPasskeyExecutionID and
update all references to it (e.g., in createPasskeyNodeContext) so the constant
name matches the core.NodeContext.ExecutionID field; ensure tests and any uses
in passkey_executor_test.go and other test files are updated to refer to
testPasskeyExecutionID and still populate ExecutionID in core.NodeContext,
keeping runtime behavior unchanged while restoring naming consistency with
passkey_executor.go which logs ctx.ExecutionID.
backend/internal/flow/executor/ou_resolver_executor_test.go (1)

83-84: Optional: reduce repeated execution-id literals in test setup.

The suite repeats "test-flow" / "flow-123" in many contexts. Extracting constants (or a small context builder helper) would reduce rename churn in future refactors.

♻️ Suggested cleanup
+const testExecutionID = "test-flow"
+const promptExecutionID = "flow-123"
...
-    ExecutionID: "test-flow",
+    ExecutionID: testExecutionID,
...
-    ExecutionID: "flow-123",
+    ExecutionID: promptExecutionID,

Also applies to: 110-111, 133-133, 152-153, 170-170, 189-189, 213-214, 229-230, 247-247, 270-270, 298-298, 326-326, 359-359, 391-391, 415-415, 443-443, 473-473, 497-497, 522-522, 547-547, 575-575

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/flow/executor/ou_resolver_executor_test.go` around lines 83
- 84, Extract repeated execution-id literals into shared test constants and
optionally a small builder: define consts like testExecutionID = "test-flow" and
testFlowID = "flow-123" at top of
backend/internal/flow/executor/ou_resolver_executor_test.go (or in a test
helper), then replace inline literals used in ExecutionID fields and any places
using "flow-123" with those constants; alternatively provide a small helper
(e.g., newTestExecutionContext(httpCtx, testExecutionID)) to construct the
Context/Execution objects used across tests to remove duplication. Ensure
references to ExecutionID and httpCtx in existing test cases are updated to use
the new constants/helper so renames are centralized.
backend/internal/flow/flowexec/model_test.go (1)

603-626: Pre-existing inconsistency: AppID set to "test-flow-id" instead of "test-app-id".

Line 604 (unchanged in this PR) sets AppID: "test-flow-id", which appears inconsistent with other tests that use "test-app-id" for the AppID field. This doesn't cause test failures since AppID isn't asserted in this test, but it reduces test clarity.

The ExecutionID rename at lines 617-618 and assertion at line 626 are correct.

Would you like me to open an issue to track fixing the AppID value for consistency across tests?

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/flow/flowexec/model_test.go` around lines 603 - 626, The
test creates a flowContextContent with AppID set to "test-flow-id" which is
inconsistent with other tests; update the AppID value to "test-app-id" in the
flowContextContent initialization in model_test.go so the constructed
FlowContextDB.Context JSON uses the expected app identifier; this change is
local to the test that calls FlowContextDB.ToEngineContext and verifies
resultCtx.ExecutionID, so adjust the AppID field there (flowContextContent ->
AppID) to "test-app-id" for consistency.
tests/integration/flow/authentication/github_auth_test.go (1)

373-373: Prefer executionID (lowerCamelCase) for local vars.

Line 373, Line 418, and Line 436 use ExecutionID as a local variable. Please rename to executionID to follow Go naming style for unexported identifiers.

♻️ Suggested patch
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	completeFlowStep, err := common.CompleteFlow(ExecutionID, inputs, "")
+	completeFlowStep, err := common.CompleteFlow(executionID, inputs, "")
...
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	_, err = common.CompleteFlow(ExecutionID, inputs, "")
+	_, err = common.CompleteFlow(executionID, inputs, "")
...
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	flowStep, err = common.CompleteFlow(ExecutionID, inputs, "")
+	flowStep, err = common.CompleteFlow(executionID, inputs, "")

Based on learnings: In asgardeo/thunder Go code, unexported identifiers should use lowerCamelCase, while exported identifiers use CamelCase.

Also applies to: 389-389, 418-418, 425-425, 436-436, 443-443

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/github_auth_test.go` at line 373,
Rename the local variable(s) currently named ExecutionID to executionID to
follow Go's lowerCamelCase convention for unexported identifiers; specifically
update the assignments like "ExecutionID := flowStep.ExecutionID" (and the other
occurrences where a local variable is assigned from flowStep.ExecutionID) to
"executionID := flowStep.ExecutionID" and adjust any subsequent references in
the same test functions so they use executionID instead of ExecutionID.
tests/integration/flow/authentication/conditional_exec_auth_test.go (1)

383-383: Use lowerCamelCase for local executionID variables.

Line 383 and Line 428 introduce ExecutionID as a local variable. For unexported/local identifiers, use lowerCamelCase (executionID) for Go style consistency.

♻️ Suggested patch
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	flowStep, err = common.CompleteFlow(ExecutionID, inputs, "")
+	flowStep, err = common.CompleteFlow(executionID, inputs, "")
...
-	ExecutionID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	flowStep, err = common.CompleteFlow(ExecutionID, inputs, "")
+	flowStep, err = common.CompleteFlow(executionID, inputs, "")
...
-	flowStep, err = common.CompleteFlow(ExecutionID, ouInputs, "")
+	flowStep, err = common.CompleteFlow(executionID, ouInputs, "")

Based on learnings: In asgardeo/thunder Go code, unexported identifiers should use lowerCamelCase, while exported identifiers use CamelCase.

Also applies to: 394-394, 428-428, 441-441, 452-452

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/conditional_exec_auth_test.go` at line
383, Local variables named "ExecutionID" are using exported-style CamelCase;
rename them to lowerCamelCase "executionID" wherever declared and used (e.g.,
the local assignment from flowStep.ExecutionID and subsequent uses around the
affected blocks) to follow Go style for unexported identifiers—update the
declarations and all references in the same functions/blocks (including the
other occurrences noted at lines 394, 428, 441, 452) so the code compiles and
behavior remains identical.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@backend/internal/flow/flowexec/handler.go`:
- Around line 53-68: Update the public API docs to reflect the request/response
field rename from "flowId"/"flow_id" to "executionId"/"execution_id" for the
/flow/execute endpoint: update docs/content/apis.mdx (the /flow/execute
contract) and any guides under docs/content/guides/ that mention flow execution,
include example request and response JSON showing the new ExecutionID field
(matching the server-side FlowResponse usage of ExecutionID), add a clear
migration note for existing clients describing the rename and how to map old
fields to the new executionId, and ensure any SDK or sample snippets in docs are
updated to use executionId consistently.

In `@samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx`:
- Around line 266-267: In processAuthResponse, avoid using the state variable
executionId for immediate chained single-action submission because
setExecutionId is async and the closure may hold a stale value; instead capture
data.executionId into a local const (e.g., const responseExecutionId =
data.executionId || '') before calling setExecutionId(responseExecutionId), and
then pass responseExecutionId to submitAuthDecision(responseExecutionId,
singleAction.ref) so the immediate auto-step uses the fresh response value
rather than the possibly stale executionId from state.

---

Duplicate comments:
In `@tests/integration/oauth/authz/authz_test.go`:
- Around line 841-842: Update the assertion message for the ExecutionID check in
the test (the if block that inspects flowStep.ExecutionID in authz_test.go) so
it accurately references "ExecutionID" instead of the stale "flow ID" wording;
modify the Fatalf call message to say something like "Expected ExecutionID, got
empty string" to improve clarity when the test fails.

---

Nitpick comments:
In `@backend/internal/flow/executor/ou_resolver_executor_test.go`:
- Around line 83-84: Extract repeated execution-id literals into shared test
constants and optionally a small builder: define consts like testExecutionID =
"test-flow" and testFlowID = "flow-123" at top of
backend/internal/flow/executor/ou_resolver_executor_test.go (or in a test
helper), then replace inline literals used in ExecutionID fields and any places
using "flow-123" with those constants; alternatively provide a small helper
(e.g., newTestExecutionContext(httpCtx, testExecutionID)) to construct the
Context/Execution objects used across tests to remove duplication. Ensure
references to ExecutionID and httpCtx in existing test cases are updated to use
the new constants/helper so renames are centralized.

In `@backend/internal/flow/executor/passkey_executor_test.go`:
- Around line 132-144: Rename the test constant testPasskeyFlowID to
testPasskeyExecutionID and update all references to it (e.g., in
createPasskeyNodeContext) so the constant name matches the
core.NodeContext.ExecutionID field; ensure tests and any uses in
passkey_executor_test.go and other test files are updated to refer to
testPasskeyExecutionID and still populate ExecutionID in core.NodeContext,
keeping runtime behavior unchanged while restoring naming consistency with
passkey_executor.go which logs ctx.ExecutionID.

In `@backend/internal/flow/flowexec/model_test.go`:
- Around line 603-626: The test creates a flowContextContent with AppID set to
"test-flow-id" which is inconsistent with other tests; update the AppID value to
"test-app-id" in the flowContextContent initialization in model_test.go so the
constructed FlowContextDB.Context JSON uses the expected app identifier; this
change is local to the test that calls FlowContextDB.ToEngineContext and
verifies resultCtx.ExecutionID, so adjust the AppID field there
(flowContextContent -> AppID) to "test-app-id" for consistency.

In `@tests/integration/flow/authentication/conditional_exec_auth_test.go`:
- Line 383: Local variables named "ExecutionID" are using exported-style
CamelCase; rename them to lowerCamelCase "executionID" wherever declared and
used (e.g., the local assignment from flowStep.ExecutionID and subsequent uses
around the affected blocks) to follow Go style for unexported identifiers—update
the declarations and all references in the same functions/blocks (including the
other occurrences noted at lines 394, 428, 441, 452) so the code compiles and
behavior remains identical.

In `@tests/integration/flow/authentication/github_auth_test.go`:
- Line 373: Rename the local variable(s) currently named ExecutionID to
executionID to follow Go's lowerCamelCase convention for unexported identifiers;
specifically update the assignments like "ExecutionID := flowStep.ExecutionID"
(and the other occurrences where a local variable is assigned from
flowStep.ExecutionID) to "executionID := flowStep.ExecutionID" and adjust any
subsequent references in the same test functions so they use executionID instead
of ExecutionID.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 68314775-8dac-4d2e-8376-41ee7dad318a

📥 Commits

Reviewing files that changed from the base of the PR and between a47c727 and 70de5b8.

⛔ Files ignored due to path filters (13)
  • backend/tests/mocks/flow/flowexecmock/FlowExecServiceInterface_mock.go is excluded by !**/*_mock.go
  • backend/tests/mocks/flow/flowexecmock/flowStoreInterface_mock.go is excluded by !**/*_mock.go
  • docs/__backup__/README.md is excluded by !docs/__backup__/**
  • docs/__backup__/authentication/server-orchestrated-flow/authentication.md is excluded by !docs/__backup__/**
  • docs/__backup__/authorization/flow-based-authorization.md is excluded by !docs/__backup__/**
  • docs/__backup__/flows/flow-execution.md is excluded by !docs/__backup__/**
  • docs/__backup__/observability/events.md is excluded by !docs/__backup__/**
  • docs/__backup__/registration/server-orchestrated-flow/registration.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/features/public-clients.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/authorization-code.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/client-credentials.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/token-exchange.md is excluded by !docs/__backup__/**
  • frontend/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (112)
  • ARCHITECTURE.md
  • README.md
  • api/flow-execution.yaml
  • backend/internal/flow/core/executor.go
  • backend/internal/flow/core/executor_test.go
  • backend/internal/flow/core/model.go
  • backend/internal/flow/core/node_test.go
  • backend/internal/flow/core/prompt_node.go
  • backend/internal/flow/core/prompt_node_test.go
  • backend/internal/flow/core/representation_node_test.go
  • backend/internal/flow/core/task_execution_node.go
  • backend/internal/flow/core/task_execution_node_test.go
  • backend/internal/flow/executor/attribute_collector.go
  • backend/internal/flow/executor/attribute_collector_test.go
  • backend/internal/flow/executor/attribute_uniqueness_validator.go
  • backend/internal/flow/executor/attribute_uniqueness_validator_test.go
  • backend/internal/flow/executor/auth_assert_executor.go
  • backend/internal/flow/executor/auth_assert_executor_test.go
  • backend/internal/flow/executor/authz_executor.go
  • backend/internal/flow/executor/authz_executor_test.go
  • backend/internal/flow/executor/basic_auth_executor.go
  • backend/internal/flow/executor/basic_auth_executor_test.go
  • backend/internal/flow/executor/consent_executor.go
  • backend/internal/flow/executor/consent_executor_test.go
  • backend/internal/flow/executor/credential_setter.go
  • backend/internal/flow/executor/credential_setter_test.go
  • backend/internal/flow/executor/email_executor.go
  • backend/internal/flow/executor/email_executor_test.go
  • backend/internal/flow/executor/federated_auth_resolver_executor.go
  • backend/internal/flow/executor/federated_auth_resolver_executor_test.go
  • backend/internal/flow/executor/http_request_executor.go
  • backend/internal/flow/executor/http_request_executor_test.go
  • backend/internal/flow/executor/identifying_executor.go
  • backend/internal/flow/executor/identifying_executor_test.go
  • backend/internal/flow/executor/invite_executor.go
  • backend/internal/flow/executor/invite_executor_test.go
  • backend/internal/flow/executor/oauth_executor.go
  • backend/internal/flow/executor/oauth_executor_test.go
  • backend/internal/flow/executor/oidc_auth_executor.go
  • backend/internal/flow/executor/oidc_auth_executor_test.go
  • backend/internal/flow/executor/ou_executor.go
  • backend/internal/flow/executor/ou_executor_test.go
  • backend/internal/flow/executor/ou_resolver_executor.go
  • backend/internal/flow/executor/ou_resolver_executor_test.go
  • backend/internal/flow/executor/passkey_executor.go
  • backend/internal/flow/executor/passkey_executor_test.go
  • backend/internal/flow/executor/permission_validator.go
  • backend/internal/flow/executor/permission_validator_test.go
  • backend/internal/flow/executor/provisioning_executor.go
  • backend/internal/flow/executor/provisioning_executor_test.go
  • backend/internal/flow/executor/sms_auth_executor.go
  • backend/internal/flow/executor/sms_auth_executor_test.go
  • backend/internal/flow/executor/sms_executor.go
  • backend/internal/flow/executor/sms_executor_test.go
  • backend/internal/flow/executor/user_type_resolver.go
  • backend/internal/flow/executor/user_type_resolver_test.go
  • backend/internal/flow/flowexec/FlowExecServiceInterface_mock_test.go
  • backend/internal/flow/flowexec/engine.go
  • backend/internal/flow/flowexec/engine_event_enabled_test.go
  • backend/internal/flow/flowexec/error_constants.go
  • backend/internal/flow/flowexec/flowStoreInterface_mock_test.go
  • backend/internal/flow/flowexec/handler.go
  • backend/internal/flow/flowexec/model.go
  • backend/internal/flow/flowexec/model_test.go
  • backend/internal/flow/flowexec/service.go
  • backend/internal/flow/flowexec/service_test.go
  • backend/internal/flow/flowexec/store.go
  • backend/internal/flow/flowexec/store_test.go
  • backend/internal/oauth/oauth2/authz/handler_test.go
  • backend/internal/oauth/oauth2/authz/service.go
  • backend/internal/oauth/oauth2/authz/service_test.go
  • backend/internal/oauth/oauth2/constants/constants.go
  • backend/internal/system/log/constants.go
  • backend/internal/system/observability/event/datakeys.go
  • docs/content/community/contributing/contributing-code/backend-development/observability.md
  • docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx
  • docs/static/api/next/combined.yaml
  • frontend/apps/thunder-gate/src/pages/AcceptInvitePage.tsx
  • frontend/pnpm-workspace.yaml
  • samples/api/postman/authentication/README.md
  • samples/api/postman/authentication/authentication_demo.json
  • samples/api/postman/authentication/environment.json
  • samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx
  • samples/apps/react-vanilla-sample/src/services/authService.ts
  • tests/e2e/tests/sample-app-authentication/README-MFA.md
  • tests/e2e/utils/thunder-setup/mfa-setup.ts
  • tests/integration/flow/authentication/assurance_test.go
  • tests/integration/flow/authentication/attribute_collect_test.go
  • tests/integration/flow/authentication/authz_test.go
  • tests/integration/flow/authentication/basic_auth_test.go
  • tests/integration/flow/authentication/conditional_exec_auth_test.go
  • tests/integration/flow/authentication/github_auth_test.go
  • tests/integration/flow/authentication/google_auth_test.go
  • tests/integration/flow/authentication/multi_action_input_binding_test.go
  • tests/integration/flow/authentication/prompt_actions_test.go
  • tests/integration/flow/authentication/sensitive_input_cleanup_test.go
  • tests/integration/flow/authentication/sms_auth_test.go
  • tests/integration/flow/authentication/verbose_meta_test.go
  • tests/integration/flow/common/model.go
  • tests/integration/flow/common/utils.go
  • tests/integration/flow/registration/basic_registration_test.go
  • tests/integration/flow/registration/github_registration_test.go
  • tests/integration/flow/registration/google_registration_test.go
  • tests/integration/flow/registration/google_registration_with_role_group_test.go
  • tests/integration/flow/registration/http_request_executor_runtime_data_test.go
  • tests/integration/flow/registration/ou_registration_test.go
  • tests/integration/flow/registration/sms_registration_test.go
  • tests/integration/oauth/authz/authz_test.go
  • tests/integration/oauth/token/refresh_token_test.go
  • tests/integration/oauth/userinfo/userinfo_test.go
  • tests/integration/testutils/models.go
  • tests/integration/testutils/oauth2_utils.go
✅ Files skipped from review due to trivial changes (42)
  • backend/internal/flow/core/task_execution_node.go
  • ARCHITECTURE.md
  • backend/internal/flow/executor/credential_setter.go
  • backend/internal/flow/executor/oidc_auth_executor.go
  • frontend/apps/thunder-gate/src/pages/AcceptInvitePage.tsx
  • samples/api/postman/authentication/environment.json
  • frontend/pnpm-workspace.yaml
  • backend/internal/flow/core/executor.go
  • backend/internal/flow/core/prompt_node.go
  • backend/internal/flow/executor/attribute_collector.go
  • backend/internal/flow/executor/attribute_uniqueness_validator.go
  • backend/internal/flow/executor/attribute_uniqueness_validator_test.go
  • backend/internal/flow/executor/auth_assert_executor.go
  • backend/internal/flow/executor/consent_executor.go
  • backend/internal/flow/executor/federated_auth_resolver_executor_test.go
  • backend/internal/flow/executor/http_request_executor.go
  • backend/internal/flow/executor/identifying_executor.go
  • backend/internal/flow/executor/ou_executor_test.go
  • backend/internal/flow/executor/provisioning_executor.go
  • tests/e2e/utils/thunder-setup/mfa-setup.ts
  • backend/internal/flow/executor/authz_executor_test.go
  • backend/internal/flow/executor/basic_auth_executor_test.go
  • backend/internal/flow/executor/email_executor_test.go
  • backend/internal/flow/executor/oauth_executor.go
  • backend/internal/flow/flowexec/engine_event_enabled_test.go
  • docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx
  • tests/integration/flow/authentication/multi_action_input_binding_test.go
  • tests/e2e/tests/sample-app-authentication/README-MFA.md
  • backend/internal/flow/executor/http_request_executor_test.go
  • backend/internal/flow/executor/identifying_executor_test.go
  • tests/integration/flow/authentication/sms_auth_test.go
  • backend/internal/flow/core/prompt_node_test.go
  • backend/internal/flow/executor/provisioning_executor_test.go
  • backend/internal/flow/executor/auth_assert_executor_test.go
  • docs/content/community/contributing/contributing-code/backend-development/observability.md
  • tests/integration/flow/common/model.go
  • tests/integration/flow/authentication/verbose_meta_test.go
  • backend/internal/flow/executor/authz_executor.go
  • tests/integration/oauth/userinfo/userinfo_test.go
  • tests/integration/flow/registration/google_registration_test.go
  • backend/internal/flow/executor/user_type_resolver_test.go
  • samples/api/postman/authentication/authentication_demo.json
🚧 Files skipped from review as they are similar to previous changes (52)
  • backend/internal/flow/core/node_test.go
  • README.md
  • backend/internal/flow/core/executor_test.go
  • backend/internal/flow/executor/email_executor.go
  • backend/internal/flow/executor/federated_auth_resolver_executor.go
  • backend/internal/flow/executor/ou_resolver_executor.go
  • backend/internal/flow/executor/permission_validator.go
  • backend/internal/flow/executor/ou_executor.go
  • backend/internal/flow/core/model.go
  • backend/internal/flow/executor/basic_auth_executor.go
  • backend/internal/flow/executor/invite_executor_test.go
  • backend/internal/flow/executor/passkey_executor.go
  • backend/internal/flow/executor/permission_validator_test.go
  • backend/internal/flow/executor/sms_auth_executor.go
  • backend/internal/flow/executor/sms_executor.go
  • backend/internal/flow/flowexec/engine.go
  • backend/internal/system/log/constants.go
  • backend/internal/oauth/oauth2/authz/service.go
  • samples/api/postman/authentication/README.md
  • backend/internal/flow/executor/sms_executor_test.go
  • tests/integration/flow/authentication/google_auth_test.go
  • tests/integration/flow/authentication/sensitive_input_cleanup_test.go
  • backend/internal/flow/executor/consent_executor_test.go
  • backend/internal/flow/executor/invite_executor.go
  • backend/internal/oauth/oauth2/constants/constants.go
  • backend/internal/flow/executor/user_type_resolver.go
  • backend/internal/oauth/oauth2/authz/service_test.go
  • backend/internal/flow/core/task_execution_node_test.go
  • backend/internal/flow/flowexec/store_test.go
  • tests/integration/flow/authentication/assurance_test.go
  • tests/integration/flow/authentication/attribute_collect_test.go
  • backend/internal/system/observability/event/datakeys.go
  • tests/integration/flow/authentication/authz_test.go
  • tests/integration/flow/authentication/prompt_actions_test.go
  • tests/integration/flow/authentication/basic_auth_test.go
  • api/flow-execution.yaml
  • backend/internal/flow/executor/oauth_executor_test.go
  • backend/internal/flow/executor/attribute_collector_test.go
  • backend/internal/flow/flowexec/model.go
  • tests/integration/flow/registration/ou_registration_test.go
  • tests/integration/flow/registration/sms_registration_test.go
  • tests/integration/flow/registration/github_registration_test.go
  • samples/apps/react-vanilla-sample/src/services/authService.ts
  • tests/integration/testutils/oauth2_utils.go
  • backend/internal/flow/executor/oidc_auth_executor_test.go
  • backend/internal/flow/executor/sms_auth_executor_test.go
  • backend/internal/flow/flowexec/FlowExecServiceInterface_mock_test.go
  • tests/integration/flow/common/utils.go
  • backend/internal/flow/flowexec/store.go
  • backend/internal/flow/flowexec/service.go
  • docs/static/api/next/combined.yaml
  • backend/internal/oauth/oauth2/authz/handler_test.go

Comment thread backend/internal/flow/flowexec/handler.go
Comment thread samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx
@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch from 70de5b8 to 7c34718 Compare April 10, 2026 09:15
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
tests/e2e/tests/sample-app-authentication/README-MFA.md (1)

136-136: ⚠️ Potential issue | 🟡 Minor

Fix heading capitalization to satisfy Vale title-case lint.

The headings at Line 136 and Line 515 violate WSO2-IAM.TitleCaseTitles.

💡 Suggested fix
-### Create the notification sender
+### Create the Notification Sender

-### Create a user with mobile No
+### Create a User with Mobile Number

Also applies to: 515-515

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/e2e/tests/sample-app-authentication/README-MFA.md` at line 136, Change
the heading "Create the notification sender" (and the other identical heading at
the second occurrence) to Title Case to satisfy the WSO2-IAM.TitleCaseTitles
lint rule; replace the lowercase words so the headings read "Create the
Notification Sender" in both places (update the heading text in the
README-MFA.md where the markdown heading text "Create the notification sender"
appears).
tests/integration/flow/registration/google_registration_with_role_group_test.go (1)

440-452: ⚠️ Potential issue | 🟠 Major

Public flow-execution identifier rename needs docs coverage.

🔴 Documentation Required: This PR introduces a user-facing change (e.g., new/modified API endpoint, configuration option, authentication flow, or SDK behavior) but does not include corresponding documentation updates under docs/. Please update the relevant documentation before merging.

Specifically, the /flow/execute contract shift to executionId (validated at Line 440 and used at Line 452) should be documented in docs/content/apis.mdx and a flow-execution guide under docs/content/guides/ with migration examples from flowId to executionId.

As per coding guidelines "If ANY of the above are detected and the PR does NOT include corresponding updates under docs/ ... flag this as a major issue ..."

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@tests/integration/flow/registration/google_registration_with_role_group_test.go`
around lines 440 - 452, The tests reveal a public contract change: the
/flow/execute parameter was renamed from flowId to executionId (referenced in
the test via flowStep.ExecutionID and the call to common.CompleteFlow), so add
documentation updates: modify docs/content/apis.mdx to describe the new
/flow/execute request/response schema using executionId, and create or update a
guide under docs/content/guides/ showing the migration steps (example requests
and responses) converting old flowId usages to executionId; ensure the docs
include the validation behavior and an example mirroring the test flow that
builds redirectURLStr and completes the flow with inputs {"code": "..."} so
consumers can migrate safely.
♻️ Duplicate comments (3)
backend/internal/oauth/oauth2/authz/handler_test.go (1)

200-202: ⚠️ Potential issue | 🟠 Major

Documentation update is still required for the authorize/login query param rename.

Line 202 confirms the OAuth authorize/login correlation parameter moved to executionId (from flowId), which is a user-facing auth flow contract change.
🔴 Documentation Required: This PR introduces a user-facing change
(e.g., new/modified API endpoint, configuration option, authentication flow, or SDK behavior)
but does not include corresponding documentation updates under docs/.
Please update the relevant documentation before merging.

Please document this rename in docs/content/apis.mdx (OAuth authorize behavior) and the related authorization/login guide under docs/content/guides/, including migration notes and updated URL examples.

As per coding guidelines: "If ANY of the above are detected and the PR does NOT include corresponding updates under docs/, flag this as a major issue."

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@backend/internal/oauth/oauth2/authz/handler_test.go` around lines 200 - 202,
The test shows the OAuth correlation query param was renamed from flowId to
executionId (see oauth2const.ExecutionID and references to flowId), but docs
were not updated; update docs/content/apis.mdx (OAuth authorize behavior) and
the relevant guide(s) under docs/content/guides/ to document the rename, include
migration notes, updated example authorize/login URLs showing executionId
instead of flowId, and mention the change in any SDK or config examples that
reference flowId so callers know to use executionId.
samples/api/postman/authentication/authentication_demo.json (2)

58-64: ⚠️ Potential issue | 🟡 Minor

Fail fast if redirect is missing executionId before persisting variables.

If executionId is absent, the collection proceeds and fails later in /flow/execute, which makes diagnosis harder.

Suggested guard
 "    const executionId = url.searchParams.get(\"executionId\");",
+"    pm.test(\"Redirect includes executionId\", function() {",
+"        pm.expect(executionId).to.be.a(\"string\").and.not.empty;",
+"    });",
 "    ",
 "    pm.environment.set(\"authId\", authId);",
-"    pm.environment.set(\"executionId\", executionId);",
+"    if (executionId) {",
+"        pm.environment.set(\"executionId\", executionId);",
+"    }",
 "    const executionId = url.searchParams.get(\"executionId\");",
+"    pm.test(\"Redirect includes executionId\", function() {",
+"        pm.expect(executionId).to.be.a(\"string\").and.not.empty;",
+"    });",
 "    ",
 "    pm.collectionVariables.set(\"auth_std_auth_id\", authId);",
-"    pm.collectionVariables.set(\"auth_std_flow_id\", executionId);",
+"    if (executionId) {",
+"        pm.collectionVariables.set(\"auth_std_flow_id\", executionId);",
+"    }",

Also applies to: 3401-3407

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@samples/api/postman/authentication/authentication_demo.json` around lines 58
- 64, Add a guard to fail fast when the redirect URL is missing executionId:
check the result of url.searchParams.get("executionId") (the executionId
variable) before calling pm.environment.set; if it's null/empty, throw or log a
clear error and stop execution (e.g., by calling pm.test/pm.expect or
equivalent) so you do not persist authId/executionId and downstream
/flow/execute failures are avoided.

2858-2858: ⚠️ Potential issue | 🟠 Major

Remove inline comment from raw body; this payload is invalid JSON.

Line 2858 includes // "mobileNumber"..., which breaks JSON parsing for the sample request body.

Suggested fix
-"raw": "{\n    \"executionId\": \"{{exec_flow_id}}\",\n    \"inputs\": {\n        \"username\": \"{{demoLoginUser1Username}}\",\n        \"password\": \"{{demoLoginUser1Password}}\"\n        // \"mobileNumber\": \"{{demoLoginUser1Mobile}}\"\n\n    },\n    \"action\": \"action_001\"\n}\n",
+"raw": "{\n    \"executionId\": \"{{exec_flow_id}}\",\n    \"inputs\": {\n        \"username\": \"{{demoLoginUser1Username}}\",\n        \"password\": \"{{demoLoginUser1Password}}\"\n    },\n    \"action\": \"action_001\"\n}\n",

Run this read-only verification to confirm the target raw body parses as valid JSON:

#!/bin/bash
set -euo pipefail

python - <<'PY'
import json
from pathlib import Path

path = Path("samples/api/postman/authentication/authentication_demo.json")
collection = json.loads(path.read_text())

def walk(items):
    for item in items:
        yield item
        for child in item.get("item", []):
            yield from walk([child])

target_name = "02.02 - Complete Authentication (Username & Password)"
for item in walk(collection["item"]):
    if item.get("name") == target_name:
        raw = item["request"]["body"]["raw"]
        try:
            json.loads(raw)
            print("VALID")
        except json.JSONDecodeError as exc:
            print(f"INVALID: {exc}")
        break
else:
    print("Target request not found")
PY

Expected result: VALID after the fix.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@samples/api/postman/authentication/authentication_demo.json` at line 2858,
The raw request body for the Postman request named "02.02 - Complete
Authentication (Username & Password)" contains an inline JavaScript-style
comment (// "mobileNumber"...) which makes the JSON invalid; remove that
commented line (or replace it with a valid JSON entry like removing the field
entirely or setting "mobileNumber": null) inside the request object's "raw"
string in samples/api/postman/authentication/authentication_demo.json so the raw
string parses as valid JSON.
🧹 Nitpick comments (3)
samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx (1)

104-117: Consider a legacy session key fallback during rollout.

At Line 117, state restores only from executionId. If a user started auth before deployment (stored flowId) and returns from IdP after deployment, Line 760 can submit with an empty id. For smoother rollout, keep a temporary fallback to the legacy key.

Proposed compatibility patch
 const START_INIT_KEY = 'startInit';
 const EXECUTION_ID_KEY = 'executionId';
+const LEGACY_FLOW_ID_KEY = 'flowId';

-const [executionId, setExecutionId] = useState<string>(sessionStorage.getItem(EXECUTION_ID_KEY) || '');
+const [executionId, setExecutionId] = useState<string>(
+    sessionStorage.getItem(EXECUTION_ID_KEY) ||
+    sessionStorage.getItem(LEGACY_FLOW_ID_KEY) ||
+    ''
+);

Also applies to: 256-257

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx` around lines 104 -
117, The executionId state is only initialized from EXECUTION_ID_KEY
('executionId') and can be empty if a user began auth with the legacy key
'flowId'; update the initialization and restore logic for executionId (the
useState for executionId and any places that read/setExecutionId/sessionStorage)
to fall back to sessionStorage.getItem('flowId') when
sessionStorage.getItem(EXECUTION_ID_KEY) is falsy, and when writing the id
persist it to both keys (EXECUTION_ID_KEY and 'flowId') so older in-flight
sessions remain compatible during rollout.
tests/integration/flow/registration/google_registration_test.go (1)

506-507: Consider renaming local flowID variables to executionID for clarity.

These locals now store execution identifiers; renaming would avoid semantic drift in test code.

✏️ Suggested cleanup
-	flowID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	completeFlowStep, err := common.CompleteFlow(flowID, inputs, "")
+	completeFlowStep, err := common.CompleteFlow(executionID, inputs, "")
...
-	flowID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	_, err = common.CompleteFlow(flowID, inputs, "")
+	_, err = common.CompleteFlow(executionID, inputs, "")
...
-	flowID := flowStep.ExecutionID
+	executionID := flowStep.ExecutionID
...
-	flowStep, err = common.CompleteFlow(flowID, inputs, "")
+	flowStep, err = common.CompleteFlow(executionID, inputs, "")

Also applies to: 571-572, 589-590

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/registration/google_registration_test.go` around lines
506 - 507, Rename the local variables named flowID to executionID where they
store execution identifiers (e.g., replace occurrences like "flowID :=
flowStep.ExecutionID" and any subsequent uses in this test file and the other
mentioned spots) so the variable name matches the value source
(flowStep.ExecutionID) and avoids semantic drift; update all references in tests
(including the other occurrences around lines with flowStep.Data.RedirectURL) to
use executionID consistently.
tests/integration/flow/authentication/github_auth_test.go (1)

373-374: Optional: use a consistent local name for execution identifier variables.

Using one lowercase local naming pattern (e.g., executionID) improves readability across this file.

Also applies to: 418-419, 436-437

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/integration/flow/authentication/github_auth_test.go` around lines 373 -
374, Rename the local variable ExecutionID to use a consistent lowercase local
naming (e.g., executionID) throughout the test file; locate the assignments like
"ExecutionID := flowStep.ExecutionID" (and the similar instances around the
other spots noted) and update the local variable name and all its subsequent
usages to executionID to match the lowercase pattern and improve readability.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@backend/internal/flow/executor/invite_executor_test.go`:
- Around line 91-92: Tests assert the invite URL now uses the query parameter
rename (flowId → executionId) via the invite link runtime data
(common.RuntimeKeyInviteLink); add documentation updates reflecting this
user-facing change by updating the API reference and invite/onboarding guide to
document the new executionId parameter, provide migration guidance for clients
(how to map old flowId values to executionId or handle both temporarily), and
update any example invite URLs and SDK/snippet samples that generate or parse
the invite link so they use executionId consistently; ensure the docs mention
the migration impact and timeline.

---

Outside diff comments:
In `@tests/e2e/tests/sample-app-authentication/README-MFA.md`:
- Line 136: Change the heading "Create the notification sender" (and the other
identical heading at the second occurrence) to Title Case to satisfy the
WSO2-IAM.TitleCaseTitles lint rule; replace the lowercase words so the headings
read "Create the Notification Sender" in both places (update the heading text in
the README-MFA.md where the markdown heading text "Create the notification
sender" appears).

In
`@tests/integration/flow/registration/google_registration_with_role_group_test.go`:
- Around line 440-452: The tests reveal a public contract change: the
/flow/execute parameter was renamed from flowId to executionId (referenced in
the test via flowStep.ExecutionID and the call to common.CompleteFlow), so add
documentation updates: modify docs/content/apis.mdx to describe the new
/flow/execute request/response schema using executionId, and create or update a
guide under docs/content/guides/ showing the migration steps (example requests
and responses) converting old flowId usages to executionId; ensure the docs
include the validation behavior and an example mirroring the test flow that
builds redirectURLStr and completes the flow with inputs {"code": "..."} so
consumers can migrate safely.

---

Duplicate comments:
In `@backend/internal/oauth/oauth2/authz/handler_test.go`:
- Around line 200-202: The test shows the OAuth correlation query param was
renamed from flowId to executionId (see oauth2const.ExecutionID and references
to flowId), but docs were not updated; update docs/content/apis.mdx (OAuth
authorize behavior) and the relevant guide(s) under docs/content/guides/ to
document the rename, include migration notes, updated example authorize/login
URLs showing executionId instead of flowId, and mention the change in any SDK or
config examples that reference flowId so callers know to use executionId.

In `@samples/api/postman/authentication/authentication_demo.json`:
- Around line 58-64: Add a guard to fail fast when the redirect URL is missing
executionId: check the result of url.searchParams.get("executionId") (the
executionId variable) before calling pm.environment.set; if it's null/empty,
throw or log a clear error and stop execution (e.g., by calling
pm.test/pm.expect or equivalent) so you do not persist authId/executionId and
downstream /flow/execute failures are avoided.
- Line 2858: The raw request body for the Postman request named "02.02 -
Complete Authentication (Username & Password)" contains an inline
JavaScript-style comment (// "mobileNumber"...) which makes the JSON invalid;
remove that commented line (or replace it with a valid JSON entry like removing
the field entirely or setting "mobileNumber": null) inside the request object's
"raw" string in samples/api/postman/authentication/authentication_demo.json so
the raw string parses as valid JSON.

---

Nitpick comments:
In `@samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx`:
- Around line 104-117: The executionId state is only initialized from
EXECUTION_ID_KEY ('executionId') and can be empty if a user began auth with the
legacy key 'flowId'; update the initialization and restore logic for executionId
(the useState for executionId and any places that
read/setExecutionId/sessionStorage) to fall back to
sessionStorage.getItem('flowId') when sessionStorage.getItem(EXECUTION_ID_KEY)
is falsy, and when writing the id persist it to both keys (EXECUTION_ID_KEY and
'flowId') so older in-flight sessions remain compatible during rollout.

In `@tests/integration/flow/authentication/github_auth_test.go`:
- Around line 373-374: Rename the local variable ExecutionID to use a consistent
lowercase local naming (e.g., executionID) throughout the test file; locate the
assignments like "ExecutionID := flowStep.ExecutionID" (and the similar
instances around the other spots noted) and update the local variable name and
all its subsequent usages to executionID to match the lowercase pattern and
improve readability.

In `@tests/integration/flow/registration/google_registration_test.go`:
- Around line 506-507: Rename the local variables named flowID to executionID
where they store execution identifiers (e.g., replace occurrences like "flowID
:= flowStep.ExecutionID" and any subsequent uses in this test file and the other
mentioned spots) so the variable name matches the value source
(flowStep.ExecutionID) and avoids semantic drift; update all references in tests
(including the other occurrences around lines with flowStep.Data.RedirectURL) to
use executionID consistently.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 032ab77d-facc-4d52-8e1a-ec432c7a4d70

📥 Commits

Reviewing files that changed from the base of the PR and between 70de5b8 and 7c34718.

⛔ Files ignored due to path filters (13)
  • backend/tests/mocks/flow/flowexecmock/FlowExecServiceInterface_mock.go is excluded by !**/*_mock.go
  • backend/tests/mocks/flow/flowexecmock/flowStoreInterface_mock.go is excluded by !**/*_mock.go
  • docs/__backup__/README.md is excluded by !docs/__backup__/**
  • docs/__backup__/authentication/server-orchestrated-flow/authentication.md is excluded by !docs/__backup__/**
  • docs/__backup__/authorization/flow-based-authorization.md is excluded by !docs/__backup__/**
  • docs/__backup__/flows/flow-execution.md is excluded by !docs/__backup__/**
  • docs/__backup__/observability/events.md is excluded by !docs/__backup__/**
  • docs/__backup__/registration/server-orchestrated-flow/registration.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/features/public-clients.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/authorization-code.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/client-credentials.md is excluded by !docs/__backup__/**
  • docs/__backup__/standards-based/oauth2-oidc/grant-types/token-exchange.md is excluded by !docs/__backup__/**
  • frontend/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (112)
  • ARCHITECTURE.md
  • README.md
  • api/flow-execution.yaml
  • backend/internal/flow/core/executor.go
  • backend/internal/flow/core/executor_test.go
  • backend/internal/flow/core/model.go
  • backend/internal/flow/core/node_test.go
  • backend/internal/flow/core/prompt_node.go
  • backend/internal/flow/core/prompt_node_test.go
  • backend/internal/flow/core/representation_node_test.go
  • backend/internal/flow/core/task_execution_node.go
  • backend/internal/flow/core/task_execution_node_test.go
  • backend/internal/flow/executor/attribute_collector.go
  • backend/internal/flow/executor/attribute_collector_test.go
  • backend/internal/flow/executor/attribute_uniqueness_validator.go
  • backend/internal/flow/executor/attribute_uniqueness_validator_test.go
  • backend/internal/flow/executor/auth_assert_executor.go
  • backend/internal/flow/executor/auth_assert_executor_test.go
  • backend/internal/flow/executor/authz_executor.go
  • backend/internal/flow/executor/authz_executor_test.go
  • backend/internal/flow/executor/basic_auth_executor.go
  • backend/internal/flow/executor/basic_auth_executor_test.go
  • backend/internal/flow/executor/consent_executor.go
  • backend/internal/flow/executor/consent_executor_test.go
  • backend/internal/flow/executor/credential_setter.go
  • backend/internal/flow/executor/credential_setter_test.go
  • backend/internal/flow/executor/email_executor.go
  • backend/internal/flow/executor/email_executor_test.go
  • backend/internal/flow/executor/federated_auth_resolver_executor.go
  • backend/internal/flow/executor/federated_auth_resolver_executor_test.go
  • backend/internal/flow/executor/http_request_executor.go
  • backend/internal/flow/executor/http_request_executor_test.go
  • backend/internal/flow/executor/identifying_executor.go
  • backend/internal/flow/executor/identifying_executor_test.go
  • backend/internal/flow/executor/invite_executor.go
  • backend/internal/flow/executor/invite_executor_test.go
  • backend/internal/flow/executor/oauth_executor.go
  • backend/internal/flow/executor/oauth_executor_test.go
  • backend/internal/flow/executor/oidc_auth_executor.go
  • backend/internal/flow/executor/oidc_auth_executor_test.go
  • backend/internal/flow/executor/ou_executor.go
  • backend/internal/flow/executor/ou_executor_test.go
  • backend/internal/flow/executor/ou_resolver_executor.go
  • backend/internal/flow/executor/ou_resolver_executor_test.go
  • backend/internal/flow/executor/passkey_executor.go
  • backend/internal/flow/executor/passkey_executor_test.go
  • backend/internal/flow/executor/permission_validator.go
  • backend/internal/flow/executor/permission_validator_test.go
  • backend/internal/flow/executor/provisioning_executor.go
  • backend/internal/flow/executor/provisioning_executor_test.go
  • backend/internal/flow/executor/sms_auth_executor.go
  • backend/internal/flow/executor/sms_auth_executor_test.go
  • backend/internal/flow/executor/sms_executor.go
  • backend/internal/flow/executor/sms_executor_test.go
  • backend/internal/flow/executor/user_type_resolver.go
  • backend/internal/flow/executor/user_type_resolver_test.go
  • backend/internal/flow/flowexec/FlowExecServiceInterface_mock_test.go
  • backend/internal/flow/flowexec/engine.go
  • backend/internal/flow/flowexec/engine_event_enabled_test.go
  • backend/internal/flow/flowexec/error_constants.go
  • backend/internal/flow/flowexec/flowStoreInterface_mock_test.go
  • backend/internal/flow/flowexec/handler.go
  • backend/internal/flow/flowexec/model.go
  • backend/internal/flow/flowexec/model_test.go
  • backend/internal/flow/flowexec/service.go
  • backend/internal/flow/flowexec/service_test.go
  • backend/internal/flow/flowexec/store.go
  • backend/internal/flow/flowexec/store_test.go
  • backend/internal/oauth/oauth2/authz/handler_test.go
  • backend/internal/oauth/oauth2/authz/service.go
  • backend/internal/oauth/oauth2/authz/service_test.go
  • backend/internal/oauth/oauth2/constants/constants.go
  • backend/internal/system/log/constants.go
  • backend/internal/system/observability/event/datakeys.go
  • docs/content/community/contributing/contributing-code/backend-development/observability.md
  • docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx
  • docs/static/api/next/combined.yaml
  • frontend/apps/thunder-gate/src/pages/AcceptInvitePage.tsx
  • frontend/pnpm-workspace.yaml
  • samples/api/postman/authentication/README.md
  • samples/api/postman/authentication/authentication_demo.json
  • samples/api/postman/authentication/environment.json
  • samples/apps/react-vanilla-sample/src/pages/LoginPage.tsx
  • samples/apps/react-vanilla-sample/src/services/authService.ts
  • tests/e2e/tests/sample-app-authentication/README-MFA.md
  • tests/e2e/utils/thunder-setup/mfa-setup.ts
  • tests/integration/flow/authentication/assurance_test.go
  • tests/integration/flow/authentication/attribute_collect_test.go
  • tests/integration/flow/authentication/authz_test.go
  • tests/integration/flow/authentication/basic_auth_test.go
  • tests/integration/flow/authentication/conditional_exec_auth_test.go
  • tests/integration/flow/authentication/github_auth_test.go
  • tests/integration/flow/authentication/google_auth_test.go
  • tests/integration/flow/authentication/multi_action_input_binding_test.go
  • tests/integration/flow/authentication/prompt_actions_test.go
  • tests/integration/flow/authentication/sensitive_input_cleanup_test.go
  • tests/integration/flow/authentication/sms_auth_test.go
  • tests/integration/flow/authentication/verbose_meta_test.go
  • tests/integration/flow/common/model.go
  • tests/integration/flow/common/utils.go
  • tests/integration/flow/registration/basic_registration_test.go
  • tests/integration/flow/registration/github_registration_test.go
  • tests/integration/flow/registration/google_registration_test.go
  • tests/integration/flow/registration/google_registration_with_role_group_test.go
  • tests/integration/flow/registration/http_request_executor_runtime_data_test.go
  • tests/integration/flow/registration/ou_registration_test.go
  • tests/integration/flow/registration/sms_registration_test.go
  • tests/integration/oauth/authz/authz_test.go
  • tests/integration/oauth/token/refresh_token_test.go
  • tests/integration/oauth/userinfo/userinfo_test.go
  • tests/integration/testutils/models.go
  • tests/integration/testutils/oauth2_utils.go
✅ Files skipped from review due to trivial changes (37)
  • backend/internal/flow/executor/federated_auth_resolver_executor.go
  • backend/internal/flow/executor/ou_executor_test.go
  • docs/content/community/contributing/contributing-code/backend-development/observability.md
  • samples/api/postman/authentication/environment.json
  • backend/internal/flow/executor/attribute_uniqueness_validator.go
  • backend/internal/flow/core/task_execution_node.go
  • backend/internal/flow/executor/authz_executor_test.go
  • frontend/pnpm-workspace.yaml
  • backend/internal/flow/core/prompt_node.go
  • backend/internal/flow/executor/auth_assert_executor.go
  • backend/internal/flow/executor/permission_validator_test.go
  • backend/internal/flow/core/executor.go
  • README.md
  • backend/internal/flow/executor/sms_executor.go
  • backend/internal/flow/executor/ou_executor.go
  • backend/internal/flow/executor/basic_auth_executor.go
  • backend/internal/flow/executor/http_request_executor.go
  • backend/internal/flow/executor/credential_setter_test.go
  • backend/internal/flow/executor/identifying_executor.go
  • backend/internal/oauth/oauth2/authz/service.go
  • backend/internal/flow/executor/ou_resolver_executor_test.go
  • frontend/apps/thunder-gate/src/pages/AcceptInvitePage.tsx
  • tests/e2e/utils/thunder-setup/mfa-setup.ts
  • docs/content/guides/key-concepts/authentication/passwordless/passkeys.mdx
  • tests/integration/flow/registration/github_registration_test.go
  • backend/internal/flow/executor/sms_executor_test.go
  • backend/internal/flow/executor/federated_auth_resolver_executor_test.go
  • backend/internal/flow/executor/provisioning_executor_test.go
  • backend/internal/flow/executor/identifying_executor_test.go
  • backend/internal/flow/executor/email_executor_test.go
  • backend/internal/flow/core/executor_test.go
  • backend/internal/flow/core/task_execution_node_test.go
  • backend/internal/flow/executor/http_request_executor_test.go
  • backend/internal/flow/executor/user_type_resolver_test.go
  • tests/integration/flow/authentication/conditional_exec_auth_test.go
  • ARCHITECTURE.md
  • backend/internal/flow/flowexec/service.go
🚧 Files skipped from review as they are similar to previous changes (49)
  • backend/internal/flow/executor/ou_resolver_executor.go
  • backend/internal/flow/core/node_test.go
  • backend/internal/flow/executor/provisioning_executor.go
  • backend/internal/flow/core/model.go
  • backend/internal/flow/executor/permission_validator.go
  • backend/internal/flow/executor/attribute_collector_test.go
  • backend/internal/flow/core/representation_node_test.go
  • backend/internal/flow/executor/consent_executor.go
  • samples/api/postman/authentication/README.md
  • tests/integration/flow/authentication/authz_test.go
  • tests/integration/testutils/models.go
  • tests/integration/flow/authentication/sensitive_input_cleanup_test.go
  • tests/integration/oauth/authz/authz_test.go
  • tests/integration/flow/registration/sms_registration_test.go
  • backend/internal/flow/executor/consent_executor_test.go
  • backend/internal/system/observability/event/datakeys.go
  • backend/internal/oauth/oauth2/constants/constants.go
  • backend/internal/system/log/constants.go
  • tests/integration/flow/registration/ou_registration_test.go
  • backend/internal/flow/flowexec/engine.go
  • backend/internal/flow/executor/sms_auth_executor.go
  • tests/integration/flow/common/model.go
  • tests/integration/flow/registration/http_request_executor_runtime_data_test.go
  • tests/integration/flow/authentication/google_auth_test.go
  • backend/internal/flow/executor/oidc_auth_executor_test.go
  • tests/integration/oauth/userinfo/userinfo_test.go
  • backend/internal/flow/executor/basic_auth_executor_test.go
  • backend/internal/flow/flowexec/error_constants.go
  • backend/internal/oauth/oauth2/authz/service_test.go
  • backend/internal/flow/executor/invite_executor.go
  • backend/internal/flow/flowexec/engine_event_enabled_test.go
  • samples/apps/react-vanilla-sample/src/services/authService.ts
  • backend/internal/flow/flowexec/model_test.go
  • backend/internal/flow/flowexec/store_test.go
  • backend/internal/flow/executor/sms_auth_executor_test.go
  • backend/internal/flow/executor/email_executor.go
  • tests/integration/flow/authentication/multi_action_input_binding_test.go
  • tests/integration/flow/authentication/assurance_test.go
  • backend/internal/flow/flowexec/model.go
  • api/flow-execution.yaml
  • backend/internal/flow/flowexec/store.go
  • backend/internal/flow/executor/oauth_executor_test.go
  • backend/internal/flow/executor/user_type_resolver.go
  • tests/integration/flow/authentication/basic_auth_test.go
  • tests/integration/flow/registration/basic_registration_test.go
  • backend/internal/flow/executor/authz_executor.go
  • backend/internal/flow/flowexec/flowStoreInterface_mock_test.go
  • backend/internal/flow/executor/auth_assert_executor_test.go
  • backend/internal/flow/flowexec/FlowExecServiceInterface_mock_test.go

Comment thread backend/internal/flow/executor/invite_executor_test.go
Comment thread backend/internal/flow/flowexec/service.go Outdated
Comment thread backend/internal/flow/flowexec/service.go Outdated
Comment thread backend/internal/system/observability/event/datakeys.go Outdated
@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch 3 times, most recently from 58b1e60 to 9b305c1 Compare April 10, 2026 10:57
@ThaminduDilshan ThaminduDilshan changed the title Rename flowID in flow execution to flowExecutionId Rename flowID in flow execution to executionId Apr 10, 2026
@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch from 53eeefb to 96ccc03 Compare April 10, 2026 11:53
@NutharaNR NutharaNR force-pushed the fix/rename-flowid-in-flow-execution branch from 96ccc03 to e77dbe1 Compare April 10, 2026 12:16
@ThaminduDilshan ThaminduDilshan linked an issue Apr 10, 2026 that may be closed by this pull request
@ThaminduDilshan ThaminduDilshan added this pull request to the merge queue Apr 10, 2026
Merged via the queue into asgardeo:main with commit f459a88 Apr 10, 2026
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking change The feature/ improvement will alter the existing behaviour dependencies-approved Type/Improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Revisit flow/execution response structure: rename flowId

4 participants