Skip to content

[BUG] Custom Parsers aren't triggered on payloads that are defined though Operations.Channel #1099

Open

Description

@liam-oldershaw-ctct

Describe the bug.

A custom parser isn't triggered on a root document like:

operations: 
  FooOperation:
    action: send
    channel:
       $ref: otherFile.yaml#/channels/BarChannel

And there is another file that defines the channel and message

channels:
  BarChannel:
    address:
    messages:
      AMessage:
        $ref: '#/components/messages/AMessage'
components:
  messages:
    AMessage:
      payload:
        schemaFormat: ....
        schema: ......

In the parsed json that is handled by packages/parser/src/custom-operations/parse-schema.ts#86 (in the variable detailed.parsed) the path to the payload with the custom schema is
$.operations.FooOperation.channel.messages.AMessage.payload

which is not covered in packages/parser/src/custom-operations/parse-schema.ts#25

A work around to this is to also re-specify the channel in the root document eg

channels:
  BarChannel:
    $ref: otherFile.yaml#/channels/BarChannel

operations: 
  FooOperation:
    action: send
    channel:
       $ref: #/channels/BarChannel

but this feels weird as the channel is already fully defined in the other file and I am looking to re-use channels for other definitions

Expected behavior

I believe customSchemasPathsV3 should also include
$.operations.*.channel.messages.*.payload

Screenshots

NA

How to Reproduce

Root AsyncApi file:

operations: 
  FooOperation:
    action: send
    channel:
       $ref: otherFile.yaml#/channels/BarChannel

Other referenced file:

channels:
  BarChannel:
    address:
    messages:
      AMessage:
        $ref: '#/components/messages/AMessage'
components:
  messages:
    AMessage:
      payload:
        schemaFormat: ....
        schema: ......

🖥️ Device Information [optional]

AsyncApi v3

👀 Have you checked for similar open issues?

  • I checked and didn't find similar issue

🏢 Have you read the Contributing Guidelines?

Are you willing to work on this issue ?

Yes I am willing to submit a PR!

Activity

  1. github-actions commented on Jul 10, 2025

    @github-actions

    Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup useful for opening a pull request.
    Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.

  2. github-actions commented on Nov 8, 2025

    @github-actions

    This issue has been automatically marked as stale because it has not had recent activity 😴

    It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation.

    There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model.

    Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here.

    Thank you for your patience ❤️

  3. sumedhcharjan commented on Jan 18, 2026

    @sumedhcharjan

    Hi, I noticed there was a previous PR linked to this issue that wasn’t merged.
    If this issue is still relevant, I’d be happy to try fixing it or continuing the work.
    Please let me know if that’s okay.

  4. liam-oldershaw-ctct commented on Jan 18, 2026

    @liam-oldershaw-ctct
    Author

    Hey @sumedhcharjan

    Yea the issue is still present. I'm not effected by it anymore as I've changed the structure of my async api files. The branch just needs review and merging. I do remember finding another issue while writing unit tests but i haven't raised anything for that yet

  5. github-actions commented on May 19, 2026

    @github-actions

    This issue has been automatically marked as stale because it has not had recent activity 😴

    It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation.

    There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model.

    Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here.

    Thank you for your patience ❤️

  6. q404365631 commented on Jun 3, 2026

    @q404365631

    I'd like to work on this! I'll trace why custom parsers don't trigger on payload-defined schemas and submit a PR with a fix + test.

  7. q404365631 commented on Jun 4, 2026

    @q404365631

    已提交新 PR #1177(branch: fix/operation-channel-payload-1099)。

    比之前的PR #1176更干净:只含#1099的4行JSONPath + 一个changeset,2个文件+17行。

    注意:@glowcloud的PR #1171已经5天没review了,如果维护者先合并那个我会撤回这个。

  8. github-actions commented on Oct 2, 2026

    @github-actions

    This issue has been automatically marked as stale because it has not had recent activity 😴

    It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation.

    There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model.

    Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here.

    Thank you for your patience ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingstale

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions