##
my $attributes = { name => "test.txt", parent => { id => 0 }};
$ua->post(ENDPOINT,
Content_Type => 'form-data',
Authorization => "Bearer $token",
Content => [
attributes => encode_json($attributes),
file => [ "test.txt" ],
],
);
##
##
[ undef, "test.txt", Content => $file_contents ]