# Route conflict while defining multiple routes

**URL:** https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188
**Category:** Support Request
**Tags:** neutrinos-ssd
**Created:** [September 3, 2025, 8:18am UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188 "2025-09-03T08:18:19Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![JeevanKumar](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/j/e8c25b/32.png) [@JeevanKumar](https://community.neutrinos.com/u/JeevanKumar)
#### Post date: [September 3, 2025, 8:18am UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/1 "2025-09-03T08:18:19Z")

</div>

I have two routes  
GET [http://localhost:8081/api/books/exists?isbn=fdsfs](http://localhost:8081/api/books/exists?isbn=fdsfs)  
GET [http://localhost:8081/api/books/:isbn](http://localhost:8081/api/books/:isbn)

when calling first api it triggers second api because of path , it considers “exists” as path parameter for :isbn  
how to resolve this.

 ![Screenshot 2025-09-03 at 1.47.00 PM](https://community.neutrinos.com/uploads/default/original/1X/4295ca9d355d4421d5c35b279727f0a65fd04614.png)

---

<div class="post-metadata">

### Author: ![Simphiwe](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/s/3be4f8/32.png) [@Simphiwe](https://community.neutrinos.com/u/Simphiwe)
#### Post date: [September 3, 2025, 12:16pm UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/2 "2025-09-03T12:16:02Z")

</div>

Hi @JeevanKumar ,

Is this still the issue ??

---

<div class="post-metadata">

### Author: ![JeevanKumar](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/j/e8c25b/32.png) [@JeevanKumar](https://community.neutrinos.com/u/JeevanKumar)
#### Post date: [September 3, 2025, 12:44pm UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/3 "2025-09-03T12:44:24Z")

</div>

@Simphiwe Yes.

 ![Screenshot 2025-09-03 at 6.04.39 PM](https://community.neutrinos.com/uploads/default/original/1X/4af51f2062f26bf97e13c5f50e12d01444f6f859.png)

Given API document has 4 GET request for same endpoints ,  
I think In SSD I can’t able to rearrange the routes , like we put dynamic route under the other routes  
for example :

```auto
get ("/books/exists");
get("/books/:isbn");

```

in above endpoints :isbn conflict with exists and get book :id conflict with paginated endpoint.

---

<div class="post-metadata">

### Author: ![Simphiwe](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/s/3be4f8/32.png) [@Simphiwe](https://community.neutrinos.com/u/Simphiwe)
#### Post date: [September 3, 2025, 12:46pm UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/4 "2025-09-03T12:46:09Z")

</div>

Can you share a screenshot of how you specified your endpoint and paths on you http-In for both

---

<div class="post-metadata">

### Author: ![JeevanKumar](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/j/e8c25b/32.png) [@JeevanKumar](https://community.neutrinos.com/u/JeevanKumar)
#### Post date: [September 3, 2025, 12:51pm UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/5 "2025-09-03T12:51:07Z")

</div>

![Screenshot 2025-09-03 at 6.20.30 PM](https://community.neutrinos.com/uploads/default/original/1X/360136216161d4c65c903193b0bc8cf4c30146a4.png)  
 ![Screenshot 2025-09-03 at 6.20.52 PM](https://community.neutrinos.com/uploads/default/original/1X/0b8a4e4f11d74c3f2904b281a80532f4a20ef75e.png)

---

<div class="post-metadata">

### Author: ![Simphiwe](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/s/3be4f8/32.png) [@Simphiwe](https://community.neutrinos.com/u/Simphiwe)
#### Post date: [September 3, 2025, 4:38pm UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/6 "2025-09-03T16:38:39Z")

</div>

Hi @JeevanKumar ,

It seems like those are two different endpoints.  
It should consider those to be completely different endpoints since they are not the same.  
Can you also share a screenshot of the responses you get and their complete URL when calling them as a screenshot, please.

---

<div class="post-metadata">

### Author: ![JeevanKumar](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/j/e8c25b/32.png) [@JeevanKumar](https://community.neutrinos.com/u/JeevanKumar)
#### Post date: [September 3, 2025, 5:45pm UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/7 "2025-09-03T17:45:05Z")

</div>

@Simphiwe

**URL 1**

```auto
http://localhost:8081/api/books/OL7353617M

```

 ![Screenshot 2025-09-03 at 11.00.04 PM](https://community.neutrinos.com/uploads/default/original/1X/01451f9b5040c1616d64c6b2fcebee2bd775b57d.png)

**URL 2**

```auto
http://localhost:8081/api/books/exists?isbn=OL7353617M

```

 ![Screenshot 2025-09-03 at 11.02.49 PM](https://community.neutrinos.com/uploads/default/original/1X/da4a289e46d9a3903d573936423c7a7ea87bf9bd.png)

here 404 is getting from URL 1

Could you provide a link to the document about handling dynamic routes in studio, or please explain it here.

---

<div class="post-metadata">

### Author: ![Simphiwe](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/s/3be4f8/32.png) [@Simphiwe](https://community.neutrinos.com/u/Simphiwe)
#### Post date: [September 4, 2025, 7:25am UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/8 "2025-09-04T07:25:15Z")

</div>

Hi @JeevanKumar ,

Am trying to understand how they are conflicting coz they are not supposed to be conflicting since their endpoints are not the same.  
They also don’t seem to be conflicting from my side since you are getting different responses, looks like one is getting the book and the other one is checking if the book exists.  
Could you please provide more Information about what you mean when you say conflicting.

---

<div class="post-metadata">

### Author: ![JeevanKumar](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/j/e8c25b/32.png) [@JeevanKumar](https://community.neutrinos.com/u/JeevanKumar)
#### Post date: [September 4, 2025, 8:41am UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/9 "2025-09-04T08:41:14Z")

</div>

@Simphiwe

I mean , when I calling two different endpoints it gives response from one http flow in ssd

I Created 2 flows for 2 URL

URL 1 [http://localhost:8081/api/books/OL7353617M](http://localhost:8081/api/books/OL7353617M)  
URL 2 [http://localhost:8081/api/books/exists?isbn=OL7353617M](http://localhost:8081/api/books/exists?isbn=OL7353617M)

when I calling URL 2 , the backend assumes I am calling URL 1 and its returns response form URL 1 . the string **“exists”** (actually path of URL 2) is considered as isbn that’s why it returns error

```auto
{
  "error" : "Book not found for ISBN: exists"
}

```

---

<div class="post-metadata">

### Author: ![Simphiwe](https://community.neutrinos.com/letter_avatar_proxy/v4/letter/s/3be4f8/32.png) [@Simphiwe](https://community.neutrinos.com/u/Simphiwe)
#### Post date: [September 4, 2025, 8:02pm UTC](https://community.neutrinos.com/t/route-conflict-while-defining-multiple-routes/1188/10 "2025-09-04T20:02:15Z")

</div>

Hi @JeevanKumar ,

Thank you for confirming.  
I see what you mean now, have went through the conflicting APIs.

In Express, routes are matched in the order they are defined, and dynamic parameters like `:isbn` will match **any value** , including the word `"exists"`. If `/books/:isbn` is placed before `/books/exists`, a request to `/books/exists` will be treated as if `"exists"` is an ISBN, causing the static route to never be reached.

Always define more **specific static routes first** (like `/books/exists`) before dynamic ones (like `/books/:isbn`). To fix this in Neutrinos studio cut`/books/:isbn` flow and paste it at the end of all your apis.

That should work.
