> For the complete documentation index, see [llms.txt](https://docs.guardianservice.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.guardianservice.app/technical-information/users/standard-registry-users-schemas-and-policies/policies/available-policy-workflow-blocks/dropdown-block-addon-dropdownblockaddon.md).

# Dropdown Block Addon (dropdownBlockAddon)

The purpose of this block is to display an interactive dropdown menu in the interfaceDocumentsSourceBlock.

## Usage <a href="#usage" id="usage"></a>

As shown in the example below, dropdownBlockAddon blocks should be placed inside interfaceDocumentsSourceBlock blocks. Source addons, which return documents for the dropdown, should be placed inside dropdownBlockAddon.

<figure><img src="/files/TAP45zIBUJMXnSdqFRCA" alt=""><figcaption></figcaption></figure>

## Properties

| Property Name                | Description                                                                   | Example                             | Status |
| ---------------------------- | ----------------------------------------------------------------------------- | ----------------------------------- | ------ |
| Option Name (*optionName*)   | The label (name) which is shown in dropdown items.                            | document.credentialSubject.0.field0 |        |
| Option Value (*optionValue*) | The value which will be used when a specific item is clicked.                 | document.credentialSubject.0.id     |        |
| Field (*field*)              | The field in selected document which will be populated with the option value. | assignedTo                          |        |

<figure><img src="/files/nCV0cNhn0SqRqa1enh6Q" alt=""><figcaption></figcaption></figure>

## Events <a href="#events" id="events"></a>

Dropdown block addon events will be automatically added to document source.

<figure><img src="/files/vqjkDJCg3qFGcwp9APou" alt=""><figcaption></figcaption></figure>

## API <a href="#api" id="api"></a>

The API for the dropdownBlockAddon has both GET and POST methods:

1. Example response to the GET request:

```
{
    "id": "47169fdc-900f-4e07-abb4-5510d7be1175",
    "blockType": "dropdownBlockAddon",
    "optionName": "document.credentialSubject.0.field0",
    "optionValue": "document.credentialSubject.0.id",
    "field": "assignedTo",
    "documents": [
        {
            "name": "example",
            "optionValue": "did:hedera:testnet:9XvzF671JeyoVRg8PvSZBTTyKyrvnZu2Mz7qE6FZXY8P_0.0.4481265",
            "value": "66b28683d029375c10f0f4ef"
        }
    ],
}
```

A response to the GET request includes all block settings and:

* documents - Dropdown options

2. Example payload for the POST request:

```
{
  "documentId": "66b28672d029375c10f0f4b6",
  "dropdownDocumentId": "66b28683d029375c10f0f4ef"
}
```

* documentId - Selected document
* dropdownDocumentId - Dropdown item which was clicked


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.guardianservice.app/technical-information/users/standard-registry-users-schemas-and-policies/policies/available-policy-workflow-blocks/dropdown-block-addon-dropdownblockaddon.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
