cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
jzcase
Level 8

"Empty segment encountered in request URL. Please make sure that a valid request URL is specified."

Hello! I need some help interpreting an error message.

 

The Flow below is designed to copy a record (called "File") and all of its child records (called "Services") to a duplicate tree.

Capture.PNG

It gets as far as listing the child Service records, but I get the following error when it tries to copy each Service to a new Service.

 

INPUTS

{
  "host": {
    "apiId": "subscriptions/427976e2-4271-4308-afb8-d28d53a6ad06/providers/Microsoft.Web/locations/westus/runtimes/unitedstates-002/apis/commondataservice",
    "connectionReferenceName": "shared_commondataservice",
    "operationId": "PostItem_V2"
  },
  "parameters": {
    "dataset": "orgc9b97da0.crm",
    "table": "case_services",
    "item/case_contractconsultminutes": null,
    "item/case_contractdirectminutes": null,
    "item/case_contractrate": null,
    "item/case_contracttype": null,
    "item/case_dropped": false,
    "item/case_fmsystem": true,
    "item/case_invoiceby": 132220000,
    "item/case_legacynotes": null,
    "item/case_name": "Test, Test (D89) 19-20 HI 504",
    "item/case_servicetype": 132220000,
    "item/statuscode": 1,
    "item/case_usestandardrate": true,
    "item/case_ycord": true,
    "item/_case_fileid_value": "4f01e4e7-94d8-e911-a83a-000d3a315a07",
    "item/_ownerid_value": "d8968745-0ea9-4dba-9998-90ffe317f753",
    "item/_ownerid_type": ""
  }
}

OUTPUTS

{
  "statusCode": 400,
  "headers": {
    "Pragma": "no-cache",
    "x-ms-request-id": "6e857663-701e-4aa6-835a-6e4bc7aa3510",
    "Strict-Transport-Security": "max-age=31536000; includeSubDomains",
    "X-Content-Type-Options": "nosniff",
    "X-Frame-Options": "DENY",
    "Timing-Allow-Origin": "*",
    "x-ms-apihub-cached-response": "true",
    "Cache-Control": "no-store, no-cache",
    "Date": "Mon, 16 Sep 2019 15:16:17 GMT",
    "Set-Cookie": "ARRAffinity=c77e36b0aca6576c8ac46e26483df0d47d259aa60bf2154168d771cd726bd4c2;Path=/;HttpOnly;Domain=commondataservice-eus2.azconn-eus2.p.azurewebsites.net",
    "Content-Length": "268",
    "Content-Type": "application/json",
    "Expires": "-1"
  },
  "body": {
    "status": 400,
    "message": "Empty segment encountered in request URL. Please make sure that a valid request URL is specified.",
    "source": "[redacted].crm.dynamics.com",
    "errors": [],
    "debugInfo": "clientRequestId: 6e857663-701e-4aa6-835a-6e4bc7aa3510"
  }
}

This one has me stumped and I can't seem to find relevant documentation of this error. Can someone here give me a clue?

1 ACCEPTED SOLUTION

Accepted Solutions
jzcase
Level 8

Re: "Empty segment encountered in request URL. Please make sure that a valid request URL is specified."

OK so after testing again I received a different error which was much more informative:

 

  "body": {
    "status": 400,
    "message": "Resource not found for the segment 'owners'."

Oh so it has something to do with Owners? I do copy the owner from the old Service to the new Service.

 

Here was the problem:

 

Capture.PNG

 

"Service Provider" is actually the "Owner" field on the record.

 

You can't leave "Owner Type" blank when creating a new CDS record and setting the Owner via Flow.

 

The solution was to set "Service Provider Type" (= "Owner Type") to "systemusers" and the error went away.

View solution in original post

3 REPLIES 3
Community Support Team
Community Support Team

Re: "Empty segment encountered in request URL. Please make sure that a valid request URL is specified."

Hi @jzcase ,

 

The error message told that the empty segment encountered in request URL, could you please check that if the URL is valid?

 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

jzcase
Level 8

Re: "Empty segment encountered in request URL. Please make sure that a valid request URL is specified."

What URL is it referring to? I don't know where to begin looking.

jzcase
Level 8

Re: "Empty segment encountered in request URL. Please make sure that a valid request URL is specified."

OK so after testing again I received a different error which was much more informative:

 

  "body": {
    "status": 400,
    "message": "Resource not found for the segment 'owners'."

Oh so it has something to do with Owners? I do copy the owner from the old Service to the new Service.

 

Here was the problem:

 

Capture.PNG

 

"Service Provider" is actually the "Owner" field on the record.

 

You can't leave "Owner Type" blank when creating a new CDS record and setting the Owner via Flow.

 

The solution was to set "Service Provider Type" (= "Owner Type") to "systemusers" and the error went away.

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 435 members 5,556 guests
Please welcome our newest community members: