-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
I am looking for a simple way to test the connection to the LRS
- Create the XApiClientBuilder
- Create the xApiClient
- Create the statementsApiClient
- getStatements
use Xabbuh\XApi\Client\XApiClientBuilder;
use Http\Adapter\Guzzle7\Client;
use Http\Message\MessageFactory\GuzzleMessageFactory;
.
.
.
$builder = new XApiClientBuilder();
$xApiClient = $builder
->setHttpClient(new Client())
->setRequestFactory(new GuzzleMessageFactory())
->setBaseUrl($endpoint)
->setAuth($key, $secret)
->setVersion($version)
->build();
$statementsApiClient = $xApiClient->getStatementsApiClient();
$result = $statementsApiClient->getStatements();
All of this works, but what I am looking to do is a simple test to check the connection works before I get into statements/storing. Is there a method available that I am missing that can test the client before doing any statements/storing?
Metadata
Metadata
Assignees
Labels
No labels