---
title: "POST /api/v1/search"
method: POST
path: "/api/v1/search"
---

# POST /api/v1/search

`POST /api/v1/search`

Searches metadata and the content of folders, documents, document versions, and comments.

## Query parameters

- `Limit` string
- `Marker` string

## Headers

- `Authentication` string, password

## Request body

- object
  - `QueryText` string, password — The String to search for. Searches across different text fields based on request parameters. Use double quotes around the query string for exact phrase matches.
  - `QueryScopes` SearchQueryScopeType[] — Filter based on the text field type. A Folder has only a name and no content. A Comment has only content and no name. A Document or Document Version has a name and content
  - `OrganizationId` string — Filters based on the resource owner OrgId. This is a mandatory parameter when using Admin SigV4 credentials.
  - `AdditionalResponseFields` AdditionalResponseFieldType[] — A list of attributes to include in the response. Used to request fields that are not normally returned in a standard response.
  - `Filters` object — Filters results based on entity metadata.
    - `TextLocales` LanguageCodeType[] — Filters by the locale of the content or comment.
    - `ContentCategories` ContentCategoryType[] — Filters by content category.
    - `ResourceTypes` SearchResourceType[] — Filters based on entity type.
    - `Labels` SearchLabel[] — Filter by labels using exact match.
    - `Principals` SearchPrincipalType[] — Filter based on UserIds or GroupIds.
      - `Id` string, required — UserIds or GroupIds.
      - `Roles` PrincipalRoleType[] — The Role of a User or Group.
    - `AncestorIds` SearchAncestorId[] — Filter based on resource’s path.
    - `SearchCollectionTypes` SearchCollectionType[] — Filter based on file groupings.
    - `SizeRange` object — Filter based on size (in bytes).
      - `StartValue` integer — The size start range (in bytes).
      - `EndValue` integer — The size end range (in bytes).
    - `CreatedRange` object — Filter based on resource’s creation timestamp.
      - `StartValue` string, date-time — Timestamp range start value (in epochs)
      - `EndValue` string, date-time — Timestamp range end value (in epochs).
    - `ModifiedRange` object — Filter based on resource’s modified timestamp.
      - `StartValue` string, date-time — Timestamp range start value (in epochs)
      - `EndValue` string, date-time — Timestamp range end value (in epochs).
  - `OrderBy` SearchSortResult[] — Order by results in one or more categories.
    - `Field` 'RELEVANCE' | 'NAME' | 'SIZE' | 'CREATED_TIMESTAMP' | 'MODIFIED_TIMESTAMP' — Sort search results based on this field name.
    - `Order` 'ASC' | 'DESC' — Sort direction.
  - `Limit` integer — Max results count per page.
  - `Marker` string — The marker for the next set of results.

## Response `200`

Success

