Class PingApi


public class PingApi extends JenkinsAppApi<PingResponse>
  • Constructor Details

    • PingApi

      @Inject public PingApi(okhttp3.OkHttpClient httpClient, com.fasterxml.jackson.databind.ObjectMapper objectMapper)
  • Method Details

    • sendPing

      public boolean sendPing(String webhookUrl, String secret, PipelineLogger pipelineLogger)
      Sends a "ping" to the Jenkins app. The Jenkins app will return true only if it could successfully validate the JWT that contains the payload (i.e. only if the shared secret is the same on both sides). This effectively tests if the connection between Jenkins plugin and app is valid.