# Get model "schema" in v2

**URL:** <https://discourse.getcockpit.com/t/get-model-schema-in-v2/3180>\
**Category:** Uncategorized\
**Created:** [April 17, 2025, 3:09pm UTC](https://discourse.getcockpit.com/t/get-model-schema-in-v2/3180 "2025-04-17T15:09:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sephen](https://avatars.discourse-cdn.com/v4/letter/s/ee7513/32.png) [@Sephen](https://discourse.getcockpit.com/u/Sephen)\
**Post date:** [April 17, 2025, 3:09pm UTC](https://discourse.getcockpit.com/t/get-model-schema-in-v2/3180/1 "2025-04-17T15:09:03Z")

</div>

In V1 you could get the collection overview “schema” via  
[example.com/db/api/collections/collection/addresses](http://example.com/db/api/collections/collection/addresses)

How can i achieve this in v2?

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![Sacha](https://avatars.discourse-cdn.com/v4/letter/s/c0e974/32.png) [@Sacha](https://discourse.getcockpit.com/u/Sacha)\
**Post date:** [May 20, 2025, 8:53am UTC](https://discourse.getcockpit.com/t/get-model-schema-in-v2/3180/2 "2025-05-20T08:53:22Z")

</div>

Hi Sephen, you can do a custom addon.  
Create api endpoint like ‘/schema-provider/schema/{model}’ to get schema of collection.

```auto
class SchemaProvider extends \Lime\Helper {
    public function getSchemas(){
        return $this->module('content')->models(false);
    }

    public function getSchema($model){
        return $this->module('content')->model($model);
    }
}

```

tell me if you need more.
