Skip to content

How to Ignore routes? #1764

Answered by Cogitri
techaum asked this question in Q&A
Discussion options

You must be logged in to vote

FWIW, if you wanted to you can do something like this:

app.MapGroup("/account").MapIdentityApi<User>();

app.MapWhen((ctx) => !ctx.Request.Path.StartsWithSegments("/account"), (app) =>
{
	app.UseOcelot();
});

That way everything that's sent to /account will be sent to to authentication thingie of MapIdentityApi and everything else will be handled by Ocelot.

Replies: 5 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by raman-m
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Initially seen a question could become a new feature or bug or closed ;)
4 participants
Converted from issue

This discussion was converted from issue #512 on October 30, 2023 12:26.