how to use RFC1123 date in http header?

hey guys. can smb explain to me how to use DateTimeFormatter RFC_1123_DATE_TIME? Im making a request to the api and i need to have
Date
header with its value being in RFC1123 format. can smb help me out? i dont understand what to write here:
HttpHeaders headers = new HttpHeaders();
headers.set();

thanks in advance.
Was this page helpful?