Unlike its battery replacement for iPhone 6 or newer models that'll set you back $29, though, Apple will swap your MacBook Pro battery for free... so long as you have an eligible model. Cupertino said it's not a safety issue, but if you can get the replacement at no cost, it'll probably be best to take advantage of the offer.
Since not all 13-inch Pros without Touch Bar are affected (other and older models aren't prone to the same component failure) you'll first have to make sure you're covered under the program. Simply go to the program page and look up your serial number, which you can find in About this Mac (click the Apple logo on the top menu), under your laptop or on its box.
If you're eligible for a replacement, you'll have to find an Apple Store or an Apple Authorized Service Provider, but you can also mail your laptop to a repair center. Even if you're physically going to a store, you may want to wipe your data after backing it up anyway, since your laptop might still have to be sent to a repair center and stay there for three to five days. (In case you already had your battery replaced, you can ask Apple for a reimbursement.) Take note that Apple wants to resolve any other issue your MacBook might have before replacing your battery, and that extra repair might not be free.