A toy needed batteries so I connected it to an outlet.
It is not possible to connet an item to an outlet without a plug.
Both batteries and a wall outlet can provide power to an object.
Some toys can be charged using a wall outlet.