[TASK] Initial version, with some help from Junie. Copies all files in albums to the local filesystem.
This commit is contained in:
991
generated/immich/openapi_client/docs/AlbumsApi.md
Normal file
991
generated/immich/openapi_client/docs/AlbumsApi.md
Normal file
@@ -0,0 +1,991 @@
|
||||
# generated.immich.openapi_client.AlbumsApi
|
||||
|
||||
All URIs are relative to *https://github.com/api*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**add_assets_to_album**](AlbumsApi.md#add_assets_to_album) | **PUT** /albums/{id}/assets |
|
||||
[**add_users_to_album**](AlbumsApi.md#add_users_to_album) | **PUT** /albums/{id}/users |
|
||||
[**create_album**](AlbumsApi.md#create_album) | **POST** /albums |
|
||||
[**delete_album**](AlbumsApi.md#delete_album) | **DELETE** /albums/{id} |
|
||||
[**get_album_info**](AlbumsApi.md#get_album_info) | **GET** /albums/{id} |
|
||||
[**get_album_statistics**](AlbumsApi.md#get_album_statistics) | **GET** /albums/statistics |
|
||||
[**get_all_albums**](AlbumsApi.md#get_all_albums) | **GET** /albums |
|
||||
[**remove_asset_from_album**](AlbumsApi.md#remove_asset_from_album) | **DELETE** /albums/{id}/assets |
|
||||
[**remove_user_from_album**](AlbumsApi.md#remove_user_from_album) | **DELETE** /albums/{id}/user/{userId} |
|
||||
[**update_album_info**](AlbumsApi.md#update_album_info) | **PATCH** /albums/{id} |
|
||||
[**update_album_user**](AlbumsApi.md#update_album_user) | **PUT** /albums/{id}/user/{userId} |
|
||||
|
||||
|
||||
# **add_assets_to_album**
|
||||
> List[BulkIdResponseDto] add_assets_to_album(id, bulk_ids_dto, key=key)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.bulk_id_response_dto import BulkIdResponseDto
|
||||
from generated.immich.openapi_client.models.bulk_ids_dto import BulkIdsDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
bulk_ids_dto = generated.immich.openapi_client.BulkIdsDto() # BulkIdsDto |
|
||||
key = 'key_example' # str | (optional)
|
||||
|
||||
try:
|
||||
api_response = api_instance.add_assets_to_album(id, bulk_ids_dto, key=key)
|
||||
print("The response of AlbumsApi->add_assets_to_album:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->add_assets_to_album: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
**bulk_ids_dto** | [**BulkIdsDto**](BulkIdsDto.md)| |
|
||||
**key** | **str**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**List[BulkIdResponseDto]**](BulkIdResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **add_users_to_album**
|
||||
> AlbumResponseDto add_users_to_album(id, add_users_dto)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.add_users_dto import AddUsersDto
|
||||
from generated.immich.openapi_client.models.album_response_dto import AlbumResponseDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
add_users_dto = generated.immich.openapi_client.AddUsersDto() # AddUsersDto |
|
||||
|
||||
try:
|
||||
api_response = api_instance.add_users_to_album(id, add_users_dto)
|
||||
print("The response of AlbumsApi->add_users_to_album:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->add_users_to_album: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
**add_users_dto** | [**AddUsersDto**](AddUsersDto.md)| |
|
||||
|
||||
### Return type
|
||||
|
||||
[**AlbumResponseDto**](AlbumResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **create_album**
|
||||
> AlbumResponseDto create_album(create_album_dto)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.album_response_dto import AlbumResponseDto
|
||||
from generated.immich.openapi_client.models.create_album_dto import CreateAlbumDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
create_album_dto = generated.immich.openapi_client.CreateAlbumDto() # CreateAlbumDto |
|
||||
|
||||
try:
|
||||
api_response = api_instance.create_album(create_album_dto)
|
||||
print("The response of AlbumsApi->create_album:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->create_album: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**create_album_dto** | [**CreateAlbumDto**](CreateAlbumDto.md)| |
|
||||
|
||||
### Return type
|
||||
|
||||
[**AlbumResponseDto**](AlbumResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**201** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **delete_album**
|
||||
> delete_album(id)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
|
||||
try:
|
||||
api_instance.delete_album(id)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->delete_album: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: Not defined
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **get_album_info**
|
||||
> AlbumResponseDto get_album_info(id, key=key, without_assets=without_assets)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.album_response_dto import AlbumResponseDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
key = 'key_example' # str | (optional)
|
||||
without_assets = True # bool | (optional)
|
||||
|
||||
try:
|
||||
api_response = api_instance.get_album_info(id, key=key, without_assets=without_assets)
|
||||
print("The response of AlbumsApi->get_album_info:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->get_album_info: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
**key** | **str**| | [optional]
|
||||
**without_assets** | **bool**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**AlbumResponseDto**](AlbumResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **get_album_statistics**
|
||||
> AlbumStatisticsResponseDto get_album_statistics()
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.album_statistics_response_dto import AlbumStatisticsResponseDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
|
||||
try:
|
||||
api_response = api_instance.get_album_statistics()
|
||||
print("The response of AlbumsApi->get_album_statistics:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->get_album_statistics: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
This endpoint does not need any parameter.
|
||||
|
||||
### Return type
|
||||
|
||||
[**AlbumStatisticsResponseDto**](AlbumStatisticsResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **get_all_albums**
|
||||
> List[AlbumResponseDto] get_all_albums(asset_id=asset_id, shared=shared)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.album_response_dto import AlbumResponseDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
asset_id = 'asset_id_example' # str | Only returns albums that contain the asset Ignores the shared parameter undefined: get all albums (optional)
|
||||
shared = True # bool | (optional)
|
||||
|
||||
try:
|
||||
api_response = api_instance.get_all_albums(asset_id=asset_id, shared=shared)
|
||||
print("The response of AlbumsApi->get_all_albums:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->get_all_albums: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**asset_id** | **str**| Only returns albums that contain the asset Ignores the shared parameter undefined: get all albums | [optional]
|
||||
**shared** | **bool**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**List[AlbumResponseDto]**](AlbumResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **remove_asset_from_album**
|
||||
> List[BulkIdResponseDto] remove_asset_from_album(id, bulk_ids_dto)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.bulk_id_response_dto import BulkIdResponseDto
|
||||
from generated.immich.openapi_client.models.bulk_ids_dto import BulkIdsDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
bulk_ids_dto = generated.immich.openapi_client.BulkIdsDto() # BulkIdsDto |
|
||||
|
||||
try:
|
||||
api_response = api_instance.remove_asset_from_album(id, bulk_ids_dto)
|
||||
print("The response of AlbumsApi->remove_asset_from_album:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->remove_asset_from_album: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
**bulk_ids_dto** | [**BulkIdsDto**](BulkIdsDto.md)| |
|
||||
|
||||
### Return type
|
||||
|
||||
[**List[BulkIdResponseDto]**](BulkIdResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **remove_user_from_album**
|
||||
> remove_user_from_album(id, user_id)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
user_id = 'user_id_example' # str |
|
||||
|
||||
try:
|
||||
api_instance.remove_user_from_album(id, user_id)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->remove_user_from_album: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
**user_id** | **str**| |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: Not defined
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **update_album_info**
|
||||
> AlbumResponseDto update_album_info(id, update_album_dto)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.album_response_dto import AlbumResponseDto
|
||||
from generated.immich.openapi_client.models.update_album_dto import UpdateAlbumDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
update_album_dto = generated.immich.openapi_client.UpdateAlbumDto() # UpdateAlbumDto |
|
||||
|
||||
try:
|
||||
api_response = api_instance.update_album_info(id, update_album_dto)
|
||||
print("The response of AlbumsApi->update_album_info:\n")
|
||||
pprint(api_response)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->update_album_info: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
**update_album_dto** | [**UpdateAlbumDto**](UpdateAlbumDto.md)| |
|
||||
|
||||
### Return type
|
||||
|
||||
[**AlbumResponseDto**](AlbumResponseDto.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
# **update_album_user**
|
||||
> update_album_user(id, user_id, update_album_user_dto)
|
||||
|
||||
### Example
|
||||
|
||||
* Api Key Authentication (cookie):
|
||||
* Api Key Authentication (api_key):
|
||||
* Bearer (JWT) Authentication (bearer):
|
||||
|
||||
```python
|
||||
import generated.immich.openapi_client
|
||||
from generated.immich.openapi_client.models.update_album_user_dto import UpdateAlbumUserDto
|
||||
from generated.immich.openapi_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Defining the host is optional and defaults to https://github.com/api
|
||||
# See configuration.py for a list of all supported configuration parameters.
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
host = "https://github.com/api"
|
||||
)
|
||||
|
||||
# The client must configure the authentication and authorization parameters
|
||||
# in accordance with the API server security policy.
|
||||
# Examples for each auth method are provided below, use the example that
|
||||
# satisfies your auth use case.
|
||||
|
||||
# Configure API key authorization: cookie
|
||||
configuration.api_key['cookie'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['cookie'] = 'Bearer'
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration.api_key['api_key'] = os.environ["API_KEY"]
|
||||
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# Configure Bearer authorization (JWT): bearer
|
||||
configuration = generated.immich.openapi_client.Configuration(
|
||||
access_token = os.environ["BEARER_TOKEN"]
|
||||
)
|
||||
|
||||
# Enter a context with an instance of the API client
|
||||
with generated.immich.openapi_client.ApiClient(configuration) as api_client:
|
||||
# Create an instance of the API class
|
||||
api_instance = generated.immich.openapi_client.AlbumsApi(api_client)
|
||||
id = 'id_example' # str |
|
||||
user_id = 'user_id_example' # str |
|
||||
update_album_user_dto = generated.immich.openapi_client.UpdateAlbumUserDto() # UpdateAlbumUserDto |
|
||||
|
||||
try:
|
||||
api_instance.update_album_user(id, user_id, update_album_user_dto)
|
||||
except Exception as e:
|
||||
print("Exception when calling AlbumsApi->update_album_user: %s\n" % e)
|
||||
```
|
||||
|
||||
|
||||
|
||||
### Parameters
|
||||
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **str**| |
|
||||
**user_id** | **str**| |
|
||||
**update_album_user_dto** | [**UpdateAlbumUserDto**](UpdateAlbumUserDto.md)| |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[cookie](../README.md#cookie), [api_key](../README.md#api_key), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: Not defined
|
||||
|
||||
### HTTP response details
|
||||
|
||||
| Status code | Description | Response headers |
|
||||
|-------------|-------------|------------------|
|
||||
**200** | | - |
|
||||
|
||||
[[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)
|
||||
|
||||
Reference in New Issue
Block a user