---
title: "POST /v4/spreadsheets/{spreadsheetId}/developerMetadata:search"
method: POST
path: "/v4/spreadsheets/{spreadsheetId}/developerMetadata:search"
tags: ["spreadsheets"]
---

# POST /v4/spreadsheets/{spreadsheetId}/developerMetadata:search

`POST /v4/spreadsheets/{spreadsheetId}/developerMetadata:search`

Returns all developer metadata matching the specified DataFilter. For more information, see [Read, write, and search metadata](https://developers.google.com/workspace/sheets/api/guides/metadata). If the provided DataFilter represents a DeveloperMetadataLookup object, this will return all DeveloperMetadata entries selected by it. If the DataFilter represents a location in a spreadsheet, this will return all developer metadata associated with locations intersecting that region.

## Path parameters

- `spreadsheetId` string, required

## Request body

- SearchDeveloperMetadataRequest — A request to retrieve all developer metadata matching the set of specified criteria.
  - `dataFilters` DataFilter[] — The data filters describing the criteria used to determine which DeveloperMetadata entries to return. DeveloperMetadata matching any of the specified filters are included in the response.
    - `a1Range` string — Selects data that matches the specified A1 range.
    - `gridRange` GridRange — A range on a sheet. All indexes are zero-based. Indexes are half open, i.e. the start index is inclusive and the end index is exclusive -- [start_index, end_index). Missing indexes indicate the range is unbounded on that side. For example, if `"Sheet1"` is sheet ID 123456, then: `Sheet1!A1:A1 == sheet_id: 123456, start_row_index: 0, end_row_index: 1, start_column_index: 0, end_column_index: 1` `Sheet1!A3:B4 == sheet_id: 123456, start_row_index: 2, end_row_index: 4, start_column_index: 0, end_column_index: 2` `Sheet1!A:B == sheet_id: 123456, start_column_index: 0, end_column_index: 2` `Sheet1!A5:B == sheet_id: 123456, start_row_index: 4, start_column_index: 0, end_column_index: 2` `Sheet1 == sheet_id: 123456` The start index must always be less than or equal to the end index. If the start index equals the end index, then the range is empty. Empty ranges are typically not meaningful and are usually rendered in the UI as `#REF!`.
      - `endRowIndex` integer — The end row (exclusive) of the range, or not set if unbounded.
      - `sheetId` integer — The sheet this range is on.
      - `endColumnIndex` integer — The end column (exclusive) of the range, or not set if unbounded.
      - `startRowIndex` integer — The start row (inclusive) of the range, or not set if unbounded.
      - `startColumnIndex` integer — The start column (inclusive) of the range, or not set if unbounded.
    - `developerMetadataLookup` DeveloperMetadataLookup — Selects DeveloperMetadata that matches all of the specified fields. For example, if only a metadata ID is specified this considers the DeveloperMetadata with that particular unique ID. If a metadata key is specified, this considers all developer metadata with that key. If a key, visibility, and location type are all specified, this considers all developer metadata with that key and visibility that are associated with a location of that type. In general, this selects all DeveloperMetadata that match the intersection of all the specified fields; any field or combination of fields may be specified.
      - `locationType` 'DEVELOPER_METADATA_LOCATION_TYPE_UNSPECIFIED' | 'ROW' | 'COLUMN' | 'SHEET' | 'SPREADSHEET' — Limits the selected developer metadata to those entries which are associated with locations of the specified type. For example, when this field is specified as ROW this lookup only considers developer metadata associated on rows. If the field is left unspecified, all location types are considered. This field cannot be specified as SPREADSHEET when the locationMatchingStrategy is specified as INTERSECTING or when the metadataLocation is specified as a non-spreadsheet location. Spreadsheet metadata cannot intersect any other developer metadata location. This field also must be left unspecified when the locationMatchingStrategy is specified as EXACT.
      - `metadataKey` string — Limits the selected developer metadata to that which has a matching DeveloperMetadata.metadata_key.
      - `metadataValue` string — Limits the selected developer metadata to that which has a matching DeveloperMetadata.metadata_value.
      - `visibility` 'DEVELOPER_METADATA_VISIBILITY_UNSPECIFIED' | 'DOCUMENT' | 'PROJECT' — Limits the selected developer metadata to that which has a matching DeveloperMetadata.visibility. If left unspecified, all developer metadata visible to the requesting project is considered.
      - `locationMatchingStrategy` 'DEVELOPER_METADATA_LOCATION_MATCHING_STRATEGY_UNSPECIFIED' | 'EXACT_LOCATION' | 'INTERSECTING_LOCATION' — Determines how this lookup matches the location. If this field is specified as EXACT, only developer metadata associated on the exact location specified is matched. If this field is specified to INTERSECTING, developer metadata associated on intersecting locations is also matched. If left unspecified, this field assumes a default value of INTERSECTING. If this field is specified, a metadataLocation must also be specified.
      - `metadataId` integer — Limits the selected developer metadata to that which has a matching DeveloperMetadata.metadata_id.
      - `metadataLocation` DeveloperMetadataLocation — A location where metadata may be associated in a spreadsheet.
        - `sheetId` integer — The ID of the sheet when metadata is associated with an entire sheet.
        - `spreadsheet` boolean — True when metadata is associated with an entire spreadsheet.
        - `dimensionRange` DimensionRange — A range along a single dimension on a sheet. All indexes are zero-based. Indexes are half open: the start index is inclusive and the end index is exclusive. Missing indexes indicate the range is unbounded on that side.
          - `sheetId` integer — The sheet this span is on.
          - `startIndex` integer — The start (inclusive) of the span, or not set if unbounded.
          - `dimension` 'DIMENSION_UNSPECIFIED' | 'ROWS' | 'COLUMNS' — The dimension of the span.
          - `endIndex` integer — The end (exclusive) of the span, or not set if unbounded.
        - `locationType` 'DEVELOPER_METADATA_LOCATION_TYPE_UNSPECIFIED' | 'ROW' | 'COLUMN' | 'SHEET' | 'SPREADSHEET' — The type of location this object represents. This field is read-only.

## Response `200`

Successful response

---

[API](https://skmtc.dev/google/apis/sheets.md) · [All operations](https://skmtc.dev/google/apis/sheets/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/google/sheets/revisions/89de4914a876/schema)
