0

I'm trying to connect WorkflowMax to my application and it's throwing the error "You don't have access to connect any WorkflowMax accounts".

Here's the server side code (NodeJS):

const oauth2 = simpleOauthModule.create({
    client: {
        id: 'client id',
        secret: 'secret key',
    },
    auth: {
       tokenHost: 'https://identity.xero.com',
       authorizeHost: 'https://login.xero.com',
       tokenPath: '/connect/token',
       authorizePath: '/identity/connect/authorize',
    },
    options: {
        authorizationMethod: 'body',
    }
});

const authorizationUri = oauth2.authorizationCode.authorizeURL({
    redirect_uri: 'example.com/_oauth2',
    state: Random.id(),
    scope: 'openid profile workflowmax'
});

The user account I'm using does have the "Authorise 3rd Party Full Access" permission ticked in the WorkflowMax staff settings. I've waited about a day for the permissions to update and tried it on other accounts.

Is there anything else I need to do to allow WorkflowMax Oauth 2?

Here's an image of what it's throwing:

enter image description here

Casey Gibson
  • 2,577
  • 1
  • 20
  • 23

1 Answers1

0

I can see you have included the correct scopes. If your staff permission is set correctly you should have access to the account. You will need to use your staff account to go through the consent screens. The setting should be an instant update you don't need to wait for it to take effect.

Unfortunately I can't provide any more assistant here. I have replicated this in my environment and worked fine.

Jenks Guo
  • 36
  • 2
  • I've edited the post to show the message I'm getting. It seems pretty easy to setup, but for some reason it's not allowing access. From what you've said, it doesn't sound like anything else needs to be setup in the Workflow Max dashboard. I've simply created the app in Xero, and ticked "Authorise 3rd Party Full Access" permission in Workflow max. – Casey Gibson May 15 '20 at 06:07
  • Hi @KcGibson, this might be a silly thing to ask to check. You will also need to make sure you have an actual workflowmax account. The practice manager account will not be able to show as an workflowmax account. – Jenks Guo May 18 '20 at 01:21
  • Hi @KcGibson, here is how you can check the account type: Buisness -> Subscription -> Cancel Subscription tab -> first sentence will tell you what type it is e.g. Xero Practice Manager or WFM. – Jenks Guo May 18 '20 at 04:30
  • The subscription does say 'Xero Practice Manager', but when I use the scope 'practicemanager', the Xero page returns an error saying "Error: unauthorized_client : Invalid scope for client". – Casey Gibson May 18 '20 at 23:26