Skip to content

Commit 39a72bd

Browse files
New storage search feature (#10)
* updated python sdk to include the new mcode-sdk-api capabilities - specifically storage.search * updated python sdk to include the new mcode-sdk-api capabilities - specifically storage.search
1 parent 94a0b56 commit 39a72bd

File tree

10 files changed

+525
-4
lines changed

10 files changed

+525
-4
lines changed

.github/workflows/python.yml

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# NOTE: This file is auto generated by OpenAPI Generator.
2+
# URL: https://openapi-generator.tech
3+
#
4+
# ref: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
5+
6+
name: monday_code Python package
7+
8+
on: [push, pull_request]
9+
10+
jobs:
11+
build:
12+
13+
runs-on: ubuntu-latest
14+
strategy:
15+
matrix:
16+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
17+
18+
steps:
19+
- uses: actions/checkout@v4
20+
- name: Set up Python ${{ matrix.python-version }}
21+
uses: actions/setup-python@v4
22+
with:
23+
python-version: ${{ matrix.python-version }}
24+
- name: Install dependencies
25+
run: |
26+
python -m pip install --upgrade pip
27+
pip install -r requirements.txt
28+
pip install -r test-requirements.txt
29+
- name: Test with pytest
30+
run: |
31+
pytest --cov={{packageName}}

.openapi-generator/FILES

+98
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
.github/workflows/python.yml
2+
.gitignore
3+
.gitlab-ci.yml
4+
.openapi-generator-ignore
5+
.travis.yml
6+
README.md
7+
docs/EnvironmentVariablesApi.md
8+
docs/GetByKeyFromStorage404Response.md
9+
docs/GetByKeyFromStorage500Response.md
10+
docs/IncrementCounter200Response.md
11+
docs/IncrementCounter200ResponseAnyOf.md
12+
docs/IncrementCounter200ResponseAnyOf1.md
13+
docs/IncrementCounterParams.md
14+
docs/JsonDataContract.md
15+
docs/LogMethods.md
16+
docs/LogsApi.md
17+
docs/Period.md
18+
docs/PublishMessageParams.md
19+
docs/PublishMessageResponse.md
20+
docs/QueueApi.md
21+
docs/SecretsApi.md
22+
docs/SecureStorageApi.md
23+
docs/StorageApi.md
24+
docs/StorageDataContract.md
25+
docs/UpsertByKeyFromStorage200Response.md
26+
docs/UpsertByKeyFromStorage200ResponseAnyOf.md
27+
docs/UpsertByKeyFromStorage200ResponseAnyOf1.md
28+
docs/ValidateSecretParams.md
29+
docs/ValidateSecretResponse.md
30+
docs/WriteLogRequestBody.md
31+
docs/WriteLogRequestBodyError.md
32+
git_push.sh
33+
monday_code/__init__.py
34+
monday_code/api/__init__.py
35+
monday_code/api/environment_variables_api.py
36+
monday_code/api/logs_api.py
37+
monday_code/api/queue_api.py
38+
monday_code/api/secrets_api.py
39+
monday_code/api/secure_storage_api.py
40+
monday_code/api/storage_api.py
41+
monday_code/api_client.py
42+
monday_code/api_response.py
43+
monday_code/configuration.py
44+
monday_code/exceptions.py
45+
monday_code/models/__init__.py
46+
monday_code/models/get_by_key_from_storage404_response.py
47+
monday_code/models/get_by_key_from_storage500_response.py
48+
monday_code/models/increment_counter200_response.py
49+
monday_code/models/increment_counter200_response_any_of.py
50+
monday_code/models/increment_counter200_response_any_of1.py
51+
monday_code/models/increment_counter_params.py
52+
monday_code/models/json_data_contract.py
53+
monday_code/models/log_methods.py
54+
monday_code/models/period.py
55+
monday_code/models/publish_message_params.py
56+
monday_code/models/publish_message_response.py
57+
monday_code/models/storage_data_contract.py
58+
monday_code/models/upsert_by_key_from_storage200_response.py
59+
monday_code/models/upsert_by_key_from_storage200_response_any_of.py
60+
monday_code/models/upsert_by_key_from_storage200_response_any_of1.py
61+
monday_code/models/validate_secret_params.py
62+
monday_code/models/validate_secret_response.py
63+
monday_code/models/write_log_request_body.py
64+
monday_code/models/write_log_request_body_error.py
65+
monday_code/py.typed
66+
monday_code/rest.py
67+
pyproject.toml
68+
requirements.txt
69+
setup.cfg
70+
setup.py
71+
test-requirements.txt
72+
test/__init__.py
73+
test/test_environment_variables_api.py
74+
test/test_get_by_key_from_storage404_response.py
75+
test/test_get_by_key_from_storage500_response.py
76+
test/test_increment_counter200_response.py
77+
test/test_increment_counter200_response_any_of.py
78+
test/test_increment_counter200_response_any_of1.py
79+
test/test_increment_counter_params.py
80+
test/test_json_data_contract.py
81+
test/test_log_methods.py
82+
test/test_logs_api.py
83+
test/test_period.py
84+
test/test_publish_message_params.py
85+
test/test_publish_message_response.py
86+
test/test_queue_api.py
87+
test/test_secrets_api.py
88+
test/test_secure_storage_api.py
89+
test/test_storage_api.py
90+
test/test_storage_data_contract.py
91+
test/test_upsert_by_key_from_storage200_response.py
92+
test/test_upsert_by_key_from_storage200_response_any_of.py
93+
test/test_upsert_by_key_from_storage200_response_any_of1.py
94+
test/test_validate_secret_params.py
95+
test/test_validate_secret_response.py
96+
test/test_write_log_request_body.py
97+
test/test_write_log_request_body_error.py
98+
tox.ini

.openapi-generator/VERSION

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
7.11.0-SNAPSHOT

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ Class | Method | HTTP request | Description
5757
*StorageApi* | [**delete_by_key_from_storage**](docs/StorageApi.md#delete_by_key_from_storage) | **DELETE** /storage/{key} |
5858
*StorageApi* | [**get_by_key_from_storage**](docs/StorageApi.md#get_by_key_from_storage) | **GET** /storage/{key} |
5959
*StorageApi* | [**increment_counter**](docs/StorageApi.md#increment_counter) | **PUT** /storage/counter/increment |
60+
*StorageApi* | [**search_record**](docs/StorageApi.md#search_record) | **GET** /storage/search/{term} |
6061
*StorageApi* | [**upsert_by_key_from_storage**](docs/StorageApi.md#upsert_by_key_from_storage) | **PUT** /storage/{key} |
6162

6263

docs/StorageApi.md

+71
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Method | HTTP request | Description
77
[**delete_by_key_from_storage**](StorageApi.md#delete_by_key_from_storage) | **DELETE** /storage/{key} |
88
[**get_by_key_from_storage**](StorageApi.md#get_by_key_from_storage) | **GET** /storage/{key} |
99
[**increment_counter**](StorageApi.md#increment_counter) | **PUT** /storage/counter/increment |
10+
[**search_record**](StorageApi.md#search_record) | **GET** /storage/search/{term} |
1011
[**upsert_by_key_from_storage**](StorageApi.md#upsert_by_key_from_storage) | **PUT** /storage/{key} |
1112

1213

@@ -213,6 +214,76 @@ No authorization required
213214

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

217+
# **search_record**
218+
> object search_record(term, x_monday_access_token, cursor=cursor)
219+
220+
221+
222+
### Example
223+
224+
225+
```python
226+
import monday_code
227+
from monday_code.rest import ApiException
228+
from pprint import pprint
229+
230+
# Defining the host is optional and defaults to http://localhost:59999
231+
# See configuration.py for a list of all supported configuration parameters.
232+
configuration = monday_code.Configuration(
233+
host = "http://localhost:59999"
234+
)
235+
236+
237+
# Enter a context with an instance of the API client
238+
with monday_code.ApiClient(configuration) as api_client:
239+
# Create an instance of the API class
240+
api_instance = monday_code.StorageApi(api_client)
241+
term = 'term_example' # str |
242+
x_monday_access_token = 'x_monday_access_token_example' # str |
243+
cursor = 'cursor_example' # str | (optional)
244+
245+
try:
246+
api_response = api_instance.search_record(term, x_monday_access_token, cursor=cursor)
247+
print("The response of StorageApi->search_record:\n")
248+
pprint(api_response)
249+
except Exception as e:
250+
print("Exception when calling StorageApi->search_record: %s\n" % e)
251+
```
252+
253+
254+
255+
### Parameters
256+
257+
258+
Name | Type | Description | Notes
259+
------------- | ------------- | ------------- | -------------
260+
**term** | **str**| |
261+
**x_monday_access_token** | **str**| |
262+
**cursor** | **str**| | [optional]
263+
264+
### Return type
265+
266+
**object**
267+
268+
### Authorization
269+
270+
No authorization required
271+
272+
### HTTP request headers
273+
274+
- **Content-Type**: Not defined
275+
- **Accept**: application/json
276+
277+
### HTTP response details
278+
279+
| Status code | Description | Response headers |
280+
|-------------|-------------|------------------|
281+
**200** | OK | - |
282+
**404** | | - |
283+
**500** | | - |
284+
285+
[[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)
286+
216287
# **upsert_by_key_from_storage**
217288
> UpsertByKeyFromStorage200Response upsert_by_key_from_storage(key, x_monday_access_token, json_data_contract, shared=shared, previous_version=previous_version)
218289

0 commit comments

Comments
 (0)