Missing required arguments - wsgetmail

I’m having trouble getting wsgetmail to work.

There is an error while trying to run the debug command.

wsgetmail --debug --dry-run --config=wsgetmail.json

Missing required arguments: command_args at /usr/local/share/perl/5.34.0/App/wsgetmail.pm line 266

Upon checking the file, here are the codes from lines 260 to 267.

260 sub _build_mda {
261 my $self = shift;
262 my $config = clone $self->config;
263 if ( defined $self->config->{username}) {
264 $config->{recipient} //= $self->config->{username};
265 }
266 return App::wsgetmail::MDA->new($config);
267 }

Does anyone have any idea?

Here is the step by step configuration guide for Wsgetmail that I have documented:

Please make sure that your wsgetmail.json is correct as
App::wsgetmail::MDA takes mail fetched from web services and routes it to another command via standard input.

App::wsgetmail::MDA requires
Command and Command_args as parameter that you need to define in your configuration JSON file (wsgetmail.json)

command": “/opt/rt4/bin/rt-mailgate”,
“command_args”: “–url=https://rt.yourdomain.com/ --queue=‘Queue Name’ --action=correspond”,
“command_timeout”: 30,

Ali,

I was able to run the command without any problems. But I haven’t seen any emails coming into RT even though all the settings are there. Any suggestions?

Here is one of the message error - on RT site: The RT System itself - Sending the previous mail has failed. Please contact your admin, they can find more details in the logs.

Please share the screenshot of running wsgetmail --debug --dry-run

Here it is:


Also, here is the message on RT’s site

I use wsgetmail for incoming mail and Postfix for outgoing mail.

It seems that the Graph API permission may cause this issue, Please make sure that you have set all needed permission correctly.

I figured it out, there was a problem with the username

Thank you!