Expose a service port on the public IP
POST
/deployments/{deploymentId}/services/{serviceId}/ports/{portId}/public
const url = 'https://example.com/deployments/example/services/example/ports/example/public';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"additionalProperty":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/deployments/example/services/example/ports/example/public \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "additionalProperty": "example" }'Auth: authenticated (scope: deploy)
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”deploymentId
required
string
serviceId
required
string
portId
required
string
Request Body
Section titled “Request Body”Media typeapplication/json
object
key
additional properties
Example generated
{ "additionalProperty": "example"}Responses
Section titled “Responses”OK
Media typeapplication/json
object
enabled
required
boolean
host
required
string
ip
required
string
port
required
number
protocol
required
string
key
additional properties
Example generated
{ "enabled": true, "host": "example", "ip": "example", "port": 1, "protocol": "example"}