Questions tagged [aurelia-fetch-client]
41 questions
16
votes
1 answer
Error handling for fetch() in Aurelia
I have an API that includes a useful description of what went wrong when an error is raised by the server (status = 500). The description comes as part of the response text. My client code, using Aurelia, calls the api via aurelia-fetch-client using…

AR.
- 39,615
- 9
- 44
- 52
6
votes
1 answer
How to download a ZipFile from a dotnet core webapi?
I am trying to download a zip file from a dotnet core web api action, but I can't make it work. I tried calling the action via POSTMAN and my Aurelia Http Fetch Client.
I am able to create the ZipFile like I want it and store it on the system, but…

Tom Aalbers
- 4,574
- 5
- 29
- 51
5
votes
1 answer
How can I use Aurelia Fetch Client to query an API protected by Windows Authentication?
We have a web server serving our Aurelia static files as well as an API, the server is protected by NTLM (using Integrated Windows Authentication on OWIN).
When using the Aurelia Fetch Client we can successfully hit the API with not problem. Here's…

MaYaN
- 6,683
- 12
- 57
- 109
4
votes
1 answer
aurelia-fetch-client - a promise was rejected with a non-error: [object Response]
I'm using the aurelia-fetch-client and I get this error when I send a request to my nodejs backend api:
Warning: a promise was rejected with a non-error: [object Response]
at http://localhost:9000/scripts/vendor-bundle.js:39700:20
at…

QuantumDream
- 137
- 6
4
votes
1 answer
CORS on Web API and MVC 5 Controller: Upload images with fetch and FormData
I have an application that has the front and back ends running on different .NET projects.
The front end is an Aurelia web application running on ASP.NET 5. This Aurelia app (from now on The FrontEnd) gets all it's data from a Web API 2/MVC 5…

Sergi Papaseit
- 15,999
- 16
- 67
- 101
3
votes
1 answer
Aurelia Fetch usage broken after NPM update
I just recently did an npm update on my Aurelia CLI project using TypeScript in Visual Studio 2015. I'm using aurelia-fetch-client for making calls to my Web API (.NET Core) backend.
This is an example of the code that was previously compiling and…

Sam
- 6,167
- 30
- 39
3
votes
2 answers
Post 'x-www-form-urlencoded' content with aurelia-fetch-client
The question is simple: how do I post x-www-form-urlencoded content with Aurelia Fetch client?
I need to make the post to a simple ASP.NET Web API server that is using OWIN and Katana for authentication.
An example of what I have already tried:
var…

Tarps
- 1,928
- 1
- 11
- 27
2
votes
1 answer
CORS errors on Azure Translator API (Cognitive Services) when using Aurelia's Fetch Client
I try to use a very basic API call from Windows Azure to translate some texts. They gives a quickstart example code.
I try this code and it works pretty well. The text Hello world is translated into deutch and italian.
I removed my personal…

Bronzato
- 9,438
- 29
- 120
- 212
2
votes
1 answer
Uploading images using aurelia to asp.net core backend
I have been searching for a solution for this but none of the guides are updated or suited for my intention. I need a user uploaded image to be loaded into javascript/aurelia which then sends it to the asp.net core backend using its http fetch…

Blaze
- 55
- 1
- 8
2
votes
0 answers
Best practices for interceptor implementation in Aurelia
What is the recommended (general) approach for implementing interceptor's logic in Aurelia?
Aurelia doc states following for fetch interceptor's request method:
request [method] takes the Request that will be passed to window.fetch() after…

matthery
- 31
- 3
2
votes
1 answer
CORS error using Aurelia Fetch client
I'm using Aurelia Fetch Client to query my own Slim Framework RESTful API. The API includes the correct header (as verified by Postman):
Access-Control-Allow-Headers →X-Requested-With, Content-Type, Accept, Origin,…

LStarky
- 2,740
- 1
- 17
- 47
2
votes
2 answers
Redirect to login page if server returns 401 response
How can I intercept the server endpoint response and redirect an aurelia application to login page if is a 401 response?
I tried "withInterceptor(responseError() {...})" method of aurelia-fetch-client config, but I cannot return a "new…

Flávio Alves
- 35
- 4
2
votes
0 answers
Aurelia fetch-client throws 401 for post requests
I'm facing an issue while trying to make httpPost request.
It always returns 401 Unauthorized error.
We are using token based authentication from our server(Apache Tomcat7) with SpringSecurity plugin for generating authToken.
Below is how I…

Jaswanth K
- 21
- 1
1
vote
1 answer
Aurelia Fetch Client Caching URL
I have an Aurelia app using HttpFetch from aurelia-fetch-client v1.8.2. The problem I'm experiencing is that the Chrome browser is caching some GET request URLs between my deployments.
E.g. one particular request would go to .../api/v1/users but has…

JP Damstra
- 545
- 7
- 25
1
vote
2 answers
Aurelia fetch client not receiving data from controller
I'm trying to load a database in a controller(asp.net MVC) and then using the aurelia fetch client to load the data from the controller into the view but no data is being fetched by aurelia(view tables are empty which isn't the result when manually…

Blaze
- 55
- 1
- 8