Zend certified PHP/Magento developer

Fetch Category ID in Magento 2.3.7

Excuse my poor presentation of a question
I am trying to list products of the same category on any product page of the named category.

Here is the code I have, which works perfectly if done for each category of product. But I wish to have a category id fetch code to insert in this here, so I can load it to all my products pages.

Here is the code I have with category id “842”

<div class="cdz-product-wrap base-slider product-list-style-30  bottom-hovered-style mb-stage-padding-5 text-center">
<div class="cdz-block-title">
<p class="b-title h2"><span class="inner">ALL COLORS IN THIS CATEGORY:</span></p>
<p class="title-desc">Recommended for You</p>
</div>
<div class="cdz-block-content">
<div class="cdz-product">{{widget type="CodazonProductFilterBlockProductProductsList" display_type="all_products" products_count="22" order_by="entity_id DESC" show="thumb,name,review,price,addtocart,wishlist,compare,quickshop,label" thumb_width="250" thumb_height="250" filter_template="custom" custom_template="grid-style-30.phtml" conditions_encoded="^['1':^['type':'Magento||CatalogWidget||Model||Rule||Condition||Combine','aggregator':'all','value':'1','new_child':''^],'1--1':^['type':'Magento||CatalogWidget||Model||Rule||Condition||Product','attribute':'category_ids','operator':'==','value':'842'^]^]" total_rows="1" total_cols="4" ajax_load="0" show_slider="1" slider_dots="0" slider_nav="1" slider_autoplay="0" slider_autoplay_timeout="5000" slider_margin="20" items_1900="4" items_1600="4" items_1420="4" items_1280="4" items_980="4" items_768="3" items_480="3" items_320="2" items_0="1"}}</div>
</div>
</div>

Is there any way to add a code in here to fetch each product’s category id so I do not have to implement it manually to each group

Thanks for your kind attention