> ## Documentation Index
> Fetch the complete documentation index at: https://docs.generalrobotics.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# GRIDType

> Abstract base class for all GRID Robot API types

```python theme={null}
from grid_types import GRIDType
```

Abstract base class for all GRID Robot API types.

All serializable types used as return values in the GRID Robot API
should inherit from this class and implement to\_dict() and from\_dict().

## Methods

### `from_dict()`

```python Signature theme={null}
from_dict(data: dict) -> GRIDType
```

Deserialize from dictionary. Please ensure any nested types
are also deserialized correctly or are converted from a serializable format in this method.

<ParamField body="data" type="dict" required>
  Dictionary containing serialized object data
</ParamField>

**Returns:**

GRIDType: Reconstructed object

### `to_dict()`

```python Signature theme={null}
to_dict() -> dict
```

Serialize to dictionary for JSON transfer. Please ensure any nested types
are also JSON serializable or are converted to a serializable format in this method.

**Returns:**

dict: Dictionary representation of the object


## Related topics

- [grid-types](/v2.2/python-api/grid-types/overview.md)
- [ImageType](/v2.2/python-api/grid-types/imagetype.md)
- [Image](/v2.2/python-api/grid-types/image.md)
- [Force](/v2.2/python-api/grid-types/force.md)
- [Orientation](/v2.2/python-api/grid-types/orientation.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.