Based on the documentation :
You can copy file from SharePoint Online by using Web activity to authenticate and grab access token from SPO, then passing to subsequent Copy activity to copy data with HTTP connector as source.
Follow the Prerequisites section to create Microsoft Entra application and grant permission to SharePoint Online.
- Create a Web Activity to get the access token from SharePoint Online:
URL: https://accounts.accesscontrol.windows.net/[Tenant-ID]/tokens/OAuth/2
. Replace the tenant ID.
Method: POST
Headers:
Content-Type: application/x-www-form-urlencoded
**Body**: `grant_type=client_credentials&client_id=[Client-ID]@[Tenant-ID]&client_secret=[Client-Secret]&resource=00000003-0000-0ff1-ce00-000000000000/[Tenant-Name].sharepoint.com@[Tenant-ID]`. Replace the client ID (application ID), client secret (application key), tenant ID, and tenant name (of the SharePoint tenant).
- Chain with a Copy activity with HTTP connector as source to copy SharePoint Online file content: HTTP linked service: Base URL:
https://[site-url]/_api/web/GetFileByServerRelativeUrl('[relative-path-to-file]')/$value
. Replace the site URL and relative path to file. Make sure to include the SharePoint site URL along with the Domain name, such ashttps://[sharepoint-domain-name].sharepoint.com/sites/[sharepoint-site]/_api/web/GetFileByServerRelativeUrl('/sites/[sharepoint-site]/[relative-path-to-file]')/$value
. Authentication type: Anonymous (to use the Bearer token configured in copy activity source later) Dataset: choose the format you want. To copy file as-is, select "Binary" type. Copy activity source: Request method: GET Additional header: use the following expression@{concat('Authorization: Bearer ', activity('<Web-activity-name>').output.access_token)}
, which uses the Bearer token generated by the upstream Web activity as authorization header. Replace the Web activity name. Configure the copy activity sink as usual.
More links :