Null Fields in Policy and Resource When Fetching Permission by ID via SDK

Dear Keycloak Development Team,

I’ve encountered an issue when using the Keycloak Java SDK to manage permissions. Specifically, I’ve created a resource permission by associating a resource ID and a policy ID. After creation, the permission appears correctly in the Keycloak Admin Console, with all fields (e.g., policy and resource) properly populated.

However, when I fetch the permission by its ID using the Java SDK, the policy and resource fields in the response are null.

Here are the steps I followed:

Created the permission using the SDK with both the resource and policy properly set.
Verified in the admin console that the resource and policy are correctly associated with the permission.
Queried the permission by ID using the SDK, where the policy and resource fields are unexpectedly null.
Could this behavior be due to SDK limitations, or a possible misconfiguration? Are there any known issues or additional steps I need to take to ensure the policy and resource fields are populated when fetching a permission via the SDK?

I am using Keycloak version 22.0 and SDK version 22.0.5.

Any insights or guidance would be greatly appreciated