Class ReservedAddrs.CreateCallBuilder

java.lang.Object
com.ngrok.services.ReservedAddrs.CreateCallBuilder
Enclosing class:
ReservedAddrs

public class ReservedAddrs.CreateCallBuilder extends Object
A builder object encapsulating state for an unsent Create API call.
  • Method Details

    • description

      public ReservedAddrs.CreateCallBuilder description(String description)
      human-readable description of what this reserved address will be used for
      Parameters:
      description - the value of the description parameter as a String
      Returns:
      the call builder instance
    • description

      public ReservedAddrs.CreateCallBuilder description(Optional<String> description)
      human-readable description of what this reserved address will be used for
      Parameters:
      description - the value of the description parameter as an Optional of String
      Returns:
      the call builder instance
    • metadata

      public ReservedAddrs.CreateCallBuilder metadata(String metadata)
      arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.
      Parameters:
      metadata - the value of the metadata parameter as a String
      Returns:
      the call builder instance
    • metadata

      public ReservedAddrs.CreateCallBuilder metadata(Optional<String> metadata)
      arbitrary user-defined machine-readable data of this reserved address. Optional, max 4096 bytes.
      Parameters:
      metadata - the value of the metadata parameter as an Optional of String
      Returns:
      the call builder instance
    • region

      public ReservedAddrs.CreateCallBuilder region(String region)
      reserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa)
      Parameters:
      region - the value of the region parameter as a String
      Returns:
      the call builder instance
    • region

      public ReservedAddrs.CreateCallBuilder region(Optional<String> region)
      reserve the address in this geographic ngrok datacenter. Optional, default is us. (au, eu, ap, us, jp, in, sa)
      Parameters:
      region - the value of the region parameter as an Optional of String
      Returns:
      the call builder instance
    • endpointConfigurationId

      public ReservedAddrs.CreateCallBuilder endpointConfigurationId(String endpointConfigurationId)
      ID of an endpoint configuration of type tcp that will be used to handle inbound traffic to this address
      Parameters:
      endpointConfigurationId - the value of the endpoint_configuration_id parameter as a String
      Returns:
      the call builder instance
    • endpointConfigurationId

      public ReservedAddrs.CreateCallBuilder endpointConfigurationId(Optional<String> endpointConfigurationId)
      ID of an endpoint configuration of type tcp that will be used to handle inbound traffic to this address
      Parameters:
      endpointConfigurationId - the value of the endpoint_configuration_id parameter as an Optional of String
      Returns:
      the call builder instance
    • call

      public CompletionStage<ReservedAddr> call()
      Initiates the API call asynchronously.
      Returns:
      a CompletionStage of ReservedAddr
    • blockingCall

      public ReservedAddr blockingCall() throws InterruptedException
      Initiates the API call and blocks until it returns.
      Returns:
      ReservedAddr
      Throws:
      InterruptedException - if the thread was interrupted during the call