Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New storage search feature #10

Merged
merged 2 commits into from
Dec 17, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# NOTE: This file is auto generated by OpenAPI Generator.
# URL: https://openapi-generator.tech
#
# ref: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python

name: monday_code Python package

on: [push, pull_request]

jobs:
build:

runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r test-requirements.txt
- name: Test with pytest
run: |
pytest --cov={{packageName}}
7 changes: 0 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,3 @@ target/

#Ipython Notebook
.ipynb_checkpoints

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
.idea/
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

return it

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

31 changes: 31 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# NOTE: This file is auto generated by OpenAPI Generator.
# URL: https://openapi-generator.tech
#
# ref: https://docs.gitlab.com/ee/ci/README.html
# ref: https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Python.gitlab-ci.yml

stages:
- test

.pytest:
stage: test
script:
- pip install -r requirements.txt
- pip install -r test-requirements.txt
- pytest --cov=monday_code

pytest-3.8:
extends: .pytest
image: python:3.8-alpine
pytest-3.9:
extends: .pytest
image: python:3.9-alpine
pytest-3.10:
extends: .pytest
image: python:3.10-alpine
pytest-3.11:
extends: .pytest
image: python:3.11-alpine
pytest-3.12:
extends: .pytest
image: python:3.12-alpine
98 changes: 98 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
.github/workflows/python.yml
.gitignore
.gitlab-ci.yml
.openapi-generator-ignore
.travis.yml
README.md
docs/EnvironmentVariablesApi.md
docs/GetByKeyFromStorage404Response.md
docs/GetByKeyFromStorage500Response.md
docs/IncrementCounter200Response.md
docs/IncrementCounter200ResponseAnyOf.md
docs/IncrementCounter200ResponseAnyOf1.md
docs/IncrementCounterParams.md
docs/JsonDataContract.md
docs/LogMethods.md
docs/LogsApi.md
docs/Period.md
docs/PublishMessageParams.md
docs/PublishMessageResponse.md
docs/QueueApi.md
docs/SecretsApi.md
docs/SecureStorageApi.md
docs/StorageApi.md
docs/StorageDataContract.md
docs/UpsertByKeyFromStorage200Response.md
docs/UpsertByKeyFromStorage200ResponseAnyOf.md
docs/UpsertByKeyFromStorage200ResponseAnyOf1.md
docs/ValidateSecretParams.md
docs/ValidateSecretResponse.md
docs/WriteLogRequestBody.md
docs/WriteLogRequestBodyError.md
git_push.sh
monday_code/__init__.py
monday_code/api/__init__.py
monday_code/api/environment_variables_api.py
monday_code/api/logs_api.py
monday_code/api/queue_api.py
monday_code/api/secrets_api.py
monday_code/api/secure_storage_api.py
monday_code/api/storage_api.py
monday_code/api_client.py
monday_code/api_response.py
monday_code/configuration.py
monday_code/exceptions.py
monday_code/models/__init__.py
monday_code/models/get_by_key_from_storage404_response.py
monday_code/models/get_by_key_from_storage500_response.py
monday_code/models/increment_counter200_response.py
monday_code/models/increment_counter200_response_any_of.py
monday_code/models/increment_counter200_response_any_of1.py
monday_code/models/increment_counter_params.py
monday_code/models/json_data_contract.py
monday_code/models/log_methods.py
monday_code/models/period.py
monday_code/models/publish_message_params.py
monday_code/models/publish_message_response.py
monday_code/models/storage_data_contract.py
monday_code/models/upsert_by_key_from_storage200_response.py
monday_code/models/upsert_by_key_from_storage200_response_any_of.py
monday_code/models/upsert_by_key_from_storage200_response_any_of1.py
monday_code/models/validate_secret_params.py
monday_code/models/validate_secret_response.py
monday_code/models/write_log_request_body.py
monday_code/models/write_log_request_body_error.py
monday_code/py.typed
monday_code/rest.py
pyproject.toml
requirements.txt
setup.cfg
setup.py
test-requirements.txt
test/__init__.py
test/test_environment_variables_api.py
test/test_get_by_key_from_storage404_response.py
test/test_get_by_key_from_storage500_response.py
test/test_increment_counter200_response.py
test/test_increment_counter200_response_any_of.py
test/test_increment_counter200_response_any_of1.py
test/test_increment_counter_params.py
test/test_json_data_contract.py
test/test_log_methods.py
test/test_logs_api.py
test/test_period.py
test/test_publish_message_params.py
test/test_publish_message_response.py
test/test_queue_api.py
test/test_secrets_api.py
test/test_secure_storage_api.py
test/test_storage_api.py
test/test_storage_data_contract.py
test/test_upsert_by_key_from_storage200_response.py
test/test_upsert_by_key_from_storage200_response_any_of.py
test/test_upsert_by_key_from_storage200_response_any_of1.py
test/test_validate_secret_params.py
test/test_validate_secret_response.py
test/test_write_log_request_body.py
test/test_write_log_request_body_error.py
tox.ini
1 change: 1 addition & 0 deletions .openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
7.11.0-SNAPSHOT
17 changes: 17 additions & 0 deletions .travis.yml
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

