vertx / io.vertx.reactivex.servicediscovery.types / HttpEndpoint / createRecord

# createRecord

`open static fun createRecord(name: String, host: String, port: Int, root: String, metadata: JsonObject): Record`

Convenient method to create a record for a HTTP endpoint.

### Parameters

`name` - the service name

`host` - the host (IP or DNS name), it must be the _public_ IP / name

`port` - the port, it must be the _public_ port

`root` - the path of the service, "/" if not set

`metadata` - additional metadata

Return
the created record

`open static fun createRecord(name: String, ssl: Boolean, host: String, port: Int, root: String, metadata: JsonObject): Record`

Same as `io.vertx.reactivex.servicediscovery.types.HttpEndpoint#createRecord` but let you configure whether or not the service is using `https`.

### Parameters

`name` - the service name

`ssl` - whether or not the service is using HTTPS

`host` - the host (IP or DNS name), it must be the _public_ IP / name

`port` - the port, it must be the _public_ port

`root` - the path of the service, "/" if not set

`metadata` - additional metadata

Return
the created record

`open static fun createRecord(name: String, host: String, port: Int, root: String): Record`

Same as `io.vertx.reactivex.servicediscovery.types.HttpEndpoint#createRecord` but without metadata.

### Parameters

`name` - the service name

`host` - the host, must be public

`port` - the port

`root` - the root, if not set "/" is used

Return
the created record

`open static fun createRecord(name: String, host: String): Record`

Same as `io.vertx.reactivex.servicediscovery.types.HttpEndpoint#createRecord` but without metadata, using the port 80 and using "/" as root.

### Parameters

`name` - the name

`host` - the host

Return
the created record