It comes from the arms and armor collection of the Rijksmuseum in Amsterdam and dates to 1650-1670. Set in between two pieces of rock crystal is a miniature flintlock, complete with a tiny flint inside. Parts of the lock are blued. The whole mechanism is carefully made and there’s cutout along the top of the ring so you can cock the hammer.
While it’s fun to think there might have been a little barrel that could fit onto the lock and form a functioning miniature, the Rijksmuseum staff has pondered that very question. Unfortunately, they concluded that the setting of the ring has no cutout that would accommodate a barrel so it seems to be merely a curiosity. Personally I would like to think it was a cigarette lighter or fire starter or something practical like that, but I would suspect it is just a demonstration of what a skilled craftsman could do.
Although no one knows who the ring belonged to, it was probably made for one of the Stadholders of the Republic (provincial executive officer, maybe the equivalent of a governor).