rename a file in Power Automate

Aby Scaria 0 Reputation points
2025-09-30T06:59:22.0033333+00:00

When creating a file from a template in a Teams channel (SharePoint), Teams doesn't prompt for a file name. I considered using Power Automate to address this but found that the rename file task requires a separate connection/authentication, even within the same workflow.

Is there a way to rename the file created without needing additional authentication?


User's image

User's image

Windows for business | Windows 365 Business
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Harry Phan 11,010 Reputation points Independent Advisor
    2025-09-30T07:34:41.1433333+00:00

    Hi Aby Scaria,

    Based on your description, here are a few options to consider:

    1. Use the "Create file" Action Instead of "Using Template" in Teams

    If your use case allows, consider using Power Automate to:

    Create the file from a known template stored in a Document Library.

    Use the "Create file" action and specify the file name programmatically (e.g., including date, user name, etc.).

    This avoids the need to rename the file later and bypasses the naming issue entirely.

    1. Use a Single Authenticated Connection

    Ensure that:

    The entire flow runs under one user connection (ideally the same as the creator or a service account).

    This can often prevent repeated authentication prompts, depending on your organization’s security settings.

    1. Trigger Flow via Teams or Power Apps Button

    Create a Power Automate button flow or integrate with Power Apps to:

    Prompt the user for the desired file name.

    Use that input to create and save the file directly in SharePoint with the correct name.

    Let me know how it goes, and if this answer helps, feel free to hit “Accept Answer” so others can benefit too 😊 T&B, Harry.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.