Skip to main content

Attach Public IP

POST/api/v1/reserve_ips/public_reserveip_actions/

Query parameters

  • project_idQuerystringoptional

    Identifier of the project to scope the request to. Optional; if omitted, the account's default project is used.

    • optional
    • if omitted, the request is applied to the default project
    example{{project_id}}
  • apikeyQuerystringoptional

    API key used to authenticate the request

    • required
    • non-empty string
    example{{api_key}}
  • locationQuerystringoptional

    Specifies the geographic region for attaching the public IP.

    • required
    • must be a valid region identifier
    example{{location}}

Request body

application/json

string

JSON string containing the attach public IP request payload

example{ "public_ip": {{public_ip}}, "type": "attach", "vm_id": {{vm_id}} }
  • must be a valid JSON object string
  • required fields: public_ip, type, vm_id
  • type field must be "attach"

Responses

200Successful response
object
codeinteger

HTTP status code of the Attach Public IP response

example200
  • must be an integer representing an HTTP status code
  • value should be between 100 and 599
dataobject
errorsobject
messagestring

Human-readable status message for the attach public IP operation.

exampleIP assigned Successfully.
  • Must be a non-empty string
  • Maximum length 256 characters