You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I get the following feedback:
The remote server returned a "400 Bad Request" error for the following transaction:
Request
~~~~~~~
POST /v2.0/floatingips HTTP/1.1
User-Agent: GuzzleHttp/6.5.1 curl/7.64.1 PHP/7.3.11
Content-Type: application/json
Host: xxxxxxx.com:13696
{"floatingip":{"floating_network_id":"exxxx-xxxx-xxxxx-9xx7-xxxxxxx"}}
Response
~~~~~~~~
HTTP/1.1 400 Bad Request
Content-Type: application/json
Content-Length: 170
X-Openstack-Request-Id: req-exxxx-xxxx-xxxx-xxxx-xxx2xxxx3x
Date: Thu, 02 Apr 2020 13:09:53 GMT
Further information
~~~~~~~~~~~~~~~~~~~
Please ensure that your input values are valid and well-formed. Visit
http://docs.php-opencloud.com/en/latest/http-codes for more information about debugging HTTP status codes, or
file a support issue on https://github.com/php-opencloud/openstack/issues.
Can someone help me? How far I found this route is not in the documentation.
Hi, @ntorga good point. I just want to add that you would typically need to specify fixedIpAddress or portId.
A full example can be seen here in our floatingIps integration test which tests the complete flow from creating an external Network to assigning floating IP.
Activity
ntorga commentedon Apr 2, 2020
"400 Bad Request" when creating floating IP addresses has 4 possible explanations as explained on the documentation:
https://docs.openstack.org/api-ref/network/v2/?expanded=create-floating-ip-detail
As long as your networks are correctly configured, you are likely trying to create a floating IP inside a private network. I would recommend list all networks via "https://docs.openstack.org/api-ref/network/v2/?expanded=#list-networks" and check the "router:external" prop.
haphan commentedon Apr 3, 2020
Hi, @ntorga good point. I just want to add that you would typically need to specify
fixedIpAddressorportId.A full example can be seen here in our floatingIps integration test which tests the complete flow from creating an external Network to assigning floating IP.