mirror of
https://github.com/ovh/python-ovh.git
synced 2026-01-16 23:00:21 +00:00
Fix some type after @yadutaf review
Signed-off-by: Vincent Casse <vincent.casse@corp.ovh.com>
This commit is contained in:
parent
f370622dbb
commit
fd555151d2
3 changed files with 7 additions and 7 deletions
|
|
@ -1,11 +1,11 @@
|
|||
Python wrapper examples
|
||||
-----------------------
|
||||
|
||||
In this part, you can find and share real use cases for the OVH python wrapper
|
||||
In this part, you can find real use cases for the OVH Python wrapper
|
||||
|
||||
## OVH services
|
||||
|
||||
Following examples are related to cross services proposed by OVH.
|
||||
|
||||
- [How to get services that will expired soon?](serviceExpiration/api_get_service_that_expired_soon.md)
|
||||
- [How to get the list of services expiring soon?](serviceExpiration/api_get_service_that_expired_soon.md)
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
How to get services that will expired soon with python wrapper?
|
||||
---------------------------------------------------------------
|
||||
How to get list of services expiring soon with Python wrapper?
|
||||
--------------------------------------------------------------
|
||||
|
||||
This documentation will help you to know what services will be expired soon and need to be renew. Following script will check each of your OVH services and check expiration date.
|
||||
This documentation will help you to list what services will be expired soon and need to be renew. The following script will check the expiration date of each services attached to your consumer_key
|
||||
|
||||
## Requirements
|
||||
|
||||
|
|
@ -39,7 +39,7 @@ If you need a more generic token, you may adjust the **Rights** fields at your n
|
|||
|
||||
## Download the script
|
||||
|
||||
- Download and edit the python file to get service that will expired. You can download [this file](serviceThatWillExpired.py). By default, delay is defined as 60 days. You can edit the script to change the delay.
|
||||
- Download and edit the python file to get service that will expired. You can download [this file](serviceThatWillExpired.py). By default, delay is defined as 60 days. You can edit the script to change the ```delay```.
|
||||
|
||||
## Run script
|
||||
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ delay_date = datetime.datetime.now() + datetime.timedelta(days=delay)
|
|||
|
||||
services_will_expired = []
|
||||
|
||||
# Checking all OVH product (service type)
|
||||
# Check all OVH product (service type)
|
||||
for service_type in service_types:
|
||||
service_list = client.get('/%s' % service_type )
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue