Title: Api#resourceByAssetID does not support same options as in documentation · Issue #357 · cloudinary/cloudinary_java · GitHub
Open Graph Title: Api#resourceByAssetID does not support same options as in documentation · Issue #357 · cloudinary/cloudinary_java
X Title: Api#resourceByAssetID does not support same options as in documentation · Issue #357 · cloudinary/cloudinary_java
Description: Bug report for Cloudinary Java SDK Before proceeding, please update to latest version and test if the issue persists Describe the bug in a sentence or two. It seems that Api#resourceByAssetID does not support same parameters as describe ...
Open Graph Description: Bug report for Cloudinary Java SDK Before proceeding, please update to latest version and test if the issue persists Describe the bug in a sentence or two. It seems that Api#resourceByAssetID does ...
X Description: Bug report for Cloudinary Java SDK Before proceeding, please update to latest version and test if the issue persists Describe the bug in a sentence or two. It seems that Api#resourceByAssetID does ...
Opengraph URL: https://github.com/cloudinary/cloudinary_java/issues/357
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Api#resourceByAssetID does not support same options as in documentation","articleBody":"## Bug report for Cloudinary Java SDK\r\nBefore proceeding, please update to latest version and test if the issue persists\r\n\r\n## Describe the bug in a sentence or two.\r\nIt seems that Api#resourceByAssetID does not support same parameters as describe in documentation.\r\nIn [Cloudinary Api Docs ](https://cloudinary.com/documentation/admin_api#get_details_of_a_single_resource_by_assetid_syntax). E.g image_metadata is described as supported option. Thus, i would expect that\r\n` cloudinary.api().resourceByAssetID(asset.asset_id(), Map.of(\"image_metadata\", true))` would result in `GET /v1_1/\u003cclient\u003e/resources/\u003casset-id\u003e?image_metadata=true`. But actually it results in `/v1_1/\u003cclient\u003e/resources/\u003casset-id\u003e` without 'image_metadata' parameter.\r\n\r\nApi#resourceByAssetID implementation does not match configuration options in documentation.\r\n```java\r\n public ApiResponse resourceByAssetID(String assetId, Map options) throws Exception {\r\n if (options == null) options = ObjectUtils.emptyMap();\r\n if(options.get(\"fields\") != null) {\r\n options.put(\"fields\", StringUtils.join(ObjectUtils.asArray(options.get(\"fields\")), \",\"));\r\n }\r\n Map params = ObjectUtils.only(options, \"tags\", \"context\", \"moderations\", \"fields\");\r\n ApiResponse response = callApi(HttpMethod.GET, Arrays.asList(\"resources\", assetId), params, options);\r\n return response;\r\n }\r\n```\r\n\r\nSince with simple curl the api responds with expected image metadata included my guess is that the java implementation is too restrictive.\r\n\r\n## Issue Type (Can be multiple)\r\n[ ] Build - Can’t install or import the SDK\r\n[ ] Performance - Performance issues\r\n[x ] Behaviour - Functions aren’t working as expected (Such as generate URL)\r\n[ ] Documentation - Inconsistency between the docs and behaviour\r\n[ ] Other (Specify)\r\n\r\n## Steps to reproduce\r\n… if applicable\r\n\r\n## Error screenshots or Stack Trace (if applicable)\r\n…\r\n\r\n## Build System\r\n[ ] Maven\r\n[x ] Gradle\r\n[ ] Other (Specify)\r\n\r\n## OS (Please specify version)\r\n[ ] Windows\r\n[ ] Linux\r\n[ ] Mac\r\n[ ] Other (specify)\r\n\r\n## Versions and Libraries (fill in the version numbers)\r\nCloudinary Java SDK version - 2.0.0\r\nJVM (dev environment) - 0.0.0\r\nJVM (production environment) - 0.0.0\r\nMaven - 0.0.0 / N/A\r\nGradle - 0.0.0 / N/A\r\n\r\n## Repository\r\nIf possible, please provide a link to a reproducible repository that showcases the problem\r\n","author":{"url":"https://github.com/ClaudioWaldvogel","@type":"Person","name":"ClaudioWaldvogel"},"datePublished":"2024-11-27T15:17:18.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":2},"url":"https://github.com/357/cloudinary_java/issues/357"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b3ebf466-5c26-ad36-d9cd-9aca5ebc3cb7 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9A1C:3E5481:BE7420:FDC1B3:697C37AD |
| html-safe-nonce | 45d043a38be7dd9c055a8d9c6fb932b97958d3e4d64e110ada6b73014be7b62d |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5QTFDOjNFNTQ4MTpCRTc0MjA6RkRDMUIzOjY5N0MzN0FEIiwidmlzaXRvcl9pZCI6Ijg5MTEwNzM2MTkyMjg3NjgxNzMiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 70efe9a429dacbfdeb004e7f4e7c53f9d024c6881ac3a6122fe5b3f6f77df0d2 |
| hovercard-subject-tag | issue:2698894825 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/cloudinary/cloudinary_java/357/issue_layout |
| twitter:image | https://opengraph.githubassets.com/ac9a619ef45fea07cb657b68be57187a6ab434a024237bb6c9fdce9256962350/cloudinary/cloudinary_java/issues/357 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/ac9a619ef45fea07cb657b68be57187a6ab434a024237bb6c9fdce9256962350/cloudinary/cloudinary_java/issues/357 |
| og:image:alt | Bug report for Cloudinary Java SDK Before proceeding, please update to latest version and test if the issue persists Describe the bug in a sentence or two. It seems that Api#resourceByAssetID does ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ClaudioWaldvogel |
| hostname | github.com |
| expected-hostname | github.com |
| None | da4f0ee56809799586f8ee546b27f94fe9b5893edfbf87732e82be45be013b52 |
| turbo-cache-control | no-preview |
| go-import | github.com/cloudinary/cloudinary_java git https://github.com/cloudinary/cloudinary_java.git |
| octolytics-dimension-user_id | 1460763 |
| octolytics-dimension-user_login | cloudinary |
| octolytics-dimension-repository_id | 6179800 |
| octolytics-dimension-repository_nwo | cloudinary/cloudinary_java |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 6179800 |
| octolytics-dimension-repository_network_root_nwo | cloudinary/cloudinary_java |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 787d8d274e314f52ce6d846c7581f9476d8dc736 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width