class SharingInformationRequest
A class representing the optional Request Object for GetSharingInformation operations in SharePoint Online.
/tf/active/vicechatdev/SPFCsync/venv/lib64/python3.11/site-packages/office365/sharepoint/sharing/information_request.py
4 - 9
simple
Purpose
This class serves as a data transfer object (DTO) for SharePoint sharing information requests. It inherits from ClientValue and provides the entity type name required for SharePoint REST API operations related to sharing information retrieval. The class is used to encapsulate request parameters when querying sharing details for SharePoint resources.
Source Code
class SharingInformationRequest(ClientValue):
"""Represents the optional Request Object for GetSharingInformation."""
@property
def entity_type_name(self):
return "SP.Sharing.SharingInformationRequest"
Parameters
| Name | Type | Default | Kind |
|---|---|---|---|
bases |
ClientValue | - |
Parameter Details
__init__: Inherits constructor from ClientValue base class. No explicit constructor parameters are defined in this class. The parent ClientValue class handles initialization.
Return Value
Instantiation returns a SharingInformationRequest object that can be used as a request parameter for SharePoint sharing information operations. The entity_type_name property returns the string 'SP.Sharing.SharingInformationRequest' which identifies this object type in SharePoint's REST API.
Class Interface
Methods
@property entity_type_name(self) -> str
property
Purpose: Returns the SharePoint entity type name identifier for this request object
Returns: String 'SP.Sharing.SharingInformationRequest' which identifies this object type in SharePoint's REST API
Attributes
| Name | Type | Description | Scope |
|---|---|---|---|
entity_type_name |
str | Read-only property that returns the SharePoint entity type identifier 'SP.Sharing.SharingInformationRequest' | instance |
Dependencies
office365
Required Imports
from office365.runtime.client_value import ClientValue
from office365.sharepoint.sharing.information_request import SharingInformationRequest
Usage Example
from office365.sharepoint.sharing.information_request import SharingInformationRequest
from office365.sharepoint.client_context import ClientContext
# Create a SharePoint context (credentials required)
ctx = ClientContext(site_url).with_credentials(credentials)
# Instantiate the sharing information request
sharing_request = SharingInformationRequest()
# The entity_type_name property is used internally by the API
entity_type = sharing_request.entity_type_name
print(entity_type) # Output: SP.Sharing.SharingInformationRequest
# Typically used with GetSharingInformation API calls
# sharing_info = some_sharepoint_object.get_sharing_information(sharing_request)
# ctx.execute_query()
Best Practices
- This class is primarily used as a parameter object for SharePoint sharing operations and should not be modified directly
- The entity_type_name property is read-only and used internally by the Office365 REST API client
- Instantiate this class when you need to pass a request object to GetSharingInformation or related SharePoint sharing methods
- This class follows the ClientValue pattern used throughout the Office365-REST-Python-Client library
- No explicit cleanup or disposal is required as this is a simple data object
- The class is stateless and can be reused across multiple API calls
Similar Components
AI-powered semantic similarity - components with related functionality:
-
class ShareLinkRequest 76.7% similar
-
class DirectSharingAbilities 73.1% similar
-
class ShareLinkResponse 72.9% similar
-
class SharingInformation 72.2% similar
-
class ObjectSharingInformation 71.1% similar