# Heartbeat services (HeartbeatWsV2)
Provides a service method to ping our server. It is useful to test connectivity and authentication.
* **Type**: SOAP
* **Production WSDL**: https://services.generali.gr/soap/v2/heartbeat?wsdl
* **Test WSDL**: https://services-test.generali.gr/soap/v2/heartbeat?wsdl
##ping
Pings the server.
###Input
Type | Description
---- | -----------
*(nothing)* | *---*
### Output
Type | Description
---- | -----------
String | Up and running message
### Example 1
#### Input
```
```
#### Output
```
Welcome ws-00000425Blvdz, we are up and running!
```
#### Client (Java)
Example of a simple Java client. Notice the exact naming of the classes depends on your client generator and it could be slightly different than the following.
```
package examples;
import gr.generali.gbox.api.ws.soap.HeartbeatWs;
import gr.generali.gbox.api.ws.soap.HeartbeatLocator;
import java.util.Map;
import javax.xml.ws.BindingProvider;
public class Example1 {
public static void main(String[] args) {
HeartbeatLocator locator = new HeartbeatLocator();
HeartbeatWs service = locator.getHeartbeatWsPort();
// Authentication
Map context = ((BindingProvider)service).getRequestContext();
context.put(BindingProvider.USERNAME_PROPERTY, "ws-00000425Blvdz");
context.put(BindingProvider.PASSWORD_PROPERTY, "5wPkZtXu2g-test");
// Execution
String message = service.ping();
// Result
System.out.println(message);
}
}
```
Being the output:
Welcome ws-00000425Blvdz, we are up and running!