Broken link on newly added camera

I am on HA Core, running in docker on Ubuntu.
I have a front doorbell camera. I am able to use the following to get a snapshot via a web browser:

http://admin:mypassword@camera-IP/cgi-bin/snapshot.cgi

However, when I add the following to my configuration.yaml, restart, and find the entity in my system, the image link is broken.

camera:
  - platform: mjpeg
    name: frontdoor_snapshot_cam
    mjpeg_url: http://admin:mypassword@camera-IP/cgi-bin/snapshot.cgi

What’s wrong?

Lastly…
If I were to use:

camera:
  - platform: mjpeg
    name: frontdoor_snapshot_cam
    username: !secret doorbell_username
    password: !secret doorbell_password
    mjpeg_url: http://camera-IP/cgi-bin/snapshot.cgi

how do I get the username and password variables accessed from my secrets file to be put in the url? Is it automatically added? When I try the above conf, it’s the same broken image.

Nevermind… I got what I want done using another method. Still don’t know what was wrong on this one, but it doesn’t matter, now.