HTTP report Json output

I want to get a json formatted report output from Duplicati. If I use the following I get a text output. And it works

–send-http-result-output-format=Duplicati
–send-http-url=https://URL/index.php

index.php

<?php
$file = 'report.txt';
$current .= $_POST['message'];
$current .= "\r\n";
$current .= "-------------------------------------------------------\r\n";
file_put_contents($file, $current, FILE_APPEND);
?>

But changing

–send-http-result-output-format=Json

I get no output at all.
Can anyone help? Thanks

By setting
–send-mail-result-output-format=Json
I get a proper Json email output but not on the HTTTP

For now I just want to save the Json to a text file.

Anyone have a idea?

Welcome to the forum @Mark_Stoehr

Nothing direct from me, but maybe ideas on troubleshooting. For example, is there a server log that says whether anything came in? netstat usually shows some lingering addresses after a connection as well. Crude way on a Linux or similar remote would ls -lu --full-time on the index.php file for file access.

looks kind of like Duplicati logging at verbose level (e.g. About → Show log → Live → Verbose) might log. Testing that theory could be done in a working config such as your original, then use JSON and compare.

Is there any long output being inserted, or just the brief statistics? There are some length limits around…

Im using the followinf PHP that will log all PHP varibles to the Txt file

<?php
$file = 'report.txt';
$arr = get_defined_vars();
$current .= print_r($arr, true);
$current .= "\r\n";
$current .= "-------------------------------------------------------\r\n";
file_put_contents($file, $current, FILE_APPEND);
?>

With
–send-http-result-output-format=Duplicati
I GET

Array
(
[_GET] => Array
(
)

[_POST] => Array
    (
        [message] => Duplicati Backup report for test10-stoehrserver

DeletedFiles: 0
DeletedFolders: 0
ModifiedFiles: 0
ExaminedFiles: 9
OpenedFiles: 0
AddedFiles: 0
SizeOfModifiedFiles: 0
SizeOfAddedFiles: 0
SizeOfExaminedFiles: 12170845
SizeOfOpenedFiles: 0
NotProcessedFiles: 0
AddedFolders: 0
TooLargeFiles: 0
FilesWithError: 0
ModifiedFolders: 0
ModifiedSymlinks: 0
AddedSymlinks: 0
DeletedSymlinks: 0
…etc

BUT WITH
–send-http-result-output-format=Json
I Get nothing not even the $_POST[‘message’]

Array
(
[_GET] => Array
(
)

[_POST] => Array
    (
    )

[_COOKIE] => Array
    (
    )

[_FILES] => Array
    (
    )

[file] => report.txt

)