You could save the object to a variable and then it doesn't happen. Still not sure WHY it is happening though.
library(httr)
res <- GET("http://comtrade.un.org/api/get?type=C&freq=A&px=HS&ps=2013&r=842&p=0&rg=all&cc=TOTAL&fmt=csv")
datin <- httr::content(res, "parsed", encoding = "UTF-8", show_col_types = FALSE)
datin
#> # A tibble: 3 x 35
#> Classification Year Period `Period Desc.` `Aggregate Level` `Is Leaf Code`
#> <chr> <dbl> <dbl> <dbl> <dbl> <dbl>
#> 1 H4 2013 2013 2013 0 0
#> 2 H4 2013 2013 2013 0 0
#> 3 H4 2013 2013 2013 0 0
#> # ... with 29 more variables: Trade Flow Code <dbl>, Trade Flow <chr>,
#> # Reporter Code <dbl>, Reporter <chr>, Reporter ISO <chr>,
#> # Partner Code <dbl>, Partner <chr>, Partner ISO <chr>,
#> # 2nd Partner Code <lgl>, 2nd Partner <lgl>, 2nd Partner ISO <lgl>,
#> # Customs Proc. Code <lgl>, Customs <lgl>, Mode of Transport Code <lgl>,
#> # Mode of Transport <lgl>, Commodity Code <chr>, Commodity <chr>,
#> # Qty Unit Code <dbl>, Qty Unit <chr>, Qty <lgl>, ...
Created on 2021-11-12 by the reprex package (v2.0.1)