Home > Net >  C # how to create the Http interface, access method is Get, do you have any sample?
C # how to create the Http interface, access method is Get, do you have any sample?

Time:11-26

C # how to create the Http interface, access method is Get, don't know how to write this

CodePudding user response:

How to write an Http interface, let the other people to call

CodePudding user response:

Have bosses give directions

CodePudding user response:

I am wrong, I didn't see clear title, many kinds of ways, set up a website, web service or webapi can be,

CodePudding user response:

Well, in section c #, I think you are by default console program, not asp.net application (if the asp.net, I think you don't ask, he is by nature)

So:
If you are the core or 5:
1. Nuget Microsoft. AspNetCore. Owin
2. Microsoft. AspNetCore. Server. Kestrel

The rest, how ordinary asp.net you write how to write, the same to webhost. Builder, as well as startup. Cs, as the use of controls, mapcontrols, use routing

If you are a net4, situation about
1. Nuget lookup owin. Self. Host

This data I don't specifically, because at that time owin itself reference some confusion, data is chaotic, how do you say, how to use, so I can't say that is the most correct (when the reality is that owin and your reference other libraries depend on each other, and version is different, the data is different, we can't reply, at the time I sometimes Nancy this unofficial products, because somehow Nancy idea of structuralism, the author of data will be less confusion)

CodePudding user response:

soil soil reference 4 floor response:
I was wrong, I didn't see clear title, many kinds of ways, set up a website, web service or webapi can be,

I have written the webservice interface, you mean to say the new build asp.net

CodePudding user response:

reference 5 floor wanghui0380 reply:
, in section c #, I think you are by default console program, not a asp.net application (if the asp.net, I think you don't ask, he is by nature)

So:
If you are the core or 5:
1. Nuget Microsoft. AspNetCore. Owin
2. Microsoft. AspNetCore. Server. Kestrel

The rest, how ordinary asp.net you write how to write, the same to webhost. Builder, as well as startup. Cs, as the use of controls, mapcontrols, use routing

If you are a net4, situation about
1. Nuget lookup owin. Self. Host

The information I don't specifically, because at that time owin itself reference some confusion, data is chaotic, how do you say, how to use, so I can't say that is the most correct (when the reality is that owin and your reference other libraries depend on each other, and version is different, the data is different, we can't reply, I sometimes Nancy in those days the unofficial products, because somehow Nancy idea of structuralism, the author of data will be less chaos)



Is I now need to write an Http interface, don't know how to write, not the console program,

CodePudding user response:

Netcore data unification, we can give a clear answer directly

1. https://docs.microsoft.com/zh-cn/aspnet/core/fundamentals/owin? View=aspnetcore - 5.0 official description
2. https://github.com/dotnet/aspnetcore.docs/tree/master/aspnetcore/fundamentals/owin/sample
The official for the demo

CodePudding user response:

It is good to create a new web site Asp.net, hang on IIS,

Some concepts are not pay someone to solve

CodePudding user response:

What kind of framework to write this? MVC, WebAPI?

CodePudding user response:

The
refer to 6th floor fairy & amp; & Response:
Quote: refer to 4th floor soil soil response:
I was wrong, I didn't see clear title, many kinds of ways, set up a website, web service or webapi can be,

I have written the webservice interface, you mean to say the new set up asp.net?

Yeah, can build many types support asp.net webservice

CodePudding user response:

Before and after the separation that call?

CodePudding user response:

soil soil reference 11 floor response:
Quote: refer to the sixth floor fairy & amp; & Response:
Quote: refer to 4th floor soil soil response:
I was wrong, I didn't see clear title, many kinds of ways, set up a website, web service or webapi can be,

I have written the webservice interface, you mean to say the new set up asp.net?

Yes, you can set up asp.net many types support webservice



Want to write a WebService, then can let the HTTP get calls

CodePudding user response:

The
refer to 12 floor Xiao__Chou reply:
separation front end the call?

Just write to someone else can call interface
  •  Tags:  
  • C#
  • Related