Hello piguy101,
It would help if you could to provide some code so we can see what you’ve done so far… We won’t be able to help if all we have is ‘I want to do this thing with this other thing’.
It makes it much easier for us to offer constructive answers if you follow Community Guidelines #9. 11, & 14 by supplying a properly formatted configuration for the automation that you have attempted. Please share the YAML and any errors so we can see what you’ve done.