# Delete image in Media DB (claudinary)

**URL:** <https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736>\
**Category:** Questions about Thunkable X\
**Created:** [January 13, 2021, 2:06pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736 "2021-01-13T14:06:59Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![funhall](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/funhall/32/92145_2.png) [@funhall](https://community.thunkable.com/u/funhall)\
**Post date:** [January 13, 2021, 2:06pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/1 "2021-01-13T14:06:59Z")

</div>

I can find a topic ow to delete a picture in Claudinary. Anyone with the magic hints, thanks…

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [January 13, 2021, 2:11pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/2 "2021-01-13T14:11:32Z")

</div>

As far as I know, I think you can only substitute it by uploading another image displaying the text this image does not exist anymore.  
[![](https://upload.wikimedia.org/wikipedia/commons/e/e0/Deleted_photo.png) ](https://upload.wikimedia.org/wikipedia/commons/e/e0/Deleted_photo.png)

---

<div class="post-metadata">

**Author:** ![funhall](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/funhall/32/92145_2.png) [@funhall](https://community.thunkable.com/u/funhall)\
**Post date:** [January 13, 2021, 2:17pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/3 "2021-01-13T14:17:09Z")

</div>

i just dont want my cloudinary to be full of not used pictures…

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [January 13, 2021, 2:19pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/4 "2021-01-13T14:19:59Z")

</div>

You can try setting a variable deleted to false. When a user clicks the delete image button, set it to true. When displaying Cloudinary images, check if the variable is true. If it is, set the URL of the image to any image displaying DELETED, instead of displaying the most recent Cloudinary picture.

---

<div class="post-metadata">

**Author:** ![funhall](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/funhall/32/92145_2.png) [@funhall](https://community.thunkable.com/u/funhall)\
**Post date:** [January 13, 2021, 2:21pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/5 "2021-01-13T14:21:48Z")

</div>

Yes but as I undertand it this solution dosent delete the picture in Cloudinary. Is that right???

---

<div class="post-metadata">

**Author:** ![codeswept](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/codeswept/32/87755_2.png) [@codeswept](https://community.thunkable.com/u/codeswept)\
**Post date:** [January 13, 2021, 4:16pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/6 "2021-01-13T16:16:27Z")

</div>

Yes, it doesn’t. It just displays another image saying that the image has been ‘deleted’.

---

<div class="post-metadata">

**Author:** ![drted](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/drted/32/92694_2.png) [@drted](https://community.thunkable.com/u/drted)\
**Post date:** [January 13, 2021, 10:44pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/7 "2021-01-13T22:44:33Z")

</div>

@funhall,

I think you will need to use the cloudinary web (REST) api

> **[How can I delete an image via the API?](https://support.cloudinary.com/hc/en-us/articles/203465641-How-can-I-delete-an-image-via-the-API-)**
>
> Deleting a single file can be done via the API with the destroy method. e.g. (Node JS):
> cloudinary.uploader.destroy('zombie', function(result) { console.log(result) });
> For more information:https:/...

---

<div class="post-metadata">

**Author:** ![paulovaz72](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/paulovaz72/32/119071_2.png) [@paulovaz72](https://community.thunkable.com/u/paulovaz72)\
**Post date:** [December 7, 2021, 11:16am UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/8 "2021-12-07T11:16:23Z")

</div>

I think this idea very useful, so the way to implement this is using the “WEB API” component, right?

If possible, can you provide some example block how to call this destroy method mentioned in the above link?

Thanks!

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 7, 2021, 12:29pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/9 "2021-12-07T12:29:18Z")

</div>

Yes, you need to use `Web API` to delete the file.

---

<div class="post-metadata">

**Author:** ![paulovaz72](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/paulovaz72/32/119071_2.png) [@paulovaz72](https://community.thunkable.com/u/paulovaz72)\
**Post date:** [December 7, 2021, 2:15pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/10 "2021-12-07T14:15:05Z")

</div>

Any example block to share? I’m a little bit lost in how to implement it… 😛

---

<div class="post-metadata">

**Author:** ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)\
**Post date:** [December 7, 2021, 3:02pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/11 "2021-12-07T15:02:57Z")

</div>

Check this

[https://x.thunkable.com/projectPage/61af762898837902ac7b6b18](https://x.thunkable.com/projectPage/61af762898837902ac7b6b18)

---

<div class="post-metadata">

**Author:** ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)\
**Post date:** [November 8, 2024, 1:30pm UTC](https://community.thunkable.com/t/delete-image-in-media-db-claudinary/1047736/12 "2024-11-08T13:30:48Z")

</div>


