Projects actions
CreateProject
The CreateProject
method sends a request to create a project.
Parameters:
-
Name (required): The name of the NeoLoad project.
-
DirectoryPath (optional): The location of the project. By default projects are created in NeoLoad projects folder.
-
Overwrite (optional): Default value is false. If set to true, an existing project with the same name and location is deleted.
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/CreateProject HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:59
{"d": {
"Name": "my_project",
"Overwrite": true
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command CreateProject -Name my_project -Overwrite true

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
import com.neotys.rest.design.model.CreateProjectParams.CreateProjectParamsBuilder;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
client.createProject(new CreateProjectParamsBuilder()
.name("my_project")
.overwrite(true)
.build());
}
}

using Neotys.DesignAPI.Client;
using Neotys.DesignAPI.Model;
namespace Design
{
class CreateProject
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
client.CreateProject(new CreateProjectParamsBuilder()
.name("my_project")
.overwrite(true)
.Build());
}
}
}
OpenProject
The OpenProject
method sends a request to open a project.
Parameters:
-
FilePath (required): The path to the NLP file.
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/OpenProject HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:109
{"d": {
"FilePath": "C:\Users\apaul\Documents\NeoLoad Projects\v5.3\Sample_Project\Sample_Project.nlp"
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command OpenProject -FilePath "C:\Users\apaul\Documents\NeoLoad Projects\v5.3\Sample_Project\Sample_Project.nlp"

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
import com.neotys.rest.design.model.OpenProjectParams.OpenProjectParamsBuilder;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
client.openProject(new OpenProjectParamsBuilder().filePath("C:\\Users\\apaul\\Documents\\NeoLoad Projects\\v5.3\\Sample_Project\\Sample_Project.nlp")
.build());
}
}

using Neotys.DesignAPI.Client;
using Neotys.DesignAPI.Model;
namespace Design
{
class OpenProject
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
client.OpenProject(new OpenProjectParamsBuilder()
.filePath(@"C:\Users\apaul\Documents\NeoLoad Projects\v5.3\Sample_Project\Sample_Project.nlp")
.Build());
}
}
}
SaveProject
The SaveProject
method sends a request to save a project.
Parameters:
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/SaveProject HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:9
{"d": {
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command SaveProject

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
client.saveProject();
}
}

using Neotys.DesignAPI.Client;
namespace Design
{
class SaveProject
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
client.SaveProject();
}
}
}
SaveAsProject
The SaveAsProject
method sends a request to work on a copy of the current project.
Parameters:
-
Name (required): The name of the NeoLoad project.
-
DirectoryPath (optional): The location of the project. By default projects are created in NeoLoad projects folder.
-
Overwrite (optional): Default value is false. If set to true, an existing project with the same name and location is deleted.
-
ForceStop (optional): Default value is false. If set to true, running tests and recordings are stopped.
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/SaveAsProject HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:102
{"d": {
"Name": "my_copy",
"DirectoryPath": "C:\\Users\\apaul\\backup",
"ForceStop": true
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command SaveAsProject -Name my_copy -DirectoryPath "C:\\Users\\apaul\\backup" -ForceStop true

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
import com.neotys.rest.design.model.SaveAsProjectParams.SaveAsProjectParamsBuilder;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
client.saveAsProject(new SaveAsProjectParamsBuilder()
.name("my_copy")
.forceStop(true)
.directoryPath("C:\\Users\\apaul\\backup")
.build());
}
}

using Neotys.DesignAPI.Client;
using Neotys.DesignAPI.Model;
namespace Design
{
class SaveAsProject
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
client.SaveAsProject(new SaveAsProjectParamsBuilder()
.name("my_copy")
.forceStop(true)
.directoryPath("C:\\Users\\apaul\\backup")
.Build());
}
}
}
CloseProject
The CloseProject
method sends a request to close the current project.
Parameters:
-
Save (optional): Default value is true. If set to false, current project is not saved.
-
ForceStop (optional): Default value is false. If set to true, running tests and recordings are stopped.
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/CloseProject HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:46
{"d": {
"Save": true,
"ForceStop": true
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command CloseProject -Save true -ForceStop true

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
import com.neotys.rest.design.model.CloseProjectParams.CloseProjectParamsBuilder;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
client.closeProject(new CloseProjectParamsBuilder()
.forceStop(true)
.save(true)
.build());
}
}

