ovh / python-ovh

Thin wrapper around OVH's APIs. Handles all the hard work including credential creation and requests signing.
https://pypi.org/project/ovh/
Other
278 stars 76 forks source link

ovh.exceptions.APIError: Service is temporarily unavailable #47

Closed Juli4nAc0sta closed 7 years ago

Juli4nAc0sta commented 7 years ago

i have this code to add vps server item in my cart:

client.post('/order/cart/{cartid}/vps',
                  duration='PT18.179651S',
                  planCode='vps_ceph-nvme_model3',
                  pricingMode='default',
                  quantity=1)

But the answer gives me the following error: ovh.exceptions.APIError: Service is temporarily unavailable OVH-Query-ID: CA.ws-2.592b81b1.10921.5307

geoffreybauduin commented 7 years ago

Hey,

this is probably because your duration looks wrong. If you want to order for 1 month, you should specify duration="P1M". Duration parameter follows the ISO 8601.