Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Data Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more

Reply
gshapiev
Frequent Visitor

REST API. jobs/instances?jobType=Refresh causes error while manual refresh works

Trying to refresh Dataflow Gen2 (CI/CD) dataflow using Rest API

 

Getting error on the service side:

There was a problem refreshing the dataflow: 'Exception encountered in GetPublishStatusAsync: Response status code does not indicate success: 404 (Not Found)..'. Error code: . (Request ID: 00000000-0000-0000-0000-000000000000).

 

When initiating run in the workspace Everything runs fine.

 

What could be the problem? Am I missing something?

1 ACCEPTED SOLUTION
gshapiev
Frequent Visitor

The problem was with permissions. Was trying to refresh with service principal which is not supported at the moment

 

View solution in original post

7 REPLIES 7
andreimiron
New Member

Hello!

What permissions you had to set?

Thanks in advance!

Andrei

I was authenticating with Service Principal, which was(is?) not supported. Had to create Delegated Auth Token with actual user.

gshapiev
Frequent Visitor

The problem was with permissions. Was trying to refresh with service principal which is not supported at the moment

 

Anonymous
Not applicable

Hi @gshapiev,

 

When you sync changes from Git into the workspace or use deployment pipelines, you need to open the new or updated dataflow and save changes manually with the editor. This triggers a publish action in the background to allow the changes to be used during refresh of your dataflow. You can also use the on-demand Dataflow publish job API call to automate the publish operation and then refresh.

 

document where limitation is noted : https://learn.microsoft.com/en-us/fabric/data-factory/dataflow-gen2-cicd-and-git-integration

 

Publish Job API Endpoint : POST https://api.fabric.microsoft.com/v1/workspaces/{workspaceId}/dataflows/{dataflowId}/jobs/instances?j...

 

Thanks & Regards,

Prasanna Kumar

 

1. Publish method doesn't exist anymore:

{
    "requestId": "cfb9aff5-00fa-4d4a-90d6-7e2a4e14f40c",
    "errorCode": "InvalidJobType",
    "message": "The requested job type is invalid"
}
 
2. It is replaced with ApplyChanges. When calling it getting error in responce. Not very informative:
{
    "id": "7f6ca2fb-5dda-4c64-bc1d-ada29e2dd093",
    "itemId": "15cacd88-df9d-447a-9caa-b17cdb87af6d",
    "jobType": "Publish",
    "invokeType": "Manual",
    "status": "Failed",
    "failureReason": {
        "requestId": "b5155ec5-6584-4580-a337-5c80b4f6868a",
        "errorCode": "JobInstanceStatusFailed",
        "message": "Job instance failed without detail error"
    },
    "rootActivityId": "36db2346-20a5-4b89-95bc-d2b44021b06b",
    "startTimeUtc": "2025-09-23T13:21:50.9036366",
    "endTimeUtc": "2025-09-23T13:21:50.9036366"
}
 
3. I tried to publishing it manually. Error in the topic starter is happening after that. Can refresh manually bit with refreshing through api getting similar message and that error on the service side
 
Thank you
 
Anonymous
Not applicable

Hi @gshapiev,

 

Thank you for reaching out to the Microsoft Fabric Forum Community.

 

The error happens because you’re trying to refresh a Dataflow Gen2 with the old Power BI REST API, which only supports Gen1 dataflows. That’s why the call returns 404 Not Found, even though the refresh works fine inside the workspace. The fix is to use the Fabric REST API instead of the Power BI API, make sure you use the correct workspace ID and item ID from Fabric, and authenticate with the Fabric scope. With the right endpoint, IDs, and permissions, the refresh will work as expected.

 

Thanks & Regards,

Prasanna Kumar

I'm using fabric api

 

https://api.fabric.microsoft.com/v1/workspaces/{{WorkspaceId}}/dataflows/{{DataflowId}}/jobs/instances?jobType=Refresh

 

The call actually goes through and I get 202 response. The error is on the service side.

 

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

June Fabric Update Carousel

Fabric Monthly Update - June 2026

Check out the June 2026 Fabric update to learn about new features.

Top Solution Authors
Top Kudoed Authors