add finally block to POST request