Deductions & credits

Selling house closed 1/31/19.  Can I use these fees/charges to lower our selling price?  Irrigation, HOA, mortgage interest.  When buying 2/17/17, can I use these  fees/charges to increase purchase price?  Homeowner ins, closing fee, closing letter, courier fee, title endorsement fee, wire transfer fee, & title insurance transaction fee.  This is 2nd home.