PHP SDK shows error while calling src/Infusionsoft.php -> requestAccessToken()

Hi
We try to connect Infusionsoft using API.
But we faced the error.
This is the test link
https://chatbot.pwamembership.co/dev_test/infusionsoft/samples/addWithDupCheck.php
Please help me.

I would suggest providing the error you received, as well as the code for the call that failed.

Like Tom has said, letting us know the specific error would help, however, I have a feeling you’re experiencing what many do when they first undertake this. I have a video on OAuth and my guess is that you’re getting a not authorized message or something similar (also based on the fact that you’re using the example code rather than something you wrote tells me you’re looking to first understand the process). I have a video on the subject so take a look at that and let us know if it helps.

Thank you for user support.

We used XML RPC method and sort out the issue.

We need to help our Customer.
From our Application to connect our Client infusion soft account.
Which is the best way to do?

  1. REST API
    https://developer.infusionsoft.com/docs/rest/#!/Account_Info/getAccountProfileUsingGET

or

2)XML RPC
https://developer.infusionsoft.com/docs/xml-rpc/

What is the difference between above two?

How to add multiple app account in infusionsoft?

We have one app account
https://by693.infusionsoft.com/

You can use either depending on what functions you need. REST offers some functions the XML-RPC does not but the XML-RPC can also do some things REST cannot.

So start there by defining what your need for the api are.

You could use both if you needed the api calls but then you’d want to divide your calls by type to try to evenly distribute their use between the SSO api key method and OAuth