mbu-dev-shared-components 0.0.44__tar.gz → 0.0.45__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mbu_dev_shared_components-0.0.44/mbu_dev_shared_components.egg-info → mbu_dev_shared_components-0.0.45}/PKG-INFO +1 -1
- mbu_dev_shared_components-0.0.45/mbu_dev_shared_components/os2forms/forms.py +40 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45/mbu_dev_shared_components.egg-info}/PKG-INFO +1 -1
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components.egg-info/SOURCES.txt +1 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/.gitignore +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/LICENSE +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/README.md +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/getorganized/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/getorganized/auth.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/getorganized/cases.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/getorganized/contacts.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/getorganized/documents.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/getorganized/objects.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/google/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/google/api/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/google/api/auth.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/google/workspace/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/google/workspace/alerts.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/office365/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/office365/excel/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/office365/excel/excel_reader.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/office365/sharepoint_api/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/office365/sharepoint_api/files.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/os2forms/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/os2forms/documents.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/sap/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/sap/create_invoice.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/utils/__init__.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/utils/db_stored_procedure_executor.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components/utils/json_handler.py +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components.egg-info/dependency_links.txt +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components.egg-info/requires.txt +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/mbu_dev_shared_components.egg-info/top_level.txt +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/pyproject.toml +0 -0
- {mbu_dev_shared_components-0.0.44 → mbu_dev_shared_components-0.0.45}/setup.cfg +0 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"""
|
|
2
|
+
This module provides functions for interacting with the OS2Forms API,
|
|
3
|
+
specifically for fetching form data.
|
|
4
|
+
|
|
5
|
+
Functions:
|
|
6
|
+
get_forms(url: str) -> requests.Response:
|
|
7
|
+
Fetches form data from the OS2Forms API using a specified URL.
|
|
8
|
+
|
|
9
|
+
Dependencies:
|
|
10
|
+
requests: This module requires the 'requests' library to make HTTP requests.
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
import requests
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def get_forms(url: str, os2_api_key) -> requests.Response:
|
|
17
|
+
"""
|
|
18
|
+
Fetches form data from the OS2Forms API.
|
|
19
|
+
|
|
20
|
+
This function sends a GET request to the specified URL and returns the response object.
|
|
21
|
+
It raises an HTTPError if the request returns an unsuccessful status code.
|
|
22
|
+
|
|
23
|
+
Args:
|
|
24
|
+
url (str): The URL for the OS2 form to be fetched.
|
|
25
|
+
|
|
26
|
+
Returns:
|
|
27
|
+
requests.Response: The response object containing the form data.
|
|
28
|
+
|
|
29
|
+
Raises:
|
|
30
|
+
requests.exceptions.HTTPError: If the request returns an unsuccessful status code.
|
|
31
|
+
requests.exceptions.RequestException: For other types of request exceptions.
|
|
32
|
+
"""
|
|
33
|
+
headers = {
|
|
34
|
+
'Content-Type': 'application/json',
|
|
35
|
+
'api-key': f'{os2_api_key}'
|
|
36
|
+
}
|
|
37
|
+
response = requests.get(url=url, headers=headers, timeout=60)
|
|
38
|
+
response.raise_for_status()
|
|
39
|
+
|
|
40
|
+
return response
|
|
@@ -25,6 +25,7 @@ mbu_dev_shared_components/office365/sharepoint_api/__init__.py
|
|
|
25
25
|
mbu_dev_shared_components/office365/sharepoint_api/files.py
|
|
26
26
|
mbu_dev_shared_components/os2forms/__init__.py
|
|
27
27
|
mbu_dev_shared_components/os2forms/documents.py
|
|
28
|
+
mbu_dev_shared_components/os2forms/forms.py
|
|
28
29
|
mbu_dev_shared_components/sap/__init__.py
|
|
29
30
|
mbu_dev_shared_components/sap/create_invoice.py
|
|
30
31
|
mbu_dev_shared_components/utils/__init__.py
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|