Skip to content

Conversation

@kleyow
Copy link
Contributor

@kleyow kleyow commented Dec 19, 2025

This pull request introduces enhancements to the ML API Adapter, focusing on improved handling of GET notification messages (including FX GET) and validation logic for transfer fulfilments. It also adds comprehensive unit tests for the new GET forwarding logic and increments the package version.

Notification GET request forwarding:

  • Updated src/handlers/notification/index.js to detect and correctly forward GET and FX_GET notification messages with empty payloads as HTTP GET requests to the appropriate FSP endpoint, ensuring proper header construction, endpoint resolution, and error handling.

Transfer fulfilment validation:

  • Modified src/api/transfers/handler.js to skip payload validation for transfer fulfilment requests originating from external participants (determined by absence of the fspiop-proxy header), allowing for more flexible integrations.

Testing improvements:

  • Added unit tests in test/unit/handlers/notification/index.test.js to verify correct forwarding of GET and FX_GET notification messages, successful and failed forwarding scenarios, and appropriate audit tagging.

Versioning:

  • Bumped the package version to 16.7.0-snapshot.3 in package.json.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds GET request forwarding functionality to support proxied participants in the ml-api-adapter service. The implementation enables the system to forward GET requests (queries) to proxied participants when there's no response payload, while maintaining backward compatibility for PUT responses when payload data is present.

Changes:

  • Added GET request forwarding logic in the notification handler for proxy scenarios
  • Modified fulfil transfer validation to skip when 'fspiop-proxy' header is present
  • Added comprehensive test coverage for GET and FX-GET forwarding scenarios

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
src/handlers/notification/index.js Added GET request forwarding logic with empty payload detection and proxy endpoint resolution
src/api/transfers/handler.js Added conditional validation skip for proxy requests based on header presence
test/unit/handlers/notification/index.test.js Added three new test cases covering GET forwarding success scenarios and error handling
package.json Version bump to 16.7.0-snapshot.3
package-lock.json Version updates and dependency changes including dev flag removals

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

kleyow and others added 4 commits January 12, 2026 22:03
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 5 out of 6 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@sonarqubecloud
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
32.6% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

@kleyow kleyow marked this pull request as ready for review January 13, 2026 03:44
@kleyow kleyow merged commit 6a1ec09 into main Jan 15, 2026
18 of 19 checks passed
@kleyow kleyow deleted the feat/forward-get branch January 15, 2026 05:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants