YouTube channels have an ID, which is used by default. Channel may also have a custom URL.
It would be helpful to be able to search artists by both URLs, and for the system to recognize duplicate artists when submitting an artist entry. For example, if artist entry already exists containing the YouTube channel with ID and the editor attempts to submit artist with the custom URL, the system would recognize those the same, and give a warning.
One way to implement this would be to use the YouTube API to fetch both the ID and custom URL and save those as metadata to the external link. Or we could create a hidden "child" link. This would be better for searching, but more complicated to manage.
Possibly we can skip persisting the metadata and do the API request on the fly when user pastes a YouTube channel URL. Some kind of caching would still be helpful.
So it could work as following:
User pastes a YouTube channel URL.
System searches for exact match of the URL being pasted.
If no result is found, attempt to resolve alternate URL (ID vs. custom URL) and search by that.
YouTube channels have an ID, which is used by default. Channel may also have a custom URL.
It would be helpful to be able to search artists by both URLs, and for the system to recognize duplicate artists when submitting an artist entry. For example, if artist entry already exists containing the YouTube channel with ID and the editor attempts to submit artist with the custom URL, the system would recognize those the same, and give a warning.
One way to implement this would be to use the YouTube API to fetch both the ID and custom URL and save those as metadata to the external link. Or we could create a hidden "child" link. This would be better for searching, but more complicated to manage.
Possibly we can skip persisting the metadata and do the API request on the fly when user pastes a YouTube channel URL. Some kind of caching would still be helpful.
So it could work as following: