> For the complete documentation index, see [llms.txt](https://dev.guardian.hedera.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dev.guardian.hedera.com/static-spec-test/guardian-policies/suggestions.md).

# Suggestions

## Get next and nested suggested block types

> Get next and nested suggested block types. Only users with the Standard Registry role are allowed to make the request.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"0.0.1"},"tags":[{"name":"suggestions"}],"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"SuggestionsInputDTO":{"type":"object","properties":{"blockType":{"type":"string"},"children":{"nullable":true,"type":"array","items":{"$ref":"#/components/schemas/SuggestionsInputDTO"}}},"required":["blockType","children"]},"SuggestionsOutputDTO":{"type":"object","properties":{"next":{"type":"string"},"nested":{"type":"string"}},"required":["next","nested"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/suggestions":{"post":{"description":"Get next and nested suggested block types. Only users with the Standard Registry role are allowed to make the request.","operationId":"SuggestionsApi_policySuggestions","parameters":[],"requestBody":{"required":true,"description":"Data.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestionsInputDTO"}}}},"responses":{"200":{"description":"Successful operation. Suggested next and nested block types respectively.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestionsOutputDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Get next and nested suggested block types","tags":["suggestions"]}}}}
```

## Get suggestions config

> Get suggestions config. Only users with the Standard Registry role are allowed to make the request.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"0.0.1"},"tags":[{"name":"suggestions"}],"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"SuggestionsConfigDTO":{"type":"object","properties":{"items":{"$ref":"#/components/schemas/SuggestionsConfigItemDTO"}},"required":["items"]},"SuggestionsConfigItemDTO":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["Policy","Module"]},"index":{"type":"number"}},"required":["id","type","index"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/suggestions/config":{"get":{"description":"Get suggestions config. Only users with the Standard Registry role are allowed to make the request.","operationId":"SuggestionsApi_getPolicySuggestionsConfig","parameters":[],"responses":{"200":{"description":"Successful operation. Response suggestions config.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestionsConfigDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Get suggestions config","tags":["suggestions"]}}}}
```

## Set suggestions config

> Set suggestions config. Only users with the Standard Registry role are allowed to make the request.

```json
{"openapi":"3.0.0","info":{"title":"Guardian","version":"0.0.1"},"tags":[{"name":"suggestions"}],"servers":[{"url":"/api/v1","description":"version 1.0"}],"security":[{"bearer":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"SuggestionsConfigDTO":{"type":"object","properties":{"items":{"$ref":"#/components/schemas/SuggestionsConfigItemDTO"}},"required":["items"]},"SuggestionsConfigItemDTO":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","enum":["Policy","Module"]},"index":{"type":"number"}},"required":["id","type","index"]},"UnauthorizedErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]},"ForbiddenErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"},"error":{"type":"string"}},"required":["statusCode","message"]},"InternalServerErrorDTO":{"type":"object","properties":{"statusCode":{"type":"number"},"message":{"type":"string"}},"required":["statusCode","message"]}}},"paths":{"/suggestions/config":{"post":{"description":"Set suggestions config. Only users with the Standard Registry role are allowed to make the request.","operationId":"SuggestionsApi_setPolicySuggestionsConfig","parameters":[],"requestBody":{"required":true,"description":"Suggestions config.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestionsConfigDTO"}}}},"responses":{"201":{"description":"Successful operation. Returns the updated suggestions config.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuggestionsConfigDTO"}}}},"401":{"description":"Unauthorized request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnauthorizedErrorDTO"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForbiddenErrorDTO"}}}},"500":{"description":"Internal server error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InternalServerErrorDTO"}}}}},"summary":"Set suggestions config","tags":["suggestions"]}}}}
```
