Create an Elastic IP

POST /elastic-ip
application/json

Body Required

  • Elastic IP address family (default: :inet4)

    Values are inet4 or inet6.

  • Elastic IP description

    Maximum length is 255.

  • healthcheck elastic-ip-healthcheck

    Elastic IP healthcheck

    Hide healthcheck attributes Show healthcheck attributes
    • strikes-ok integer(int64)

      Number of attempts before considering the target healthy (default: 2)

      Minimum value is 1, maximum value is 20.

    • Skip TLS verification

    • tls-sni string

      An optional domain or subdomain to check TLS against

      Minimum length is 1, maximum length is 255.

    • strikes-fail integer(int64)

      Number of attempts before considering the target unhealthy (default: 3)

      Minimum value is 1, maximum value is 20.

    • mode string Required

      Health check mode

      Values are tcp, http, or https.

    • port integer(int64) Required

      Health check port

      Minimum value is 1, maximum value is 65535.

    • uri string

      An endpoint to use for the health check, for example '/status'

      Minimum length is 1, maximum length is 255.

    • interval integer(int64)

      Interval between the checks in seconds (default: 10)

      Minimum value is 5, maximum value is 300.

    • timeout integer(int64)

      Health check timeout value in seconds (default: 2)

      Minimum value is 2, maximum value is 60.

  • labels labels

    Resource labels

    Hide labels attribute Show labels attribute

Responses

  • 200 application/json

    200

    Hide response attributes Show response attributes operation
    • id string(uuid)

      Operation ID

    • reason string

      Operation failure reason

      Values are incorrect, unknown, unavailable, forbidden, busy, fault, partial, not-found, interrupted, unsupported, or conflict.

    • Related resource reference

      Hide reference attributes Show reference attributes
      • id string(uuid)

        Reference ID

      • command string

        Command name

    • message string

      Operation message

    • state string

      Operation status

      Values are failure, pending, success, or timeout.

POST /elastic-ip
curl \
 -X POST https://api-ch-gva-2.exoscale.com/v2/elastic-ip \
 -H "Content-Type: application/json" \
 -d '{"addressfamily":"inet4","description":"string","healthcheck":{"strikes-ok":42,"tls-skip-verify":true,"tls-sni":"string","strikes-fail":42,"mode":"tcp","port":42,"uri":"string","interval":42,"timeout":42},"labels":{}}'
Request example
{
  "addressfamily": "inet4",
  "description": "string",
  "healthcheck": {
    "strikes-ok": 42,
    "tls-skip-verify": true,
    "tls-sni": "string",
    "strikes-fail": 42,
    "mode": "tcp",
    "port": 42,
    "uri": "string",
    "interval": 42,
    "timeout": 42
  },
  "labels": {}
}
Response examples (200)
{
  "id": "string",
  "reason": "incorrect",
  "reference": {
    "id": "string",
    "link": "string",
    "command": "string"
  },
  "message": "string",
  "state": "failure"
}