Questions tagged [rest]

REST (Representational State Transfer) is a style of software architecture for distributed hypermedia systems such as the World Wide Web. It has increased in popularity relative to RPC architectures such as SOAP due to the intrinsic de-coupling of client from server that comes from having a uniform ...

0
votes
0answers
6 views

@RestController with StreamingResponseBody async.request-timeout not working

I'm trying to get a StreamingResponseBody from a @RestController on a long running job. It times out after 30 seconds, no matter what configuration I try. This is in Spring Boot 2.0.3. I've used the ...
0
votes
0answers
7 views

What framework Google, Microsoft, FB use to document their REST APIs

I am using Swagger for REST API documentation which is built using Spring Framework. I am looking for better alternatives where I don't need to define complex resources again and again in every API. ...
0
votes
0answers
9 views

Wildfly 14 - Cannot map RESTeasy exceptions with javax.ws.rs.ext.ExceptionMapper

I am working on migration of a REST api from Wildfly10 to Wildfly14. Wildfly10 used RESTeasy of an older version where some exceptions were still build-in, for example BadRequestException and ...
0
votes
2answers
19 views

How to instruct REST API to include additional data for given resource

I've implemented a GET request as followed: https://api.com/invoices?filter[status]=paid&include=client Current situation: Fetch invoices with status 'paid' & include client data for each ...
0
votes
0answers
18 views

REST web service not getting header parameter info

Hi I've created a simple REST web service. I followed the following steps in Netbeans: On project, right click and select New, and then select RESTful web services from patterns I selected json and ...
0
votes
0answers
5 views

Reuse Zend_Controller_Action for REST API

I have a project developed on Zend. I want to create a Restful API without rewriting new controllers. Is it possible to reuse the existing controllers for REST? Is it possible to change ...
1
vote
1answer
26 views

How to improve the performance of a REST call which internally other REST calls

I am creating an endpoint which retrieves me some data and in this call it calls 3 different REST calls and due to this it hampers the performance of my application. My Endpoint Code: 1. REST call ...
-1
votes
0answers
11 views

Unit testing REST get api using mockito

I am trying to write a unit test for my User Controller class, more specifically for this method: @Autowired private UserRepository userRepository; @Autowired private UserService userService; @...
-1
votes
1answer
34 views

how to pass dynamic parameter in the REST API url using golang

I am getting the encoded url from postman (google api). In the url, I have the query written to fetch info from a db. In the query, I have hardcoded the date parameter for which I want to fetch the ...
-4
votes
1answer
26 views

My mobile needs previously entered Gmail account, but I forgot

When reset my Android mobile and then restart, mobile needs to enter the Gmail account which you entered before formatting or reset mobile, but I forgot that account. What should I do?
0
votes
0answers
15 views

Got exponential decimal value while POST request [duplicate]

