Skip to content

Commit

Permalink
rm all core rest documentation links (#364)
Browse files Browse the repository at this point in the history
* rm all core rest documentation links

* put back support doc link

* use cloud doc for restore troubleshooting link

* move ffs query doc link to dev portal
  • Loading branch information
timabrmsn committed Sep 7, 2021
1 parent 4846a91 commit 0d0a472
Show file tree
Hide file tree
Showing 9 changed files with 3 additions and 66 deletions.
8 changes: 1 addition & 7 deletions src/py42/clients/archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ def __init__(self, archive_accessor_factory, archive_service):

def get_by_archive_guid(self, archive_guid):
"""Gets single archive information by GUID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Archive-get>`__
Args:
archive_guid (str): The GUID for the archive.
Expand All @@ -30,7 +29,6 @@ def get_by_archive_guid(self, archive_guid):

def get_all_by_device_guid(self, device_guid):
"""Gets archive information for a device.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Archive-get>`__
Args:
device_guid (str): The GUID for the device.
Expand All @@ -56,7 +54,7 @@ def stream_from_backup(
"""Streams a file from a backup archive to memory. This method uses the same endpoint
as restoring from Console and therefore has all the same considerations.
`Support Documentation <https://support.code42.com/Administrator/6/Monitoring_and_managing/Restore_files_from_the_Code42_console#Troubleshooting>`__
`Support Documentation <https://support.code42.com/Administrator/Cloud/Monitoring_and_managing/Restore_files_from_the_Code42_console#Troubleshooting>`__
Args:
file_paths (str or list of str): The path or list of paths to the files or directories in
Expand Down Expand Up @@ -214,7 +212,6 @@ def get_backup_sets(self, device_guid, destination_guid):

def get_all_org_restore_history(self, days, org_id):
"""Gets all restore jobs from the past given days for the organization with the given ID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#RestoreHistory-get>`__
Args:
days (int): Number of days of restore history to retrieve.
Expand All @@ -228,7 +225,6 @@ def get_all_org_restore_history(self, days, org_id):

def get_all_user_restore_history(self, days, user_id):
"""Gets all restore jobs from the past given days for the user with the given ID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#RestoreHistory-get>`__
Args:
days (int): Number of days of restore history to retrieve.
Expand All @@ -242,7 +238,6 @@ def get_all_user_restore_history(self, days, user_id):

def get_all_device_restore_history(self, days, device_id):
"""Gets all restore jobs from the past given days for the device with the given ID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#RestoreHistory-get>`__
Args:
days (int): Number of days of restore history to retrieve.
Expand All @@ -258,7 +253,6 @@ def get_all_device_restore_history(self, days, device_id):

def update_cold_storage_purge_date(self, archive_guid, purge_date):
"""Updates the cold storage purge date for a specified archive.
`REST Documentation <https://console.us.code42.com/apidocviewer/#ColdStorage-put>`__
Args:
archive_guid (str): The identification number of the archive that should be updated
Expand Down
2 changes: 0 additions & 2 deletions src/py42/clients/loginconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ def get_for_user(self, username):
`LOCAL`, `LOCAL_2FA`, and `CLOUD_SSO`. If username does not exist the default
return value is `LOCAL_2FA`.
`REST Documentation: <https://console.us.code42.com/swagger/index.html?urls.primaryName=v3#/Feature/get>`__
Args:
username (str): Username to retrieve login configuration for.
Expand Down
3 changes: 0 additions & 3 deletions src/py42/services/archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ def get_data_key_token(self, device_guid):

def get_single_archive(self, archive_guid):
"""Gets single archive information by GUID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Archive-get>`__
Args:
archive_guid (str): The GUID for the archive.
Expand All @@ -24,7 +23,6 @@ def get_single_archive(self, archive_guid):

def get_page(self, page_num, page_size=None, **kwargs):
"""Gets an individual page of archives.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Archive-get>`__
Args:
page_num (int): The page number to request.
Expand All @@ -40,7 +38,6 @@ def get_page(self, page_num, page_size=None, **kwargs):

def get_all_archives_from_value(self, id_value, id_type):
"""Gets archive information from an ID, such as a User UID, Device GUID, or Destination GUID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Archive-get>`__
Args:
id_value (str): Query value for archive.
Expand Down
11 changes: 0 additions & 11 deletions src/py42/services/devices.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ def get_page(
q=None,
):
"""Gets a page of devices.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Computer-get>`__
Args:
page_num (int): The page number to request.
Expand Down Expand Up @@ -90,7 +89,6 @@ def get_all(
When no arguments are passed, all records are returned. To filter results, specify
respective arguments. For example, to retrieve all active and blocked devices, pass
active=true and blocked=true.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Computer-get>`__
Args:
active (bool, optional): Filters results by device state. When set to True, gets all
Expand Down Expand Up @@ -133,7 +131,6 @@ def get_all(

def get_by_id(self, device_id, include_backup_usage=None, **kwargs):
"""Gets device information by ID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Computer-get>`__
Args:
device_id (int): The identification number of the device.
Expand All @@ -149,7 +146,6 @@ def get_by_id(self, device_id, include_backup_usage=None, **kwargs):

def get_by_guid(self, guid, include_backup_usage=None, **kwargs):
"""Gets device information by GUID.
`REST Documentation <https://console.us.code42.com/apidocviewer/#Computer-get>`__
Args:
guid (str): The globally unique identifier of the device.
Expand All @@ -166,7 +162,6 @@ def get_by_guid(self, guid, include_backup_usage=None, **kwargs):
def block(self, device_id):
"""Blocks a device causing the user not to be able to log in to or restore from Code42 on
that device.
`REST Documentation <https://console.us.code42.com/apidocviewer/#ComputerBlock>`__
Args:
device_id (int): The identification number of the device.
Expand All @@ -179,7 +174,6 @@ def block(self, device_id):

def unblock(self, device_id):
"""Unblocks a device, permitting a user to be able to login and restore again.
`REST Documentation <https://console.us.code42.com/apidocviewer/#ComputerBlock>`__
Args:
device_id (int): The identification number of the device.
Expand All @@ -192,7 +186,6 @@ def unblock(self, device_id):

def deactivate(self, device_id):
"""Deactivates a device, causing backups to stop and archives to go to cold storage.
`REST Documentation <https://console.us.code42.com/swagger/index.html?urls.primaryName=v4#/computer-deactivation/ComputerDeactivation_Update>`__
Args:
device_id (int): The identification number of the device.
Expand All @@ -210,7 +203,6 @@ def deactivate(self, device_id):

def reactivate(self, device_id):
"""Activates a previously deactivated device.
`REST Documentation <https://console.us.code42.com/swagger/?urls.primaryName=v4#/computer-deactivation/ComputerDeactivation_Remove>`__
Args:
device_id (int): The identification number of the device.
Expand All @@ -225,7 +217,6 @@ def reactivate(self, device_id):
def deauthorize(self, device_id):
"""Deauthorizes the device with the given ID. If used on a cloud connector device, it will
remove the authorization token for that account.
`REST Documentation <https://console.us.code42.com/apidocviewer/#ComputerDeauthorization>`__
Args:
device_id (int): The identification number of the device.
Expand All @@ -238,7 +229,6 @@ def deauthorize(self, device_id):

def get_agent_state(self, guid, property_name):
"""Gets the agent state of the device.
`REST Documentation <https://console.us.code42.com/swagger/index.html?urls.primaryName=v14#/agent-state/AgentState_ViewByDeviceGuid>`__
Args:
guid (str): The globally unique identifier of the device.
Expand All @@ -253,7 +243,6 @@ def get_agent_state(self, guid, property_name):

def get_agent_full_disk_access_state(self, guid):
"""Gets the full disk access status of a device.
`REST Documentation <https://console.us.code42.com/swagger/index.html?urls.primaryName=v14#/agent-state/AgentState_ViewByDeviceGuid>`__
Args:
guid (str): The globally unique identifier of the device.
Expand Down
2 changes: 1 addition & 1 deletion src/py42/services/fileevent.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class FileEventService(BaseService):

def search(self, query):
"""Searches for file events matching the query criteria.
`REST Documentation <https://forensicsearch-east.us.code42.com/forensic-search/queryservice/swagger-ui.html#/file-event-controller/searchEventsUsingPOST>`__
`REST Documentation <https://developer.code42.com/api/#operation/searchEventsUsingPOST>`__
Args:
query (:class:`~py42.sdk.queries.fileevents.file_event_query.FileEventQuery` or str or unicode):
Expand Down
15 changes: 0 additions & 15 deletions src/py42/services/legalhold.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ class LegalHoldService(BaseService):

def create_policy(self, name, policy=None):
"""Creates a new Legal Hold Preservation Policy.
`REST Documentation <https://console.us.code42.com/swagger/?urls.primaryName=v4#/legal-hold-policy/LegalHoldPolicy_Create>`__
Args:
name (str): The name of the new Policy.
Expand All @@ -50,7 +49,6 @@ def create_matter(
self, name, hold_policy_uid, description=None, notes=None, hold_ext_ref=None
):
"""Creates a new, active Legal Hold Matter.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHold-post>`__
Args:
name (str): The name of the new Legal Hold Matter.
Expand All @@ -75,7 +73,6 @@ def create_matter(

def get_policy_by_uid(self, legal_hold_policy_uid):
"""Gets a single Preservation Policy.
`V4 REST Documentation <https://console.us.code42.com/swagger/#/legal-hold-policy/LegalHoldPolicy_View>`__
Args:
legal_hold_policy_uid (str): The identifier of the Preservation Policy.
Expand All @@ -89,7 +86,6 @@ def get_policy_by_uid(self, legal_hold_policy_uid):

def get_policy_list(self):
"""Gets a list of existing Preservation Policies.
`V4 REST Documentation <https://console.us.code42.com/swagger/#/legal-hold-policy/LegalHoldPolicy_List>`__
Returns:
:class:`py42.response.Py42Response`: A response containing the list of Policies.
Expand All @@ -99,7 +95,6 @@ def get_policy_list(self):

def get_matter_by_uid(self, legal_hold_uid):
"""Gets a single Legal Hold Matter.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHold-get>`__
Args:
legal_hold_uid (str): The identifier of the Legal Hold Matter.
Expand All @@ -123,7 +118,6 @@ def get_matters_page(
page_size=None,
):
"""Gets a page of existing Legal Hold Matters.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHold-get>`__
Args:
page_num (int): The page number to request.
Expand Down Expand Up @@ -160,7 +154,6 @@ def get_all_matters(
self, creator_user_uid=None, active=True, name=None, hold_ext_ref=None
):
"""Gets all existing Legal Hold Matters.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHold-get>`__
Args:
creator_user_uid (str, optional): Find Matters by the identifier of the user who created
Expand Down Expand Up @@ -201,7 +194,6 @@ def get_custodians_page(
`legal_hold_membership_uid`, `legal_hold_uid`, `user_uid`, `user`
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHoldMembership-get>`__
Args:
page_num (int): The page number to request.
Expand Down Expand Up @@ -250,7 +242,6 @@ def get_all_matter_custodians(
"INACTIVE", they have been removed from the Matter and are no longer subject to the Legal
Hold retention rules. Users can be Custodians of multiple Legal Holds at once (and thus
would be part of multiple LegalHoldMembership objects).
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHoldMembership-get>`__
Args:
legal_hold_uid (str, optional): Find LegalHoldMemberships for the Legal Hold Matter
Expand Down Expand Up @@ -286,7 +277,6 @@ def get_events_page(
):
"""Gets an individual page of Legal Hold events.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHoldEventReport-get>`__
Args:
legal_hold_uid (str, optional): Find LegalHoldEvents for the Legal Hold
Expand Down Expand Up @@ -324,7 +314,6 @@ def get_all_events(
self, legal_hold_uid=None, min_event_date=None, max_event_date=None
):
"""Gets an individual page of Legal Hold events.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHoldEventReport-get>`__
Args:
legal_hold_uid (str, optional): Find LegalHoldEvents for the Legal Hold Matter
Expand All @@ -350,7 +339,6 @@ def get_all_events(

def add_to_matter(self, user_uid, legal_hold_uid):
"""Add a user (Custodian) to a Legal Hold Matter.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHoldMembership-post>`__
Args:
user_uid (str): The identifier of the user.
Expand All @@ -374,7 +362,6 @@ def add_to_matter(self, user_uid, legal_hold_uid):

def remove_from_matter(self, legal_hold_membership_uid):
"""Remove a user (Custodian) from a Legal Hold Matter.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHoldMembershipDeactivation-post>`__
Args:
legal_hold_membership_uid (str): The identifier of the LegalHoldMembership
Expand All @@ -389,7 +376,6 @@ def remove_from_matter(self, legal_hold_membership_uid):

def deactivate_matter(self, legal_hold_uid):
"""Deactivates and closes a Legal Hold Matter.
`V4 REST Documentation <https://console.us.code42.com/swagger/#/legal-hold-deactivation/LegalHoldDeactivation_Update>`__
Args:
legal_hold_uid (str): The identifier of the Legal Hold Matter.
Expand All @@ -403,7 +389,6 @@ def deactivate_matter(self, legal_hold_uid):

def reactivate_matter(self, legal_hold_uid):
"""Reactivates and re-opens a closed Matter.
`REST Documentation <https://console.us.code42.com/apidocviewer/#LegalHoldReactivation-put>`__
Args:
legal_hold_uid (str): The identifier of the Legal Hold Matter.
Expand Down

0 comments on commit 0d0a472

Please sign in to comment.