GraphQL: "fetchNeedReload" always returning "Doreload is not required"

Hi,

I am using GraphQL to create extensions.
It works fine, I make my changes, and after calling “doreload” I can connect to these extensions.

But “doreload” is very long and I don’t want to call it after every operation I make.
Rather, I would like to be able to add/delete extentions quickly and then apply the changes (much like in the FreePBX GUI).

To do that the right way, I need to know if any configuration needs to be applied. I figured that was what “fetchNeedReload” was for, so I tried calling it. But no matter what I do the answer I get is always “message”: “Doreload is not required”, “status”: true.

Am I missunderstanding the function, or is this a bug?

Regards.

What version of freepbx are you running?

Graphql of:

query {
  fetchNeedReload{
    message status
  }
}

on mine successfully gives:

{
    "data": {
        "fetchNeedReload": {
            "message": "Doreload is required",
            "status": true
        }
    }
}

when I make a major change.

I’ll give precisions on Monday regarding the version.
But what do you call a major change? Any mutation?
Adding and deleting exensions should be part of it, right?

Also, could you please clarify for me what is “status” in the answer?

Thanks.

For me, it was adding a new extension

Status seems to just be the “did the graphQL Query execute?”

So “successfully ram command”

I will admit, I hate this specific graphQL call. “Blah blah it needs a reload” is not easy to work with programmatically

I’d much prefer something like “needsreload”=true or something.

You could likely submit a feature request for that

Thanks for the clarification.
Then it shoudl work for me too… yes it doesn’t.

The version I am working with is FreePBX 16.0.10.32.
May I ask what is yours?

im on FreePBX 15, sadly.

I reinstalled FreePBX, exact same version, and now it works… go figure.

1 Like

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.