{"id":17191354,"date":"2023-11-10T12:32:54","date_gmt":"2023-11-10T12:32:54","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/rest-api-wrong-source-url\/"},"modified":"2023-11-10T12:32:54","modified_gmt":"2023-11-10T12:32:54","slug":"rest-api-wrong-source-url","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/rest-api-wrong-source-url\/","title":{"rendered":"REST API wrong source URL"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Hey there, great plugin and best cloud image service by far!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Maybe you can help us out. We are currently facing an issue with the response from the REST API returning a wrong source_url.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">We are fetching some posts via the WP API, for example <a href=\"https:\/\/www.mukken.com\/m\/wp-json\/wp\/v2\/banner\/?_embed&amp;per_page=50&amp;status=publish\">here<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Within the response the first entry has following source_url:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><em>&#8220;source_url&#8221;: &#8220;https:\/\/res.cloudinary.com\/simplefox\/images\/f_auto,q_auto\/v1689156211?_i=AA&#8221;,<\/em><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you try to open this link, the image won&#8217;t show \/ does not exist. We doubled checked the attached image and got following URL within the media listing \/ on single attachment view:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">https:\/\/res.cloudinary.com\/simplefox\/images\/f_auto,q_auto\/v1689156211\/blog\/mukken-shop-de\/mukken-shop-de.?_i=AA<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img data-recalc-dims=\"1\" decoding=\"async\" src=\"https:\/\/i0.wp.com\/i.ibb.co\/2cYvTyn\/Bildschirmfoto-2023-11-10-um-13-14-48.png?ssl=1\" alt=\"\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">&#8212;&#8212;<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Not only here, we also saw a different file url presented within the single media view, vs the media embed modal.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">media embed modal within post: set featured image<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img data-recalc-dims=\"1\" decoding=\"async\" src=\"https:\/\/i0.wp.com\/i.ibb.co\/mvLL8p0\/Bildschirmfoto-2023-11-10-um-13-28-46.png?ssl=1\" alt=\"\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">You can see the v1689156211.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">VS the single attachment view<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img data-recalc-dims=\"1\" decoding=\"async\" src=\"https:\/\/i0.wp.com\/i.ibb.co\/1GrW8y0\/Bildschirmfoto-2023-11-10-um-13-29-48.png?ssl=1\" alt=\"\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Here we have a v1689156333.<\/p>\n","protected":false},"template":"","class_list":["post-17191354","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/17191354","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/17191354\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=17191354"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}