@tennac-booking/sdk
Version:
OpenAPI client for @tennac-booking/sdk
155 lines (98 loc) • 3.62 kB
Markdown
# ClubRolesStaffApi
All URIs are relative to *http://localhost*
|Method | HTTP request | Description|
|------------- | ------------- | -------------|
|[**getAllClubRoles**](#getallclubroles) | **GET** /api/club-roles | |
|[**getClubRoleById**](#getclubrolebyid) | **GET** /api/club-roles/{id} | |
|[**getUserRolesInClubs**](#getuserrolesinclubs) | **GET** /api/club-roles/me/roles | |
# **getAllClubRoles**
> Array<ClubRoleResponse> getAllClubRoles()
Récupère la liste des rôles d\'un club
### Example
```typescript
import {
ClubRolesStaffApi,
Configuration
} from '@tennac-booking/sdk';
const configuration = new Configuration();
const apiInstance = new ClubRolesStaffApi(configuration);
const { status, data } = await apiInstance.getAllClubRoles();
```
### Parameters
This endpoint does not have any parameters.
### Return type
**Array<ClubRoleResponse>**
### Authorization
[bearerAuth](../README.md#bearerAuth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Liste des roles | - |
|**400** | Bad Request | - |
|**401** | Unauthorized | - |
|**500** | Server Error | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **getClubRoleById**
> ClubRoleResponse getClubRoleById()
Récupère un rôle de club par ID
### Example
```typescript
import {
ClubRolesStaffApi,
Configuration
} from '@tennac-booking/sdk';
const configuration = new Configuration();
const apiInstance = new ClubRolesStaffApi(configuration);
let id: string; // (default to undefined)
const { status, data } = await apiInstance.getClubRoleById(
id
);
```
### Parameters
|Name | Type | Description | Notes|
|------------- | ------------- | ------------- | -------------|
| **id** | [**string**] | | defaults to undefined|
### Return type
**ClubRoleResponse**
### Authorization
[bearerAuth](../README.md#bearerAuth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Role trouvé | - |
|**401** | Unauthorized | - |
|**404** | Not Found | - |
|**500** | Server Error | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **getUserRolesInClubs**
> UserRolesResponse getUserRolesInClubs()
### Example
```typescript
import {
ClubRolesStaffApi,
Configuration
} from '@tennac-booking/sdk';
const configuration = new Configuration();
const apiInstance = new ClubRolesStaffApi(configuration);
const { status, data } = await apiInstance.getUserRolesInClubs();
```
### Parameters
This endpoint does not have any parameters.
### Return type
**UserRolesResponse**
### Authorization
[bearerAuth](../README.md#bearerAuth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
|**200** | Ok | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)