using Neotys.DesignAPI.Client;
using Neotys.DesignAPI.Model;
namespace Design
{
class CloseProject
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
client.CloseProject(new CloseProjectParamsBuilder()
.forceStop(true)
.save(true)
.Build());
}
}
}
GetStatus
The GetStatus
method provides the current status of NeoLoad:
-
NEOLOAD_INITIALIZING: NeoLoad is starting up.
-
NO_PROJECT: No project is opened.
-
PROJECT_INITIALIZING: A project is getting opened.
-
READY: Project is opened, NeoLoad is ready to start a test.
-
BUSY: NeoLoad is busy (a recording is in progress or stopping or there is a blocking window), a test can't be started.
-
TEST_LOADING: The test is getting started.
-
TEST_RUNNING: The test is running.
-
TEST_STOPPING: The test is getting stopped.
Parameters:
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/GetStatus HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:9
{"d": {
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command GetStatus

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
import com.neotys.rest.runtime.model.Status;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
final Status status = client.getStatus();
System.out.println(status);
}
}

using Neotys.DesignAPI.Client;
using Neotys.DesignAPI.Model;
using System;
namespace Design
{
class getStatus
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
Status status = client.GetStatus();
Console.WriteLine(status);
}
}
}
ContainsUserPath
The ContainsUserPath
method allows to know if a User Path already exists.
Parameters:
-
Name (required): The name of the User Path.
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/ContainsUserPath HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:25
{"d": {
"Name": "my_user_path"
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command ContainsUserPath -Name my_user_path

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
import com.neotys.rest.design.model.ContainsUserPathParams;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
final boolean exist = designAPIClient.containsUserPath(
new ContainsUserPathParams.ContainsUserPathParamsBuilder().name("my_user_path").build());
System.out.println(exist);
}
}

using Neotys.DesignAPI.Client;
using Neotys.DesignAPI.Model;
using System;
namespace Design
{
class ContainsUserPath
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
bool exist = client.ContainsUserPath(new ContainsUserPathParamsBuilder()
.name("my_user_path")
.Build());
Console.WriteLine(exist);
}
}
}
IsProjectOpen
The IsProjectOpen
method allows to know if a Project is already open.
Parameters:
-
FilePath (required): The path to the NLP file.
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/IsProjectOpen HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:25
{"d": {
"FilePath": "C:\Users\apaul\Documents\NeoLoad Projects\v5.3\Sample_Project\Sample_Project.nlp"
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command ContainsUserPath -FilePath "C:\Users\apaul\Documents\NeoLoad Projects\v5.3\Sample_Project\Sample_Project.nlp"

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
import com.neotys.rest.design.model.ContainsUserPathParams;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
final boolean isOpen = client.isProjectOpen(new IsProjectOpenParams.IsProjectOpenParamsBuilder().filePath("C:\\Users\\apaul\\Documents\\NeoLoad Projects\\v5.3\\Sample_Project\\Sample_Project.nlp")
.build());
System.out.println(isOpen);
}
}

using Neotys.DesignAPI.Client;
using Neotys.DesignAPI.Model;
using System;
namespace Design
{
class getStatus
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
bool isOpen = client.IsProjectOpen(new IsProjectOpenParamsBuilder()
.filePath(@"C:\Users\apaul\Documents\NeoLoad Projects\v5.3\Sample_Project\Sample_Project.nlp")
.Build());
Console.WriteLine(isOpen);
}
}
}
Exit
The Exit
method sends a request to close NeoLoad. A project must have been closed first.
Parameters:
-
ApiKey (optional): To authenticate the command. Required if enabled on the Controller.

POST http://localhost:7400/Design/v1/Service.svc/Exit HTTP/1.1
Accept: application/json
Content-Type:application/json
Cache-Control:nocache
Pragma: nocache
User-Agent:Java/1.7.0_10
Host: localhost:7400
Connection: keepalive
Content-Length:9
{"d": {
}}

java -cp "api/Common/java/*;api/Design API Client/java/*" com.neotys.rest.design.client.CommandLineDesigner -designAPIURL http://localhost:7400/Design/v1/Service.svc/ -command Exit

import com.neotys.rest.design.client.DesignAPIClient;
import com.neotys.rest.design.client.DesignAPIClientFactory;
public class Main {
public static void main(String[] args) throws Exception {
final String url = "http://localhost:7400/Design/v1/Service.svc";
final DesignAPIClient client = DesignAPIClientFactory.newClient(url);
client.exit();
}
}

using Neotys.DesignAPI.Client;
namespace Design
{
class ExitExample
{
static void Main(string[] args)
{
string url = "http://localhost:7400/Design/v1/Service.svc/";
IDesignAPIClient client = DesignAPIClientFactory.NewClient(url);
client.Exit();
}
}
}