Questions tagged [webapi]

Questions related to web browser's Web APIs specification. Web APIs is a set of numerous different APIs related to programmatically using web browser with your JavaScript code. For example the visual web page rendered is represented as and controlled by Document Object Model (DOM), which itself is a Web API. Or when using console.debug() function to log messages to the browser's console, you are using Console API.

Questions related to web browser's Web APIs specification.

Web APIs is a set of numerous different APIs related to programmatically controlling the functions of a web page that is run in the web browser with JavaScript code.

For example the visual web page rendered is represented as and controlled by Document Object Model (DOM), which itself is a Web API. Or when using console.debug() function to log messages to the browser's console, you are using Console API.

If you are new to Web APIs, you can read: Introduction to web APIs

1984 questions
0
votes
0 answers

Testcafe: Inject Client Script Code into Worker Global Scope to mock a missing Web API

It is easy to inject client scripts into window's global scope as per official guide. What I'm having troubles is how to go about injecting client scripts into web worker's global scope. Goal is to mock a Web API which is supported in Chrome's web…
radulle
  • 1,437
  • 13
  • 19
0
votes
1 answer

.Net Core 5 WebAPI Missing ClientId in Production

I have a WebAPI that I am able to debug/deploy in 4 different place with no code changes and it only acts different in production. On the image below, the left shows the local dev machine (both VS & IIS), the right shows the production server, both…
Briana Finney
  • 1,171
  • 5
  • 12
  • 22
0
votes
1 answer

How to alert React-JS fetch values

I have a Web API that takes 3 parameters (e.g: int EID, string MUN, string MUP) and then return a JSON like this: [ { "MemberID": 71, "MemberExamID": 1 } ] Now I want to alert 'MemberID' in my React-JS project, when the user…
0
votes
0 answers

HttpContext.Current.Session.SessionID is throwing "Object reference error" when instantiated outside of the project

I have web application project name say project1 in which i have class Class A. Inside which i have a field readonly string sessionId = HttpContext.Current.Session.SessionID; my sample class looks like this public class A { readonly string…
0
votes
1 answer

Can you pass property values into a 'Specific Page' URL path in the Web Properties in C# .NET

I am working on a program to GET data from an API. I am having an issue with error 404, which I resolved by setting the Web Property on the Web application to the name of the controller(rating), and the name of the method (index.) Is this best way…
0
votes
0 answers

Accepting any type of data in web api method c#

I am building a web api method in c# which should be capable of accepting string value or Complex type like Objects. For that i have written below sample snippet which seems to be working with Content-Type: 'application/json'. public…
Ronak
  • 187
  • 2
  • 17
0
votes
1 answer

Autoupdate OpenAPI Specification in APIM

I have backend system in Web API using asp.net core where I am using Swashbuckle.AspNetCore package for generating OpenAPI Specification document. The OpenAPI specification document is generating fine something like '~/swagger.json'. I hookup this…
0
votes
1 answer

Blazor Server Webapi Not working on postman

I build the Blazor with template Blazor Server, Webassembly, Shared. It is working okay. But when I try to test with postman. It always show this the below is my testing controller. i can use blazor httpclient to access rest. but i want to test…
Sras
  • 1,686
  • 2
  • 19
  • 29
0
votes
1 answer

.NET 5 WebAPI returning different format in local and when deployed to Azure

I am retrieving data from my database using WebAPI and displaying it in a page, but once I get the response in the browser, im getting invalid date in my local but correct date from the one deployed in Azure. I chcked the response and it happens…
g_b
  • 11,728
  • 9
  • 43
  • 80
0
votes
1 answer

Which formatter is used when I send a multipart request to a Web API Controller in ASP.NET CORE?

Checking the ASP.NET Core built-in formatters there seems to be no multipart formatter. Yet a multipart request is model bound, so there needs to be some kind of input formatter, that creates the key-value pairs, which are then model bound. Which…
stefan.at.kotlin
  • 15,347
  • 38
  • 147
  • 270
0
votes
1 answer

How to implement an HTTP GET for large data avoiding Request Timeout error

I`m developing WebAPI to transfer data between 2 systems. Simplifying I have to implement an HTTP GET method to retrieve large data. Same problem for a POST method to push data. How can I do to avoid timeout error due to long processing? Any help…
Andrea86
  • 129
  • 1
  • 8
0
votes
1 answer

PDF form submission to .Net Core Web API, return result

I have created a .net core web api controller in C#, that accepts PDF form data in FDF format, from a submit button on the form. Because my controller tries to store the data in a database, I would like to return a success/fail status to the form,…
Tim Dol
  • 31
  • 3
0
votes
1 answer

Controlling a Checkbox group input type with a Radio button input type in ASP.NET Core

In my Visual Studio 2019 ASP.NET Core 5.0 MVC project, I wish to consume a publicly available Joke API at information about a Joke API which is a try out form for a joke api. Now I am stuck at the implementation of catergory/categories at the top…
user9555045
  • 43
  • 1
  • 7
0
votes
0 answers

Unhandled Exception In HttpClient web api call in asp.net core but couldn't understand the issue

In postman I issue a request with the following body against http://localhost:2001/api/ProductQuality/Check: { "productid": "2274", "productcorenumber": "1321", "value": "AE1C1F-0363-D6F-B3D-AE0029A8", "contacts": [ 15998, …
0
votes
0 answers

Web API application does not run any controller code

I already have been trying to solve this for days, I created a Web API application (using .NET 5, VS2019) and when I was finally be able to run it without errors in the IIS, I receive 404 errors in the responses, simply put the controller code is…