Get all models of type

I currently have this code

for _, obj in ipairs(GetGamePool('CObject')) do
	if DoesEntityExist(obj) and GetEntityModel(obj) == GetHashKey('prop_vend_soda_01') then
        ...
	end

This code seems to only get all object rendered around the player on the moment the script is started.
When I move to a place further away from the location where I started the script, then it doesn’t work.

I use ox_target inside the if statement and the third eye option don’t show on the vending machines far away from the place where I was when the script started

for _, obj in ipairs(GetGamePool('CObject')) do
	if DoesEntityExist(obj) and GetEntityModel(obj) == GetHashKey(Config.Models.Cola) then
      exports.ox_target:addBoxZone({
         coords = GetEntityCoords(obj),
         size = vec3(2,2,2),
         rotation = 45,
         debug = drawZones,
        options = {
             {
               distance = 1,
               name = "buy-cola",
               event = 'ss-script:buycola',
               icon = 'fa-solid fa-cube',
               label = "Buy Cola ($" .. Config.Prices.Cola .. ")",
            }
         }
     })
	end
end

Since you use ox_target you can use
addModel - Ox Target (overextended.dev) to add options to a specific model or list of models

In the documentation it says:
• models: number or string or Array<number | string>

What do I have to put in here?

when I put 'prop_vend_coffe_01' I get an error expected array (received hash table)

EDIT.
Fixed it I forgot to remove the position attributes from the addBoxZone