@Post("/upload")
    public HttpResponse upload(@Param String text, @Param File file) throws IOException {
        return HttpResponse.of(() -> {
            try {
                final String content = Files.readString(file.toPath());
                return HttpResponse.ofJson(Arrays.asList(text, content));
            } catch (IOException e) {
                throw new UncheckedIOException(e);
            } finally {
                file.delete();
            }
        }, ServiceRequestContext.current().blockingTaskExecutor().withoutContext());
    }
Examples how to use {@link Param} with {@link File}.
examples/annotated-http-service/src/main/java/example/armeria/server/annotated/FileUploadService.java