Skip to content

Commit

Permalink
PATCH: fix project-access-token nullable fields
Browse files Browse the repository at this point in the history
  • Loading branch information
Bimdata-io committed Jul 30, 2024
1 parent 69bdbd8 commit 7277533
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 20 deletions.
2 changes: 1 addition & 1 deletion bimdata_api_client/api/collaboration_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -8859,7 +8859,7 @@ def create_document(
):
"""Create a document # noqa: E501

Create a document. If the document is one of {'OBJ', 'IFC', 'DXF', 'GLTF', 'DWG', 'POINT_CLOUD'}, a model will be created and attached to this document Required scopes: document:write # noqa: E501
Create a document. If the document is one of {'DWG', 'OBJ', 'DXF', 'POINT_CLOUD', 'IFC', 'GLTF'}, a model will be created and attached to this document Required scopes: document:write # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

Expand Down
20 changes: 11 additions & 9 deletions bimdata_api_client/model/check_project_access.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,11 @@ class CheckProjectAccess(ModelNormal):

allowed_values = {
('user_role',): {
'100': 100,
'50': 50,
'25': 25,
'None': None,
'100': "100",
'50': "50",
'25': "25",
'NULL': "null",
},
}

Expand Down Expand Up @@ -98,8 +100,8 @@ def openapi_types():
'has_admin_permission': (bool,), # noqa: E501
'token_scopes': ([str],), # noqa: E501
'usable_scopes': ([str],), # noqa: E501
'user_role': (int,), # noqa: E501
'user': (User,), # noqa: E501
'user_role': (int, none_type,), # noqa: E501
'user': (bool, date, datetime, dict, float, int, list, str, none_type,), # noqa: E501
}

@cached_property
Expand Down Expand Up @@ -165,8 +167,8 @@ def _from_openapi_data(cls, has_read_permission, has_write_permission, has_admin
Animal class but this time we won't travel
through its discriminator because we passed in
_visited_composed_classes = (Animal,)
user_role (int): * `100` - admin * `50` - user * `25` - guest. [optional] # noqa: E501
user (User): [optional] # noqa: E501
user_role (int, none_type): * `100` - admin * `50` - user * `25` - guest. [optional] # noqa: E501
user (bool, date, datetime, dict, float, int, list, str, none_type): [optional] # noqa: E501
"""

_check_type = kwargs.pop('_check_type', True)
Expand Down Expand Up @@ -260,8 +262,8 @@ def __init__(self, has_read_permission, has_write_permission, has_admin_permissi
Animal class but this time we won't travel
through its discriminator because we passed in
_visited_composed_classes = (Animal,)
user_role (int): * `100` - admin * `50` - user * `25` - guest. [optional] # noqa: E501
user (User): [optional] # noqa: E501
user_role (int, none_type): * `100` - admin * `50` - user * `25` - guest. [optional] # noqa: E501
user (bool, date, datetime, dict, float, int, list, str, none_type): [optional] # noqa: E501
"""

_check_type = kwargs.pop('_check_type', True)
Expand Down
8 changes: 4 additions & 4 deletions bimdata_api_client/model/write_folder_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ def openapi_types():
"""
return {
'name': (str,), # noqa: E501
'parent_id': (int, none_type,), # noqa: E501
'default_permission': (int,), # noqa: E501
'parent_id': (int, none_type,), # noqa: E501
'children': ([WriteFolderRequest], none_type,), # noqa: E501
}

Expand All @@ -108,8 +108,8 @@ def discriminator():

attribute_map = {
'name': 'name', # noqa: E501
'parent_id': 'parent_id', # noqa: E501
'default_permission': 'default_permission', # noqa: E501
'parent_id': 'parent_id', # noqa: E501
'children': 'children', # noqa: E501
}

Expand Down Expand Up @@ -157,8 +157,8 @@ def _from_openapi_data(cls, name, *args, **kwargs): # noqa: E501
Animal class but this time we won't travel
through its discriminator because we passed in
_visited_composed_classes = (Animal,)
parent_id (int, none_type): [optional] # noqa: E501
default_permission (int): Permission for a Folder * `1` - denied * `50` - read_only * `100` - read_write. [optional] # noqa: E501
parent_id (int, none_type): [optional] # noqa: E501
children ([WriteFolderRequest], none_type): [optional] # noqa: E501
"""

Expand Down Expand Up @@ -245,8 +245,8 @@ def __init__(self, name, *args, **kwargs): # noqa: E501
Animal class but this time we won't travel
through its discriminator because we passed in
_visited_composed_classes = (Animal,)
parent_id (int, none_type): [optional] # noqa: E501
default_permission (int): Permission for a Folder * `1` - denied * `50` - read_only * `100` - read_write. [optional] # noqa: E501
parent_id (int, none_type): [optional] # noqa: E501
children ([WriteFolderRequest], none_type): [optional] # noqa: E501
"""

Expand Down
4 changes: 2 additions & 2 deletions docs/CheckProjectAccess.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ Name | Type | Description | Notes
**has_admin_permission** | **bool** | |
**token_scopes** | **[str]** | |
**usable_scopes** | **[str]** | Some tokens may have write scopes (eg: model:write) but the user of the token is a guest in the project so they can't use the scopes. |
**user_role** | **int** | * `100` - admin * `50` - user * `25` - guest | [optional]
**user** | [**User**](User.md) | | [optional]
**user_role** | **int, none_type** | * `100` - admin * `50` - user * `25` - guest | [optional]
**user** | **bool, date, datetime, dict, float, int, list, str, none_type** | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
Expand Down
6 changes: 3 additions & 3 deletions docs/CollaborationApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -1482,9 +1482,9 @@ with bimdata_api_client.ApiClient(configuration) as api_client:
id = 1 # int | A unique integer value identifying this project.
write_folder_request = [
WriteFolderRequest(
parent_id=1,
name="name_example",
default_permission=1,
name="name_example",
parent_id=1,
children=[
WriteFolderRequest(),
],
Expand Down Expand Up @@ -1541,7 +1541,7 @@ Name | Type | Description | Notes
Create a document

Create a document. If the document is one of {'OBJ', 'IFC', 'DXF', 'GLTF', 'DWG', 'POINT_CLOUD'}, a model will be created and attached to this document Required scopes: document:write
Create a document. If the document is one of {'DWG', 'OBJ', 'DXF', 'POINT_CLOUD', 'IFC', 'GLTF'}, a model will be created and attached to this document Required scopes: document:write

### Example

Expand Down
2 changes: 1 addition & 1 deletion docs/WriteFolderRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | Name of the folder |
**parent_id** | **int, none_type** | | [optional]
**default_permission** | **int** | Permission for a Folder * `1` - denied * `50` - read_only * `100` - read_write | [optional]
**parent_id** | **int, none_type** | | [optional]
**children** | [**[WriteFolderRequest], none_type**](WriteFolderRequest.md) | | [optional]
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

Expand Down

0 comments on commit 7277533

Please sign in to comment.