Integrations/MicrosoftGraphFiles/MicrosoftGraphFiles.py
def list_drive_content_command(client, args):
    """
    This function runs list drive children command
    :return: human_readable, context, result
    """
    object_type = args.get("object_type")
    object_type_id = args.get("object_type_id")
    item_id = args.get("item_id")
    limit = args.get("limit")
    next_page_url = args.get("next_page_url")

    if not item_id:
        item_id = "root"

    result = client.list_drive_content(
        object_type=object_type,
        object_type_id=object_type_id,
        item_id=item_id,
        limit=limit,
        next_page_url=next_page_url,
    )

    title = f"{INTEGRATION_NAME} - drivesItems information:"

    parsed_drive_items = [parse_key_to_context(item) for item in result["value"]]
    human_readable_content = [
        list_drive_content_human_readable_object(item) for item in parsed_drive_items
    ]
    human_readable = tableToMarkdown(
        title, human_readable_content, headerTransform=pascalToSpace
    )

    drive_items_outputs = {
        "OdataContext": result["@odata.context"],
        "Value": parsed_drive_items,
    }
    context = {
        f"{INTEGRATION_NAME}.ListChildren(val.ItemID == obj.ItemID)": {
            "ParentID": item_id,
            "Children": drive_items_outputs,
        }
    }

    return human_readable, context, result

    This function runs list drive children command
    :return: human_readable, context, result
    
This function runs list drive children command
This function runs list drive children command
def list_drive_content_command(client, args):
    object_type = args.get("object_type")
    object_type_id = args.get("object_type_id")
    item_id = args.get("item_id")
    limit = args.get("limit")
    next_page_url = args.get("next_page_url")
    if not item_id:
        item_id = "root"
    result = client.list_drive_content(
        object_type=object_type,
        object_type_id=object_type_id,
        item_id=item_id,
        limit=limit,
        next_page_url=next_page_url,
    )
    title = f"{INTEGRATION_NAME} - drivesItems information:"
    parsed_drive_items = [parse_key_to_context(item) for item in result["value"]]
    human_readable_content = [
        list_drive_content_human_readable_object(item) for item in parsed_drive_items
    ]
    human_readable = tableToMarkdown(
        title, human_readable_content, headerTransform=pascalToSpace
    )
    drive_items_outputs = {
        "OdataContext": result["@odata.context"],
        "Value": parsed_drive_items,
    }
    context = {
        f"{INTEGRATION_NAME}.ListChildren(val.ItemID == obj.ItemID)": {
            "ParentID": item_id,
            "Children": drive_items_outputs,
        }
    }
    return human_readable, context, result
def list_drive_content_command ( client , args ) : object_type = args . get ( "object_type" ) object_type_id = args . get ( "object_type_id" ) item_id = args . get ( "item_id" ) limit = args . get ( "limit" ) next_page_url = args . get ( "next_page_url" ) if not item_id : item_id = "root" result = client . list_drive_content ( object_type = object_type , object_type_id = object_type_id , item_id = item_id , limit = limit , next_page_url = next_page_url , ) title = f"{INTEGRATION_NAME} - drivesItems information:" parsed_drive_items = [ parse_key_to_context ( item ) for item in result [ "value" ] ] human_readable_content = [ list_drive_content_human_readable_object ( item ) for item in parsed_drive_items ] human_readable = tableToMarkdown ( title , human_readable_content , headerTransform = pascalToSpace ) drive_items_outputs = { "OdataContext" : result [ "@odata.context" ] , "Value" : parsed_drive_items , } context = { f"{INTEGRATION_NAME}.ListChildren(val.ItemID == obj.ItemID)" : { "ParentID" : item_id , "Children" : drive_items_outputs , } } return human_readable , context , result
This function runs list drive children command
This function runs list drive children command
"""
    This function runs list drive children command
    :return: human_readable, context, result
    """
human_readable, context, result
human_readable context result
client
args