I have spring model class, controller. In the post request, I have take model class value as a request body. Take a look Employee.java @JsonInclude(Include.NON_NULL) public class Employee { private ...
0
votes
1answer
20 views

Automation testing for RestApi and UI in one application

I have an application in which I need to do UI testing as well as rest Api testing.Could anyone suggest me any testing tool for this. My framework will be data driven. Also, it is 20% UI and 80% rest ...
0
votes
0answers
6 views

Can Integer in URL be typecasted to String in Query Param?

For the request http://xyz/resource?articleid=232&name=John Response getDetails(@QueryParam("articleid") String articleid,(@QueryParam("name") String name){} Is the above Query Parameter ...
0
votes
0answers
13 views

Is it safe to use the Google Drive Rest API from the client browser with javascript?

I have a web application with a database on a VPS with Ubuntu. The idea is to save with the transfer of data that they charge, placing the images of the file of articles in Google Drive, where they do ...
0
votes
0answers
8 views

Get property of Google Sheet API using POSTMAN

I was able to connect to a Google Sheet using REST API and change a value to bold using the following tutorial: https://developers.google.com/sheets/api/samples/formatting However, I did not find a ...
0
votes
0answers
12 views

Do you know any REST generator for nestjs BE nodejs framework?

I've searched and i've found nothing I'm trying to find REST generator to generate controller, service, module etc. from model but it's hopeless Is there are some generator like Gii in Yii2?
0
votes
0answers
28 views

Why does my URL request returns error code 400?

String jsonOutput = null; String urlStr = null; try { String encodedInputText ="query={\"query\":\"" +URLEncoder.encode(question, "UTF-8") + "\""; if(sku !=...
-1
votes
0answers
19 views

What is the best approach to send JSON data to Rest API?

I want to build API request/response that will be an API URL which will 1) Accept JSON as input parameter (e.g. 100 values) and 2) Process data / do some simple calculation on a fly and provide back a ...
0
votes
0answers
18 views

“Server Error Problem” in Node.js API (for android to web server request)

"Server Error" in nodejs api (android to web server request) I am a new node.js learner. I'm doing a project that user are registration by android application, and user details will go to web server. ...
0
votes
1answer
22 views

Returning a dynamic Json in a Rest Service

I'm trying my hand on implementing a simple Restful Web Service using Spring Boot. Currently, I want to parse an XML file to a Json object and return it as the response message. However I'm currently ...
0
votes
0answers
7 views

get rest sub resource link using json is invalid for patch operation

I use json to get the sub resource link and do the patch operation. It returns a 400 bad request error: JsonObject objJsonobj = objJsonRead.readObject(); JsonArray objArray = objJsonobj.getJsonArray("...
0
votes
0answers
6 views

REST service is decoding parameters twice

I have a problem where my REST service host keeps decoding parameters twice. So far i havent found a way to turn that off. For example, if a want to pass the string "test#test" in the browser, i have ...
-1
votes
0answers
29 views

PHP Multiple cURL requests in a loop

Typically I am an ajax/JavaScript guy but I have a project with an API that does not allow me to use client-side api requests so I am stuck using PHP. I have a cURL request that returns a list of ...
0
votes
0answers
6 views

Clockify API: Group Report by Project and aggregate by Task

Calling the REST-Api, I want to get a list of tasks with their corresponding summed tracked time grouped by their project. As an example, if I have the following time entries: 2h, Task1, ProjectA 1h, ...
-2
votes
0answers
7 views

How to implement paging for advanced custom fields pro repeaters with ajax load/rest API?

I'd like to add paging/load more/filtering on my ACF repeaters as they seem to load a lot of data at once which makes my page load times bigger. Can you recommend me the best way/plugin/framework to ...
0
votes
1answer
22 views

Microservices end points accessible on Internet

We have a MicroService based Architecture where each service has a REST End point. These services talk to each other via REST. However I noticed that a lot of developers have directly started ...
1
vote
1answer
19 views

SpringBoot: Is possible deploy my views on https and rest services on 8080 port?

I am starting with spring boot, amd I have a project with jsp views and rest services. All in the same project. Then, when I wanted to deploy, the clients say me that the views, must be in https://...
2
votes
0answers
13 views

nodejs api not working after socket hangup and gets resolved automatically

Nodejs api not working after socket hangup and gets resolved automatically.I have also added res.end() while sending the response Also added connection:close header in request so as to tell server ...
0
votes
0answers
8 views

How to send a file to a S3 with vuejs with a presigned URL?

I wanto upload a file to minio using vuejs. So for I have added the following code to my vue project <template> <div class="app-container"> <h1>Minio Code</h1> <input ...
0
votes
0answers
14 views

Unable to call function within wordpress rest api

I have the following code in my custom Wordpress Rest API. I am getting 500-Internal server error whenever I am enabling the call to function send_mail2. Commenting that , the webservice works ...
0
votes
0answers
15 views

Error with Jersey REST API on tomcat startup

I have a REST webservice project using the below dependency <dependency> <groupId>org.glassfish.jersey.core</groupId> <artifactId>jersey-client</...
0
votes
1answer
27 views

How To upload Images/Files to Firebase storage in Java?

I am working in a functionality where i need to upload an Image/File to firebase storage using java and expose it as an API. I have already achieved this functionality in angular 4 typescript. But now ...
-1
votes
0answers
19 views

How to send Enums with HttpClient to Spring REST service?

I have the following enum class in my Angular 6 project: export enum UserGroup{ USER="USER", ADMIN="ADMIN", } then I have this service method example(id: number, userGroup: UserGroup){ ... ...
-1
votes
1answer
38 views

Required variable Rest

I want to do a request with [POST] and if some field it's null i don't follow to the Service. I want to stop the flow in the Controller. problem is with ModelState.IsValid it returns a true when it ...
1
vote
1answer
13 views

Flash messages for REST API

I want to build REST API using Express. Aside from resources there are endpoints for authentication stuff like signup, signin and user option (the view templates are loaded). It's common practice to ...
0
votes
0answers
19 views

Making Concurrent request to webapi process only the last request in Selfhost Owin

I am writing a connector service which takes the data from one system and put that into other system. It is publish subscribe model for which I have created a web api on selfhost Owin which listens to ...
0
votes
1answer
12 views

RESTEasyClient Request - session, cookie

i've sending the "same" request (a simple get-request) to a server and with Postman all works fine and with RestEasyClient it doesn't (401 Unauthorized)... I looked on both requests by fiddler and ...
0
votes
0answers
14 views

JPQL Authorization

I have to make a validation after fetching a column from an entity using JPQL. The validation is to compare Logged Out time and current time. But while comparing I am getting error, since the returned ...
0
votes
1answer
8 views

Use DataFields in Rest URL in ExtJS to access Context.io API

I have two Question Regarding Rest API in EXTJS. How can I use fields to make rest URL dynamic? How can I add authentication key to access Context.io in my Rest.Proxy? This is my solution, but I ...
1
vote
0answers
17 views

Springboot gzip compressing responses having size less than min-response-size configured

I am trying to implement Gzip response compression in my Springboot Rest API I am using below configuration in my application.properties # Enable response compression server.compression.enabled=true ...
0
votes
1answer
20 views

REST API Create Group TFS 2018 update 3

As stated in the title, I try to create or even list the Groups of the server. Documentation explains with the example command to list all groups: https://vssps.dev.azure.com/fabrikam/_apis/graph/...
0
votes
1answer
34 views

Pass messages between requests with a REST API (JSON, XML, HTML…)

Let's imagine a REST API that can return JSON, XML, HTML and other formats. In case of a browser web client without JavaScript enabled, the API return HTML. Tokens are used for authentication and ...
0
votes
0answers
13 views

Rest Assured - How to check if my firewall is blocking specific URLs

The below URL produces a JSON file in my browser. But when I run the same using Rest Assured, I get a "java.net.ConnectException: Connection timed out: connect" error. How can I make sure that this is ...
0
votes
1answer
13 views

.NET Core REST API Detect Put/Post Field From Request

I have an endpoint for create/update a data object that has 5 fields in its table. There are 5 fields for creation: class A { string field1 string field2 int field3 int field4 ...
0
votes
2answers
20 views

How to add array name in RestFul web services using Jersey

I am using jersey framework for building restful web services. I am returning one arraylist which contains multiple JSONObject as a response. But my queries is ,i want to add array name before ...
0
votes
1answer
18 views

custom param convertors in spring

Is there any custom param convertors in Spring.For example @RequestMapping(value="/getEmployees/{"empName"}") public void getEmployees(@PathVariable("empName") Employee employee) { } The path ...
0
votes
1answer
28 views

Rails receive params as string

I'm building an API with Ruby on Rails. Because of that, I can't force the params to follow sone restriction. Currently, I'm having an error with params that contained a Windows newline, because the ...
1
vote
1answer
21 views

OkHttpClient - Ignore proxy from system properties

I have a web container (Glassfish) with a proxy configured on its system properties for one application. Now i have another application on the same web container and would like to customize proxy ...
-1
votes
1answer
35 views

deserialize json list from Rest server c#

Just a little stuck here, I want to grab "notifications"(list) from the json that is sent back to me from the server. Please see below: {"amountCashback": 0,"amountGratuity": 0, "amountTotal": 0, "...
0
votes
1answer
21 views

Refresh JSON on Flask RESTful

My script prints sensor information (temperature, humidity, barometric pressure) to an LCD screen and also sends it as JSON via Flask RESTful api for other devices to use. The python script below ...