katana_public_api_client.api.material.update_material¶
katana_public_api_client.api.material.update_material
¶
Classes¶
Functions¶
asyncio(id, *, client, body)
async
¶
Update a material
Updates the specified material by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
Parameters:
-
id(int) – -
body(UpdateMaterialRequest) –Request payload for updating an existing raw material's properties and specifications Example: {'name': 'Stainless Steel Sheet 304 - Updated', 'uom': 'm²', 'category_name': 'Premium Raw Materials', 'default_supplier_id': 1502, 'additional_info': 'Food-grade stainless steel, 1.5mm thickness - Updated specifications', 'batch_tracked': True, 'is_sellable': False, 'is_archived': False, 'purchase_uom': 'sheet', 'purchase_uom_conversion_rate': 2.0, 'configs': [{'id': 101, 'name': 'Grade', 'values': ['304', '316', '430']}, {'name': 'Finish', 'values': ['Brushed', 'Mirror', 'Matte']}], 'custom_field_collection_id': 201}.
Raises:
-
UnexpectedStatus–If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
-
TimeoutException–If the request takes longer than Client.timeout.
Returns:
-
DetailedErrorResponse | ErrorResponse | Material | None–Union[DetailedErrorResponse, ErrorResponse, Material]
Source code in katana_public_api_client/api/material/update_material.py
asyncio_detailed(id, *, client, body)
async
¶
Update a material
Updates the specified material by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
Parameters:
-
id(int) – -
body(UpdateMaterialRequest) –Request payload for updating an existing raw material's properties and specifications Example: {'name': 'Stainless Steel Sheet 304 - Updated', 'uom': 'm²', 'category_name': 'Premium Raw Materials', 'default_supplier_id': 1502, 'additional_info': 'Food-grade stainless steel, 1.5mm thickness - Updated specifications', 'batch_tracked': True, 'is_sellable': False, 'is_archived': False, 'purchase_uom': 'sheet', 'purchase_uom_conversion_rate': 2.0, 'configs': [{'id': 101, 'name': 'Grade', 'values': ['304', '316', '430']}, {'name': 'Finish', 'values': ['Brushed', 'Mirror', 'Matte']}], 'custom_field_collection_id': 201}.
Raises:
-
UnexpectedStatus–If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
-
TimeoutException–If the request takes longer than Client.timeout.
Returns:
-
Response[DetailedErrorResponse | ErrorResponse | Material]–Response[Union[DetailedErrorResponse, ErrorResponse, Material]]
Source code in katana_public_api_client/api/material/update_material.py
sync(id, *, client, body)
¶
Update a material
Updates the specified material by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
Parameters:
-
id(int) – -
body(UpdateMaterialRequest) –Request payload for updating an existing raw material's properties and specifications Example: {'name': 'Stainless Steel Sheet 304 - Updated', 'uom': 'm²', 'category_name': 'Premium Raw Materials', 'default_supplier_id': 1502, 'additional_info': 'Food-grade stainless steel, 1.5mm thickness - Updated specifications', 'batch_tracked': True, 'is_sellable': False, 'is_archived': False, 'purchase_uom': 'sheet', 'purchase_uom_conversion_rate': 2.0, 'configs': [{'id': 101, 'name': 'Grade', 'values': ['304', '316', '430']}, {'name': 'Finish', 'values': ['Brushed', 'Mirror', 'Matte']}], 'custom_field_collection_id': 201}.
Raises:
-
UnexpectedStatus–If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
-
TimeoutException–If the request takes longer than Client.timeout.
Returns:
-
DetailedErrorResponse | ErrorResponse | Material | None–Union[DetailedErrorResponse, ErrorResponse, Material]
Source code in katana_public_api_client/api/material/update_material.py
sync_detailed(id, *, client, body)
¶
Update a material
Updates the specified material by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
Parameters:
-
id(int) – -
body(UpdateMaterialRequest) –Request payload for updating an existing raw material's properties and specifications Example: {'name': 'Stainless Steel Sheet 304 - Updated', 'uom': 'm²', 'category_name': 'Premium Raw Materials', 'default_supplier_id': 1502, 'additional_info': 'Food-grade stainless steel, 1.5mm thickness - Updated specifications', 'batch_tracked': True, 'is_sellable': False, 'is_archived': False, 'purchase_uom': 'sheet', 'purchase_uom_conversion_rate': 2.0, 'configs': [{'id': 101, 'name': 'Grade', 'values': ['304', '316', '430']}, {'name': 'Finish', 'values': ['Brushed', 'Mirror', 'Matte']}], 'custom_field_collection_id': 201}.
Raises:
-
UnexpectedStatus–If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
-
TimeoutException–If the request takes longer than Client.timeout.
Returns:
-
Response[DetailedErrorResponse | ErrorResponse | Material]–Response[Union[DetailedErrorResponse, ErrorResponse, Material]]