Forum Discussion

smartbearuser's avatar
smartbearuser
Occasional Contributor
8 years ago

how to add a REST service(from an exsited project) to a new project by groovy in SoapUI Pro

requirement:

1. have an old project with many REST API in it

2.want to extract some of the REST API into a new project.

 

 

I know I can do it manually, but I want them automatically.

I can get my needed REST API's service, resource, method using groovy, but I don't know how to add them into my new project. 

 

RestService restService = myRestRequest.getResource().getInterface();
RestResource resource =myRestRequest.getResource();

 

then I don't know how to do next????

1 Reply

  • testhrishi's avatar
    testhrishi
    Frequent Contributor

    How about just perform the SAVE-AS for this project to create a copy of the project and then delete what ever you don't need in this new project