class ShareLinkPartialSuccessResponse
A class representing a partial success response when creating or managing SharePoint share links, inheriting from ShareLinkResponse.
/tf/active/vicechatdev/SPFCsync/venv/lib64/python3.11/site-packages/office365/sharepoint/sharing/links/partial_success_response.py
4 - 5
simple
Purpose
This class serves as a specialized response type for SharePoint sharing operations that complete with partial success. It extends ShareLinkResponse to handle scenarios where a share link operation succeeds for some items but fails for others. This is commonly used in batch operations or when sharing with multiple recipients where some operations may fail while others succeed.
Source Code
class ShareLinkPartialSuccessResponse(ShareLinkResponse):
""""""
Parameters
| Name | Type | Default | Kind |
|---|---|---|---|
bases |
ShareLinkResponse | - |
Parameter Details
__init__: The constructor parameters are inherited from the parent class ShareLinkResponse. No additional parameters are defined in this class. Typically accepts response data from SharePoint API calls related to share link operations.
Return Value
Instantiation returns a ShareLinkPartialSuccessResponse object that represents a partial success state for share link operations. Methods inherited from ShareLinkResponse will return various data types depending on the specific method called, typically including link information, success/failure details, and error messages for failed operations.
Class Interface
Dependencies
office365
Required Imports
from office365.sharepoint.sharing.links.share_link_partial_success_response import ShareLinkPartialSuccessResponse
Usage Example
from office365.sharepoint.client_context import ClientContext
from office365.sharepoint.sharing.links.share_link_partial_success_response import ShareLinkPartialSuccessResponse
# Assuming you have a ClientContext set up
ctx = ClientContext(site_url).with_credentials(credentials)
# This class is typically returned by SharePoint API operations
# Example: After attempting to share a document with multiple users
response = ShareLinkPartialSuccessResponse()
# The response would contain information about which operations succeeded
# and which failed, inherited from ShareLinkResponse
# Access response properties (inherited from parent)
if hasattr(response, 'error_message'):
print(f"Partial success with errors: {response.error_message}")
Best Practices
- This class is typically instantiated by the Office365 library internally when processing SharePoint API responses, not directly by user code
- Check for both successful and failed operations when handling partial success responses
- Always verify the response status before attempting to access link information
- Use this class to handle graceful degradation in batch sharing operations
- Inherit from this class if you need to extend partial success handling with custom logic
- The empty class body indicates this is primarily a marker class for type differentiation from full success or full failure responses
Tags
Similar Components
AI-powered semantic similarity - components with related functionality:
-
class ShareLinkResponse 76.6% similar
-
class ShareLinkRequest 67.5% similar
-
class SharingLinkAccessRequest 63.5% similar
-
class SharingLinkAbilities 61.4% similar
-
class Link 60.3% similar