-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e466b39
commit bfc1718
Showing
75 changed files
with
55,184 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
.github export-ignore | ||
.gitattributes export-ignore | ||
.gitignore export-ignore | ||
.php-cs-fixer.php export-ignore | ||
test export-ignore | ||
doc export-ignore | ||
phpunit.xml.dist export-ignore | ||
composer.lock export-ignore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.idea |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
# Kimai API | ||
|
||
JSON API for the Kimai time-tracking software: [API documentation](https://www.kimai.org/documentation/rest-api.html) | ||
|
||
This PHP package is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project: | ||
|
||
- API version: 0.6 | ||
- Build package: io.swagger.codegen.languages.PhpClientCodegen | ||
|
||
## Requirements | ||
|
||
PHP 5.5 and later | ||
|
||
## Installation & Usage | ||
|
||
### Composer | ||
|
||
To install the bindings via [Composer](http://getcomposer.org/): | ||
|
||
```bash | ||
composer require kimai/api-php | ||
``` | ||
|
||
|
||
## Getting Started | ||
|
||
Please follow the [installation procedure](#installation--usage) and then run the following: | ||
|
||
```php | ||
<?php | ||
require_once(__DIR__ . '/vendor/autoload.php'); | ||
|
||
// Configure API key authorization: apiToken | ||
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-AUTH-TOKEN', 'YOUR_API_KEY'); | ||
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed | ||
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-AUTH-TOKEN', 'Bearer'); | ||
// Configure API key authorization: apiUser | ||
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-AUTH-USER', 'YOUR_API_KEY'); | ||
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed | ||
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-AUTH-USER', 'Bearer'); | ||
|
||
$apiInstance = new Swagger\Client\Api\ActivityApi( | ||
// 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 | ||
); | ||
$project = ""; // string | Project ID to filter activities | ||
$projects = ""; // string | Comma separated list of project IDs to filter activities | ||
$visible = "1"; // string | Visibility status to filter activities. Allowed values: 1=visible, 2=hidden, 3=all (default: 1) | ||
$globals = "1"; // string | Use if you want to fetch only global activities. Allowed values: true (default: false) | ||
$globals_first = "globals_first_example"; // string | Deprecated parameter, value is not used any more | ||
$order_by = ""; // string | The field by which results will be ordered. Allowed values: id, name, project (default: name) | ||
$order = "order_example"; // string | The result order. Allowed values: ASC, DESC (default: ASC) | ||
$term = "term_example"; // string | Free search term | ||
|
||
try { | ||
$result = $apiInstance->apiActivitiesGet($project, $projects, $visible, $globals, $globals_first, $order_by, $order, $term); | ||
print_r($result); | ||
} catch (Exception $e) { | ||
echo 'Exception when calling ActivityApi->apiActivitiesGet: ', $e->getMessage(), PHP_EOL; | ||
} | ||
|
||
?> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
{ | ||
"name": "kimai/api-php", | ||
"type": "library", | ||
"description": "Swagger generated API stubs for Kimai", | ||
"keywords": [ | ||
"kimai", | ||
"swagger", | ||
"php", | ||
"sdk", | ||
"api" | ||
], | ||
"homepage": "https://github.com/kimai/api-php", | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": "Kevin Papst", | ||
"homepage": "https://www.kevinpapst.de" | ||
}, | ||
{ | ||
"name": "Swagger and contributors", | ||
"homepage": "https://github.com/swagger-api/swagger-codegen" | ||
} | ||
], | ||
"require": { | ||
"php": ">=5.5", | ||
"ext-curl": "*", | ||
"ext-json": "*", | ||
"ext-mbstring": "*", | ||
"guzzlehttp/guzzle": "^6.2" | ||
}, | ||
"autoload": { | ||
"psr-4": { "Swagger\\Client\\" : "lib/" } | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { "Swagger\\Client\\" : "test/" } | ||
} | ||
} |
Oops, something went wrong.