Skip to content

Commit

Permalink
add profile filters
Browse files Browse the repository at this point in the history
  • Loading branch information
Niko Heller committed Aug 13, 2024
1 parent e6b6ac6 commit 4ee2977
Show file tree
Hide file tree
Showing 10 changed files with 834 additions and 44 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "verdigado/gruene-api-client",
"version": "0.7.0",
"version": "0.8.0",
"description": "PHP client library for gruene api",
"keywords": [
"openapitools",
Expand Down
23 changes: 15 additions & 8 deletions docs/Api/ProfilesApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ try {
## `deleteProfile()`

```php
deleteProfile($profile_id)
deleteProfile($profile_id): \Verdigado\GrueneApiClient\models\Profile
```

Delete user profile
Expand Down Expand Up @@ -111,7 +111,8 @@ $apiInstance = new Verdigado\GrueneApiClient\Api\ProfilesApi(
$profile_id = 'profile_id_example'; // string

try {
$apiInstance->deleteProfile($profile_id);
$result = $apiInstance->deleteProfile($profile_id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ProfilesApi->deleteProfile: ', $e->getMessage(), PHP_EOL;
}
Expand All @@ -125,7 +126,7 @@ try {

### Return type

void (empty response body)
[**\Verdigado\GrueneApiClient\models\Profile**](../Model/Profile.md)

### Authorization

Expand All @@ -134,7 +135,7 @@ void (empty response body)
### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: Not defined
- **Accept**: `application/json`

[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
[[Back to Model list]](../../README.md#models)
Expand Down Expand Up @@ -275,7 +276,7 @@ try {
## `findProfiles()`

```php
findProfiles($tags, $search): \Verdigado\GrueneApiClient\models\FindProfilesResponse
findProfiles($limit, $tags, $offset, $search, $division): \Verdigado\GrueneApiClient\models\FindProfilesResponse
```

Find user profiles
Expand All @@ -302,11 +303,14 @@ $apiInstance = new Verdigado\GrueneApiClient\Api\ProfilesApi(
new GuzzleHttp\Client(),
$config
);
$limit = 20; // float
$tags = array('tags_example'); // string[] | Filter by profile tag ids
$search = 'search_example'; // string | Search term to look for in firstName, lastName, email, username.
$offset = 3.4; // float
$search = 'search_example'; // string | Search term to look for in firstName, lastName and username
$division = 'division_example'; // string | Division key to filter profiles. Only include profiles that are member of given division.

try {
$result = $apiInstance->findProfiles($tags, $search);
$result = $apiInstance->findProfiles($limit, $tags, $offset, $search, $division);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling ProfilesApi->findProfiles: ', $e->getMessage(), PHP_EOL;
Expand All @@ -317,8 +321,11 @@ try {

| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **limit** | **float**| | [optional] [default to 20] |
| **tags** | [**string[]**](../Model/string.md)| Filter by profile tag ids | [optional] |
| **search** | **string**| Search term to look for in firstName, lastName, email, username. | [optional] |
| **offset** | **float**| | [optional] |
| **search** | **string**| Search term to look for in firstName, lastName and username | [optional] |
| **division** | **string**| Division key to filter profiles. Only include profiles that are member of given division. | [optional] |

### Return type

Expand Down
1 change: 1 addition & 0 deletions docs/Model/FindProfilesResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**data** | [**\Verdigado\GrueneApiClient\models\PublicProfile[]**](PublicProfile.md) | |
**meta** | [**\Verdigado\GrueneApiClient\models\FindProfilesResponseMeta**](FindProfilesResponseMeta.md) | |

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
12 changes: 12 additions & 0 deletions docs/Model/FindProfilesResponseMeta.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# # FindProfilesResponseMeta

## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**count** | **float** | | [optional]
**offset** | **float** | | [optional]
**limit** | **float** | | [optional]
**has_next** | **bool** | | [optional]

[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
4 changes: 2 additions & 2 deletions lib/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ class Configuration
*
* @var string
*/
protected $userAgent = 'OpenAPI-Generator/0.7.0/PHP';
protected $userAgent = 'OpenAPI-Generator/0.8.0/PHP';

/**
* Debug switch (default set to false)
Expand Down Expand Up @@ -433,7 +433,7 @@ public static function toDebugReport()
$report .= ' OS: ' . php_uname() . PHP_EOL;
$report .= ' PHP Version: ' . PHP_VERSION . PHP_EOL;
$report .= ' The version of the OpenAPI document: 0.1.0' . PHP_EOL;
$report .= ' SDK Package Version: 0.7.0' . PHP_EOL;
$report .= ' SDK Package Version: 0.8.0' . PHP_EOL;
$report .= ' Temp Folder Path: ' . self::getDefaultConfiguration()->getTempFolderPath() . PHP_EOL;

return $report;
Expand Down
Loading

0 comments on commit 4ee2977

Please sign in to comment.