delete

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# ref: https://docs.travis-ci.com/user/languages/python
language: python
python:
- "3.8"
- "3.9"
- "3.10"
- "3.11"
- "3.12"
# uncomment the following if needed
#- "3.12-dev" # 3.12 development branch
#- "nightly" # nightly build
# command to install dependencies
install:
- "pip install -r requirements.txt"
- "pip install -r test-requirements.txt"
# command to run tests
script: pytest --cov=monday_code
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ Class | Method | HTTP request | Description
*StorageApi* | [**delete_by_key_from_storage**](docs/StorageApi.md#delete_by_key_from_storage) | **DELETE** /storage/{key} |
*StorageApi* | [**get_by_key_from_storage**](docs/StorageApi.md#get_by_key_from_storage) | **GET** /storage/{key} |
*StorageApi* | [**increment_counter**](docs/StorageApi.md#increment_counter) | **PUT** /storage/counter/increment |
*StorageApi* | [**search_record**](docs/StorageApi.md#search_record) | **GET** /storage/search/{term} |
*StorageApi* | [**upsert_by_key_from_storage**](docs/StorageApi.md#upsert_by_key_from_storage) | **PUT** /storage/{key} |


Expand Down
71 changes: 71 additions & 0 deletions docs/StorageApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Method | HTTP request | Description
[**delete_by_key_from_storage**](StorageApi.md#delete_by_key_from_storage) | **DELETE** /storage/{key} |
[**get_by_key_from_storage**](StorageApi.md#get_by_key_from_storage) | **GET** /storage/{key} |
[**increment_counter**](StorageApi.md#increment_counter) | **PUT** /storage/counter/increment |
[**search_record**](StorageApi.md#search_record) | **GET** /storage/search/{term} |
[**upsert_by_key_from_storage**](StorageApi.md#upsert_by_key_from_storage) | **PUT** /storage/{key} |


Expand Down Expand Up @@ -213,6 +214,76 @@ No authorization required

[[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)

# **search_record**
> object search_record(term, x_monday_access_token, cursor=cursor)



### Example


```python
import monday_code
from monday_code.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to http://localhost:59999
# See configuration.py for a list of all supported configuration parameters.
configuration = monday_code.Configuration(
host = "http://localhost:59999"
)


# Enter a context with an instance of the API client
with monday_code.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = monday_code.StorageApi(api_client)
term = 'term_example' # str |
x_monday_access_token = 'x_monday_access_token_example' # str |
cursor = 'cursor_example' # str | (optional)

try:
api_response = api_instance.search_record(term, x_monday_access_token, cursor=cursor)
print("The response of StorageApi->search_record:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling StorageApi->search_record: %s\n" % e)
```



### Parameters


Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**term** | **str**| |
**x_monday_access_token** | **str**| |
**cursor** | **str**| | [optional]

### Return type

**object**

### Authorization

No authorization required

### HTTP request headers

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

### HTTP response details

| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | OK | - |
**404** | | - |
**500** | | - |

[[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)

# **upsert_by_key_from_storage**
> UpsertByKeyFromStorage200Response upsert_by_key_from_storage(key, x_monday_access_token, json_data_contract, shared=shared, previous_version=previous_version)

Expand Down
Loading
Loading