# fyi.opensocial.listListedTemplates

> Published by [lexicons.opensocial.fyi](https://lexicon.garden/identity/did:plc:2gqnilpksz2e7faj3bwvo6qc)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:2gqnilpksz2e7faj3bwvo6qc/fyi.opensocial.listListedTemplates)
- [Documentation](https://lexicon.garden/lexicon/did:plc:2gqnilpksz2e7faj3bwvo6qc/fyi.opensocial.listListedTemplates/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:2gqnilpksz2e7faj3bwvo6qc/fyi.opensocial.listListedTemplates/examples)

## Definitions

### `fyi.opensocial.listListedTemplates#listedView`

**Type**: `object`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `description` | `string` | Yes |  |
| `icon` | `string` | No | Its icon, as a square SVG. |
| `keptBy` | `integer` | Yes | How many groups on this host have a tab of it now. |
| `likes` | `integer` | Yes |  |
| `maker` | `ref` → `fyi.opensocial.getTemplateListing#makerView` | Yes |  |
| `name` | `string` | Yes | What it's called. |
| `number` | `integer` | Yes | Its latest version's number. |
| `summary` | `string` | No | One short line on what a tab of it shows. |
| `updatedAt` | `string` (datetime) | Yes | When its latest version came out. |
| `uri` | `string` (at-uri) | Yes |  |

### `fyi.opensocial.listListedTemplates`

**Type**: `query`

Templates shared with everyone that this host lists, for anyone looking for something to add to their group: each one whoever made it asked to be listed, kept by enough groups on this host for long enough, its latest version scanned with nothing found, and nothing labelling it hidden. Counts are from this host alone.

#### Parameters

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `cursor` | `string` | No |  |
| `limit` | `integer` | No |  |
| `q` | `string` | No | Words to find in what it's called and what it's for. |
| `sort` | `string` | No | Kept by the most groups first, newest first, or most liked first. |

#### Output

**Encoding**: `application/json`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `cursor` | `string` | No |  |
| `templates` | `array` | Yes |  |

## Raw Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "listedView": {
      "properties": {
        "description": {
          "type": "string"
        },
        "icon": {
          "description": "Its icon, as a square SVG.",
          "type": "string"
        },
        "keptBy": {
          "description": "How many groups on this host have a tab of it now.",
          "minimum": 0,
          "type": "integer"
        },
        "likes": {
          "minimum": 0,
          "type": "integer"
        },
        "maker": {
          "ref": "fyi.opensocial.getTemplateListing#makerView",
          "type": "ref"
        },
        "name": {
          "description": "What it's called.",
          "type": "string"
        },
        "number": {
          "description": "Its latest version's number.",
          "minimum": 1,
          "type": "integer"
        },
        "summary": {
          "description": "One short line on what a tab of it shows.",
          "type": "string"
        },
        "updatedAt": {
          "description": "When its latest version came out.",
          "format": "datetime",
          "type": "string"
        },
        "uri": {
          "format": "at-uri",
          "type": "string"
        }
      },
      "required": [
        "uri",
        "name",
        "description",
        "maker",
        "number",
        "keptBy",
        "likes",
        "updatedAt"
      ],
      "type": "object"
    },
    "main": {
      "description": "Templates shared with everyone that this host lists, for anyone looking for something to add to their group: each one whoever made it asked to be listed, kept by enough groups on this host for long enough, its latest version scanned with nothing found, and nothing labelling it hidden. Counts are from this host alone.",
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "cursor": {
              "type": "string"
            },
            "templates": {
              "items": {
                "ref": "#listedView",
                "type": "ref"
              },
              "type": "array"
            }
          },
          "required": [
            "templates"
          ],
          "type": "object"
        }
      },
      "parameters": {
        "properties": {
          "cursor": {
            "type": "string"
          },
          "limit": {
            "default": 50,
            "maximum": 100,
            "minimum": 1,
            "type": "integer"
          },
          "q": {
            "description": "Words to find in what it's called and what it's for.",
            "maxLength": 200,
            "type": "string"
          },
          "sort": {
            "default": "kept",
            "description": "Kept by the most groups first, newest first, or most liked first.",
            "knownValues": [
              "kept",
              "newest",
              "liked"
            ],
            "type": "string"
          }
        },
        "type": "params"
      },
      "type": "query"
    }
  },
  "id": "fyi.opensocial.listListedTemplates",
  "lexicon": 1
}
```
