

<!-- WARNING: THIS FILE WAS AUTOGENERATED! DO NOT EDIT! -->

------------------------------------------------------------------------

<a
href="https://github.com/hassoun/ovhmanager/blob/main/ovhmanager/instance.py#L12"
target="_blank" style="float:right; font-size:smaller">source</a>

### GPUInstance

``` python

def GPUInstance(
    client:ovh.client, project_base_url:str, region:str, # OVH GPU Instance region
    name:str, # OVH GPU Instance name
    id:str, # OVH GPU Instance id
    status:str, # OVH GPU Instance status
    gpu_type:str, # OVH GPU Instance gpu_type
    flavor_id:str, # OVH GPU Instance flavor_id
    image_id:str, # OVH GPU Instance image_id
    consumption_mode:str, created:str, # OVH GPU Instance creation date
):

```

*OVH GPU Instance class, enabling to interact with the instance
(start/stop/delete)*

``` python
from ovhmanager.core import OVHGPUManager
client = OVHGPUManager()
client.select_project('PROJECT_ID')
```

    2026-02-11 15:36:09.249 | INFO     | ovhmanager.manager:select_project:87 - Available projects:
    2026-02-11 15:36:09.442 | INFO     | ovhmanager.manager:select_project:95 - Selected project: PROJECT_ID

    1. PROJECT_ID

    <ovhmanager.project.OVHProject>

``` python
instance = GPUInstance(
    client=client.client,
    project_base_url=client.project.base_url,
    region='GRA9', 
    name='test-instance', 
    id='f5f3f3aa-fea9-4f73-a5b5-31c253ee143b',
    status='ACTIVE',
    gpu_type='rtx5000-28',
    flavor_id='c5708c95-f450-43c3-8b56-7d498e7b5d07',
    image_id='8d595649-b9b2-4aeb-a544-a3709abf437f',
    consumption_mode='consumption',
    created='2025-01-11T13:24:03Z')
```

``` python
instance.planCode
```

    'rtx5000-28.consumption'

``` python
instance.display_details()
```

    client: <ovh.client.Client object>
    project_base_url: /cloud/project/PROJECT_ID
    region: GRA9
    name: test-instance
    id: f5f3f3aa-fea9-4f73-a5b5-31c253ee143b
    status: ACTIVE
    gpu_type: rtx5000-28
    flavor_id: c5708c95-f450-43c3-8b56-7d498e7b5d07
    image_id: 8d595649-b9b2-4aeb-a544-a3709abf437f
    consumption_mode: consumption
    planCode: rtx5000-28.consumption
    created: 2025-01-11T13:24:03Z

------------------------------------------------------------------------

<a
href="https://github.com/hassoun/ovhmanager/blob/main/ovhmanager/instance.py#L62"
target="_blank" style="float:right; font-size:smaller">source</a>

### GPUInstance.delete

``` python

def delete(
    
):

```

*Enables an OVH GPU instance to delete it’s self*

------------------------------------------------------------------------

<a
href="https://github.com/hassoun/ovhmanager/blob/main/ovhmanager/instance.py#L79"
target="_blank" style="float:right; font-size:smaller">source</a>

### GPUInstance.start

``` python

def start(
    
):

```

*Enables an OVH GPU instance to start it’s self*

------------------------------------------------------------------------

<a
href="https://github.com/hassoun/ovhmanager/blob/main/ovhmanager/instance.py#L96"
target="_blank" style="float:right; font-size:smaller">source</a>

### GPUInstance.stop

``` python

def stop(
    
):

```

*Enables an OVH GPU instance to start it’s self*