- SearchResourcesResponse
  - `Items` ResponseItem[] — List of Documents, Folders, Comments, and Document Versions matching the query.
    - `ResourceType` 'DOCUMENT' | 'FOLDER' | 'COMMENT' | 'DOCUMENT_VERSION' — The type of item being returned.
    - `WebUrl` string, password — The webUrl of the item being returned.
    - `DocumentMetadata` object — The document that matches the query.
      - `Id` string — The ID of the document.
      - `CreatorId` string — The ID of the creator.
      - `ParentFolderId` string — The ID of the parent folder.
      - `CreatedTimestamp` string, date-time — The time when the document was created.
      - `ModifiedTimestamp` string, date-time — The time when the document was updated.
      - `LatestVersionMetadata` object — The latest version of the document.
        - `Id` string — The ID of the version.
        - `Name` string, password — The name of the version.
        - `ContentType` string — The content type of the document.
        - `Size` integer — The size of the document, in bytes.
        - `Signature` string — The signature of the document.
        - `Status` 'INITIALIZED' | 'ACTIVE' — The status of the document.
        - `CreatedTimestamp` string, date-time — The timestamp when the document was first uploaded.
        - `ModifiedTimestamp` string, date-time — The timestamp when the document was last uploaded.
        - `ContentCreatedTimestamp` string, date-time — The timestamp when the content of the document was originally created.
        - `ContentModifiedTimestamp` string, date-time — The timestamp when the content of the document was modified.
        - `CreatorId` string — The ID of the creator.
        - `Thumbnail` object — The thumbnail of the document.
        - `Source` object — The source of the document.
      - `ResourceState` 'ACTIVE' | 'RESTORING' | 'RECYCLING' | 'RECYCLED' — The resource state.
      - `Labels` SharedLabel[] — List of labels on the document.
    - `FolderMetadata` object — The folder that matches the query.
      - `Id` string — The ID of the folder.
      - `Name` string, password — The name of the folder.
      - `CreatorId` string — The ID of the creator.
      - `ParentFolderId` string — The ID of the parent folder.
      - `CreatedTimestamp` string, date-time — The time when the folder was created.
      - `ModifiedTimestamp` string, date-time — The time when the folder was updated.
      - `ResourceState` 'ACTIVE' | 'RESTORING' | 'RECYCLING' | 'RECYCLED' — The resource state of the folder.
      - `Signature` string — The unique identifier created from the subfolders and documents of the folder.
      - `Labels` SharedLabel[] — List of labels on the folder.
      - `Size` integer — The size of the folder metadata.
      - `LatestVersionSize` integer — The size of the latest version of the folder metadata.
    - `CommentMetadata` object — The comment that matches the query.
      - `CommentId` string — The ID of the comment.
      - `Contributor` object — The user who made the comment.
        - `Id` string — The ID of the user.
        - `Username` string, password — The login name of the user.
        - `EmailAddress` string, password — The email address of the user.
        - `GivenName` string, password — The given name of the user.
        - `Surname` string, password — The surname of the user.
        - `OrganizationId` string — The ID of the organization.
        - `RootFolderId` string — The ID of the root folder.
        - `RecycleBinFolderId` string — The ID of the recycle bin folder.
        - `Status` 'ACTIVE' | 'INACTIVE' | 'PENDING' — The status of the user.
        - `Type` 'USER' | 'ADMIN' | 'POWERUSER' | 'MINIMALUSER' | 'WORKSPACESUSER' — The type of user.
        - `CreatedTimestamp` string, date-time — The time when the user was created.
        - `ModifiedTimestamp` string, date-time — The time when the user was modified.
        - `TimeZoneId` string — The time zone ID of the user.
        - `Locale` 'en' | 'fr' | 'ko' | 'de' | 'es' | 'ja' | 'ru' | 'zh_CN' | 'zh_TW' | 'pt_BR' | 'default' — The locale of the user.
        - `Storage` object — The storage for the user.
          - `StorageUtilizedInBytes` integer — The amount of storage used, in bytes.
          - `StorageRule` object — The storage for a user.
            - `StorageAllocatedInBytes` integer — The amount of storage allocated, in bytes.
            - `StorageType` 'UNLIMITED' | 'QUOTA' — The type of storage.
      - `CreatedTimestamp` string, date-time — The timestamp that the comment was created.
      - `CommentStatus` 'DRAFT' | 'PUBLISHED' | 'DELETED' — The status of the comment.
      - `RecipientId` string — The ID of the user being replied to.
      - `ContributorId` string — The ID of the user who made the comment.
    - `DocumentVersionMetadata` object — The document version that matches the metadata.
      - `Id` string — The ID of the version.
      - `Name` string, password — The name of the version.
      - `ContentType` string — The content type of the document.
      - `Size` integer — The size of the document, in bytes.
      - `Signature` string — The signature of the document.
      - `Status` 'INITIALIZED' | 'ACTIVE' — The status of the document.
      - `CreatedTimestamp` string, date-time — The timestamp when the document was first uploaded.
      - `ModifiedTimestamp` string, date-time — The timestamp when the document was last uploaded.
      - `ContentCreatedTimestamp` string, date-time — The timestamp when the content of the document was originally created.
      - `ContentModifiedTimestamp` string, date-time — The timestamp when the content of the document was modified.
      - `CreatorId` string — The ID of the creator.
      - `Thumbnail` object — The thumbnail of the document.
      - `Source` object — The source of the document.
  - `Marker` string — The marker to use when requesting the next set of results. If there are no additional results, the string is empty.

## Other responses

- `480` — InvalidArgumentException
- `481` — UnauthorizedResourceAccessException
- `482` — UnauthorizedOperationException
- `483` — ServiceUnavailableException

---

[API](https://skmtc.net/aws/apis/workdocs.md) · [All operations](https://skmtc.net/aws/apis/workdocs/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/workdocs/versions/8a533af4e1ef/schema)
