Apple has launched a replacement program for iPhone XS, iPhone XS Max and iPhone XR battery cases manufactured between January 2019 and October 2019. It will replace cases that won't charge or only charges intermittently when plugged in, as well as cases don't properly charge.
Apple's battery cases cost around $130 each, so you may want to take advantage of the program while you can. Apple says it will replace cases up to two years from their date of sale. Apple says the program isn't related to a safety issue.