Skip to content

Latest commit

 

History

History
72 lines (49 loc) · 1.97 KB

UserApi.md

File metadata and controls

72 lines (49 loc) · 1.97 KB

LivewatchApi\UserApi

All URIs are relative to https://www.livewatch.de.

Method HTTP request Description
apiTokenDetails() POST /api/user/token Get your API-Token.

apiTokenDetails()

apiTokenDetails($username, $password): \LivewatchApi\Model\ApiToken

Get your API-Token.

Provide your access credentials and return api token

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure API key authorization: LivewatchToken
$config = LivewatchApi\Configuration::getDefaultConfiguration()->setApiKey('auth-livewatch-token', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = LivewatchApi\Configuration::getDefaultConfiguration()->setApiKeyPrefix('auth-livewatch-token', 'Bearer');


$apiInstance = new LivewatchApi\Api\UserApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$username = 'username_example'; // string
$password = 'password_example'; // string

try {
    $result = $apiInstance->apiTokenDetails($username, $password);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->apiTokenDetails: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
username string
password string

Return type

\LivewatchApi\Model\ApiToken

Authorization

LivewatchToken

HTTP request headers

  • Content-Type: multipart/form-data
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]