# memos.MemoServiceApi All URIs are relative to */* Method | HTTP request | Description ------------- | ------------- | ------------- [**memo_service_create_memo**](MemoServiceApi.md#memo_service_create_memo) | **POST** /api/v2/memos | CreateMemo creates a memo. [**memo_service_create_memo_comment**](MemoServiceApi.md#memo_service_create_memo_comment) | **POST** /api/v2/memos/{id}/comments | CreateMemoComment creates a comment for a memo. [**memo_service_delete_memo**](MemoServiceApi.md#memo_service_delete_memo) | **DELETE** /api/v2/memos/{id} | DeleteMemo deletes a memo by id. [**memo_service_delete_memo_reaction**](MemoServiceApi.md#memo_service_delete_memo_reaction) | **DELETE** /api/v2/memos/{id}/reactions/{reactionId} | DeleteMemoReaction deletes a reaction for a memo. [**memo_service_export_memos**](MemoServiceApi.md#memo_service_export_memos) | **POST** /api/v2/memos:export | ExportMemos exports memos. [**memo_service_get_memo**](MemoServiceApi.md#memo_service_get_memo) | **GET** /api/v2/memos/{id} | GetMemo gets a memo by id. [**memo_service_get_memo_by_name**](MemoServiceApi.md#memo_service_get_memo_by_name) | **GET** /api/v2/memos/name/{name} | GetMemoByName gets a memo by name. [**memo_service_get_user_memos_stats**](MemoServiceApi.md#memo_service_get_user_memos_stats) | **GET** /api/v2/memos/stats | GetUserMemosStats gets stats of memos for a user. [**memo_service_list_memo_comments**](MemoServiceApi.md#memo_service_list_memo_comments) | **GET** /api/v2/memos/{id}/comments | ListMemoComments lists comments for a memo. [**memo_service_list_memo_reactions**](MemoServiceApi.md#memo_service_list_memo_reactions) | **GET** /api/v2/memos/{id}/reactions | ListMemoReactions lists reactions for a memo. [**memo_service_list_memo_relations**](MemoServiceApi.md#memo_service_list_memo_relations) | **GET** /api/v2/memos/{id}/relations | ListMemoRelations lists relations for a memo. [**memo_service_list_memo_resources**](MemoServiceApi.md#memo_service_list_memo_resources) | **GET** /api/v2/memos/{id}/resources | ListMemoResources lists resources for a memo. [**memo_service_list_memos**](MemoServiceApi.md#memo_service_list_memos) | **GET** /api/v2/memos | ListMemos lists memos with pagination and filter. [**memo_service_set_memo_relations**](MemoServiceApi.md#memo_service_set_memo_relations) | **POST** /api/v2/memos/{id}/relations | SetMemoRelations sets relations for a memo. [**memo_service_set_memo_resources**](MemoServiceApi.md#memo_service_set_memo_resources) | **POST** /api/v2/memos/{id}/resources | SetMemoResources sets resources for a memo. [**memo_service_update_memo**](MemoServiceApi.md#memo_service_update_memo) | **PATCH** /api/v2/memos/{memo.id} | UpdateMemo updates a memo. [**memo_service_upsert_memo_reaction**](MemoServiceApi.md#memo_service_upsert_memo_reaction) | **POST** /api/v2/memos/{id}/reactions | UpsertMemoReaction upserts a reaction for a memo. # **memo_service_create_memo** > V2CreateMemoResponse memo_service_create_memo(body) CreateMemo creates a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() body = memos.V2CreateMemoRequest() # V2CreateMemoRequest | try: # CreateMemo creates a memo. api_response = api_instance.memo_service_create_memo(body) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_create_memo: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**V2CreateMemoRequest**](V2CreateMemoRequest.md)| | ### Return type [**V2CreateMemoResponse**](V2CreateMemoResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[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) # **memo_service_create_memo_comment** > V2CreateMemoCommentResponse memo_service_create_memo_comment(id, create_content=create_content, create_visibility=create_visibility) CreateMemoComment creates a comment for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | id is the memo id to create comment for. create_content = 'create_content_example' # str | (optional) create_visibility = 'VISIBILITY_UNSPECIFIED' # str | (optional) (default to VISIBILITY_UNSPECIFIED) try: # CreateMemoComment creates a comment for a memo. api_response = api_instance.memo_service_create_memo_comment(id, create_content=create_content, create_visibility=create_visibility) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_create_memo_comment: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| id is the memo id to create comment for. | **create_content** | **str**| | [optional] **create_visibility** | **str**| | [optional] [default to VISIBILITY_UNSPECIFIED] ### Return type [**V2CreateMemoCommentResponse**](V2CreateMemoCommentResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_delete_memo** > V2DeleteMemoResponse memo_service_delete_memo(id) DeleteMemo deletes a memo by id. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | try: # DeleteMemo deletes a memo by id. api_response = api_instance.memo_service_delete_memo(id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_delete_memo: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | ### Return type [**V2DeleteMemoResponse**](V2DeleteMemoResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_delete_memo_reaction** > V2DeleteMemoReactionResponse memo_service_delete_memo_reaction(id, reaction_id) DeleteMemoReaction deletes a reaction for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | reaction_id = 56 # int | try: # DeleteMemoReaction deletes a reaction for a memo. api_response = api_instance.memo_service_delete_memo_reaction(id, reaction_id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_delete_memo_reaction: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | **reaction_id** | **int**| | ### Return type [**V2DeleteMemoReactionResponse**](V2DeleteMemoReactionResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_export_memos** > V2ExportMemosResponse memo_service_export_memos(filter=filter) ExportMemos exports memos. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() filter = 'filter_example' # str | Same as ListMemosRequest.filter (optional) try: # ExportMemos exports memos. api_response = api_instance.memo_service_export_memos(filter=filter) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_export_memos: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **filter** | **str**| Same as ListMemosRequest.filter | [optional] ### Return type [**V2ExportMemosResponse**](V2ExportMemosResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_get_memo** > V2GetMemoResponse memo_service_get_memo(id) GetMemo gets a memo by id. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | try: # GetMemo gets a memo by id. api_response = api_instance.memo_service_get_memo(id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_get_memo: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | ### Return type [**V2GetMemoResponse**](V2GetMemoResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_get_memo_by_name** > V2GetMemoByNameResponse memo_service_get_memo_by_name(name) GetMemoByName gets a memo by name. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() name = 'name_example' # str | try: # GetMemoByName gets a memo by name. api_response = api_instance.memo_service_get_memo_by_name(name) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_get_memo_by_name: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **name** | **str**| | ### Return type [**V2GetMemoByNameResponse**](V2GetMemoByNameResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_get_user_memos_stats** > V2GetUserMemosStatsResponse memo_service_get_user_memos_stats(name=name, timezone=timezone, filter=filter) GetUserMemosStats gets stats of memos for a user. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() name = 'name_example' # str | name is the name of the user to get stats for. Format: users/{username} (optional) timezone = 'timezone_example' # str | timezone location Format: uses tz identifier https://en.wikipedia.org/wiki/List_of_tz_database_time_zones (optional) filter = 'filter_example' # str | Same as ListMemosRequest.filter (optional) try: # GetUserMemosStats gets stats of memos for a user. api_response = api_instance.memo_service_get_user_memos_stats(name=name, timezone=timezone, filter=filter) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_get_user_memos_stats: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **name** | **str**| name is the name of the user to get stats for. Format: users/{username} | [optional] **timezone** | **str**| timezone location Format: uses tz identifier https://en.wikipedia.org/wiki/List_of_tz_database_time_zones | [optional] **filter** | **str**| Same as ListMemosRequest.filter | [optional] ### Return type [**V2GetUserMemosStatsResponse**](V2GetUserMemosStatsResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_list_memo_comments** > V2ListMemoCommentsResponse memo_service_list_memo_comments(id) ListMemoComments lists comments for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | try: # ListMemoComments lists comments for a memo. api_response = api_instance.memo_service_list_memo_comments(id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_list_memo_comments: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | ### Return type [**V2ListMemoCommentsResponse**](V2ListMemoCommentsResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_list_memo_reactions** > V2ListMemoReactionsResponse memo_service_list_memo_reactions(id) ListMemoReactions lists reactions for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | try: # ListMemoReactions lists reactions for a memo. api_response = api_instance.memo_service_list_memo_reactions(id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_list_memo_reactions: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | ### Return type [**V2ListMemoReactionsResponse**](V2ListMemoReactionsResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_list_memo_relations** > V2ListMemoRelationsResponse memo_service_list_memo_relations(id) ListMemoRelations lists relations for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | try: # ListMemoRelations lists relations for a memo. api_response = api_instance.memo_service_list_memo_relations(id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_list_memo_relations: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | ### Return type [**V2ListMemoRelationsResponse**](V2ListMemoRelationsResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_list_memo_resources** > V2ListMemoResourcesResponse memo_service_list_memo_resources(id) ListMemoResources lists resources for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | try: # ListMemoResources lists resources for a memo. api_response = api_instance.memo_service_list_memo_resources(id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_list_memo_resources: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | ### Return type [**V2ListMemoResourcesResponse**](V2ListMemoResourcesResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_list_memos** > V2ListMemosResponse memo_service_list_memos(page_size=page_size, page_token=page_token, filter=filter) ListMemos lists memos with pagination and filter. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() page_size = 56 # int | The maximum number of memos to return. (optional) page_token = 'page_token_example' # str | A page token, received from a previous `ListMemos` call. Provide this to retrieve the subsequent page. (optional) filter = 'filter_example' # str | Filter is used to filter memos returned in the list. Format: \"creator == users/{username} && visibilities == ['PUBLIC', 'PROTECTED']\" (optional) try: # ListMemos lists memos with pagination and filter. api_response = api_instance.memo_service_list_memos(page_size=page_size, page_token=page_token, filter=filter) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_list_memos: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **page_size** | **int**| The maximum number of memos to return. | [optional] **page_token** | **str**| A page token, received from a previous `ListMemos` call. Provide this to retrieve the subsequent page. | [optional] **filter** | **str**| Filter is used to filter memos returned in the list. Format: \"creator == users/{username} && visibilities == ['PUBLIC', 'PROTECTED']\" | [optional] ### Return type [**V2ListMemosResponse**](V2ListMemosResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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) # **memo_service_set_memo_relations** > V2SetMemoRelationsResponse memo_service_set_memo_relations(body, id) SetMemoRelations sets relations for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() body = memos.MemoServiceSetMemoRelationsBody() # MemoServiceSetMemoRelationsBody | id = 56 # int | try: # SetMemoRelations sets relations for a memo. api_response = api_instance.memo_service_set_memo_relations(body, id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_set_memo_relations: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**MemoServiceSetMemoRelationsBody**](MemoServiceSetMemoRelationsBody.md)| | **id** | **int**| | ### Return type [**V2SetMemoRelationsResponse**](V2SetMemoRelationsResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[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) # **memo_service_set_memo_resources** > V2SetMemoResourcesResponse memo_service_set_memo_resources(body, id) SetMemoResources sets resources for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() body = memos.MemoServiceSetMemoResourcesBody() # MemoServiceSetMemoResourcesBody | id = 56 # int | try: # SetMemoResources sets resources for a memo. api_response = api_instance.memo_service_set_memo_resources(body, id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_set_memo_resources: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**MemoServiceSetMemoResourcesBody**](MemoServiceSetMemoResourcesBody.md)| | **id** | **int**| | ### Return type [**V2SetMemoResourcesResponse**](V2SetMemoResourcesResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[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) # **memo_service_update_memo** > V2UpdateMemoResponse memo_service_update_memo(body, memo_id) UpdateMemo updates a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() body = memos.MemosMemoIdBody() # MemosMemoIdBody | memo_id = 56 # int | id is the system generated unique identifier. try: # UpdateMemo updates a memo. api_response = api_instance.memo_service_update_memo(body, memo_id) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_update_memo: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **body** | [**MemosMemoIdBody**](MemosMemoIdBody.md)| | **memo_id** | **int**| id is the system generated unique identifier. | ### Return type [**V2UpdateMemoResponse**](V2UpdateMemoResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: application/json - **Accept**: application/json [[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) # **memo_service_upsert_memo_reaction** > V2UpsertMemoReactionResponse memo_service_upsert_memo_reaction(id, reaction_id=reaction_id, reaction_creator=reaction_creator, reaction_content_id=reaction_content_id, reaction_reaction_type=reaction_reaction_type) UpsertMemoReaction upserts a reaction for a memo. ### Example ```python from __future__ import print_function import time import memos from memos.rest import ApiException from pprint import pprint # create an instance of the API class api_instance = memos.MemoServiceApi() id = 56 # int | reaction_id = 56 # int | (optional) reaction_creator = 'reaction_creator_example' # str | (optional) reaction_content_id = 'reaction_content_id_example' # str | (optional) reaction_reaction_type = 'TYPE_UNSPECIFIED' # str | (optional) (default to TYPE_UNSPECIFIED) try: # UpsertMemoReaction upserts a reaction for a memo. api_response = api_instance.memo_service_upsert_memo_reaction(id, reaction_id=reaction_id, reaction_creator=reaction_creator, reaction_content_id=reaction_content_id, reaction_reaction_type=reaction_reaction_type) pprint(api_response) except ApiException as e: print("Exception when calling MemoServiceApi->memo_service_upsert_memo_reaction: %s\n" % e) ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **id** | **int**| | **reaction_id** | **int**| | [optional] **reaction_creator** | **str**| | [optional] **reaction_content_id** | **str**| | [optional] **reaction_reaction_type** | **str**| | [optional] [default to TYPE_UNSPECIFIED] ### Return type [**V2UpsertMemoReactionResponse**](V2UpsertMemoReactionResponse.md) ### Authorization No authorization required ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[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)