An error occurred during the request. Unable to proceed. Failed to enable ExApp

Error:
An error occurred during the request. Unable to proceed.
Failed to enable ExApp

What I was trying to do:
I was trying to install To Gif Example in app API, for external apps. I also tried to install Context Chat Backend and I got the same error

Console log:


  Error    app_api            Failed to enable ExApp to_gif_example. Error: cURL error 6: Could not resolve host: to_gif_example (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for                2024-04-02T15:40:12+00:00 
                              http://to_gif_example:23000/enabled?enabled=1                                                                                                                                                            

  Error    app_api            GuzzleHttp\Exception\ConnectException: cURL error 6: Could not resolve host: to_gif_example (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for                       2024-04-02T15:40:12+00:00 
                              http://to_gif_example:23000/enabled?enabled=1 at .../guzzlehttp/guzzle/src/Handler/CurlFactory.php line 210                                                                                              
                                                                                                                                                                                                                                       
                               0. 3rdparty/guzzlehttp/guzzle/src/Handler/CurlFactory.php line 158                                                                                                                                      
                                  GuzzleHttp\Handler\CurlFactory::createRejection("*** sensitive parameters replaced ***")                                                                                                             
                               1. 3rdparty/guzzlehttp/guzzle/src/Handler/CurlFactory.php line 110                                                                                                                                      
                                  GuzzleHttp\Handler\CurlFactory::finishError(                                                                                                                                                         
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                               2. 3rdparty/guzzlehttp/guzzle/src/Handler/CurlHandler.php line 47                                                                                                                                       
                                  GuzzleHttp\Handler\CurlFactory::finish(                                                                                                                                                              
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                               3. 3rdparty/guzzlehttp/guzzle/src/Middleware.php line 137                                                                                                                                               
                                  GuzzleHttp\Handler\CurlHandler->__invoke(                                                                                                                                                            
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                               4. lib/private/Http/Client/DnsPinMiddleware.php line 121                                                                                                                                                
                                  GuzzleHttp\Middleware::GuzzleHttp\{closure}("*** sensitive parameters replaced ***")                                                                                                                 
                               5. 3rdparty/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php line 35                                                                                                                                     
                                  OC\Http\Client\DnsPinMiddleware->OC\Http\Client\{closure}("*** sensitive parameters replaced ***")                                                                                                   
                               6. 3rdparty/guzzlehttp/guzzle/src/Middleware.php line 31                                                                                                                                                
                                  GuzzleHttp\PrepareBodyMiddleware->__invoke(                                                                                                                                                          
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                               7. 3rdparty/guzzlehttp/guzzle/src/RedirectMiddleware.php line 71                                                                                                                                        
                                  GuzzleHttp\Middleware::GuzzleHttp\{closure}("*** sensitive parameters replaced ***")                                                                                                                 
                               8. 3rdparty/guzzlehttp/guzzle/src/Middleware.php line 63                                                                                                                                                
                                  GuzzleHttp\RedirectMiddleware->__invoke(                                                                                                                                                             
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                               9. 3rdparty/guzzlehttp/guzzle/src/HandlerStack.php line 75                                                                                                                                              
                                  GuzzleHttp\Middleware::GuzzleHttp\{closure}("*** sensitive parameters replaced ***")                                                                                                                 
                              10. 3rdparty/guzzlehttp/guzzle/src/Client.php line 331                                                                                                                                                   
                                  GuzzleHttp\HandlerStack->__invoke(                                                                                                                                                                   
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              11. 3rdparty/guzzlehttp/guzzle/src/Client.php line 168                                                                                                                                                   
                                  GuzzleHttp\Client->transfer(                                                                                                                                                                         
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              12. 3rdparty/guzzlehttp/guzzle/src/Client.php line 187                                                                                                                                                   
                                  GuzzleHttp\Client->requestAsync("*** sensitive parameters replaced ***")                                                                                                                             
                              13. lib/private/Http/Client/Client.php line 337                                                                                                                                                          
                                  GuzzleHttp\Client->request(                                                                                                                                                                          
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              14. apps/app_api/lib/Service/AppAPIService.php line 130                                                                                                                                                  
                                  OC\Http\Client\Client->put(                                                                                                                                                                          
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              15. apps/app_api/lib/Service/AppAPIService.php line 517                                                                                                                                                  
                                  OCA\AppAPI\Service\AppAPIService->requestToExApp(                                                                                                                                                    
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              16. apps/app_api/lib/Controller/ExAppsPageController.php line 426                                                                                                                                        
                                  OCA\AppAPI\Service\AppAPIService->enableExApp(                                                                                                                                                       
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              17. lib/private/AppFramework/Http/Dispatcher.php line 230                                                                                                                                                
                                  OCA\AppAPI\Controller\ExAppsPageController->enableApp(                                                                                                                                               
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              18. lib/private/AppFramework/Http/Dispatcher.php line 137                                                                                                                                                
                                  OC\AppFramework\Http\Dispatcher->executeController(                                                                                                                                                  
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              19. lib/private/AppFramework/App.php line 184                                                                                                                                                            
                                  OC\AppFramework\Http\Dispatcher->dispatch(                                                                                                                                                           
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              20. lib/private/Route/Router.php line 315                                                                                                                                                                
                                  OC\AppFramework\App::main(                                                                                                                                                                           
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              21. lib/base.php line 1069                                                                                                                                                                               
                                  OC\Route\Router->match(                                                                                                                                                                              
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    
                              22. index.php line 39                                                                                                                                                                                    
                                  OC::handleRequest(                                                                                                                                                                                   
                                                                                                                                                                                                                                       
                                  )                                                                                                                                                                                                    

  Warning  app_api            Failed heartbeat on http://to_gif_example:23000 for 250 times. Most recent status=0, error: cURL error 6: Could not resolve host: to_gif_example (see                          2024-04-02T15:40:18+00:00 
                              https://curl.haxx.se/libcurl/c/libcurl-errors.html) for http://to_gif_example:23000/heartbeat

Prior issues:
I struggled to successfully register a daemon that would work, but found a solution, can be seen at Default Deploy Daemon is not accessible. Please verify its configuration - :information_source: Support - Nextcloud community.

Docker containers:
I can see the docker containers were created, but they can’t be enabled

CONTAINER ID   IMAGE                                               COMMAND                CREATED         STATUS                         PORTS     NAMES
e25bc5ce549e   ghcr.io/cloud-py-api/to_gif_example:1.2.0           "python3 main.py"      6 minutes ago   Up 6 minutes                             nc_app_to_gif_example
16087c4306b9   ghcr.io/cloud-py-api/nextcloud-appapi-dsp:release   "/bin/bash start.sh"   2 hours ago     Up About an hour (unhealthy)             nextcloud-appapi-dsp

What I have tried:
I have tried registering and enabling the aforementioned apps by doing the following
sudo -u www-data php /var/www/nextcloud/occ app_api:app:register context_chat_backend
sudo -u www-data php /var/www/nextcloud/occ app_api:app:enablecontext_chat_backend
But once I enable it, it says Failed to enable ExApp context_chat_backend.

My Daemon configuration can be found the previously mentioned forum post, found at Default Deploy Daemon is not accessible. Please verify its configuration - :information_source: Support - Nextcloud community.

Thank you