SearchTopicsCommand

Searches for any Q topic that exists in an Amazon QuickSight account.

Example Syntax

Use a bare-bones client and the command you need to make an API call.

import { QuickSightClient, SearchTopicsCommand } from "@aws-sdk/client-quicksight"; // ES Modules import
// const { QuickSightClient, SearchTopicsCommand } = require("@aws-sdk/client-quicksight"); // CommonJS import
const client = new QuickSightClient(config);
const input = { // SearchTopicsRequest
  AwsAccountId: "STRING_VALUE", // required
  Filters: [ // TopicSearchFilterList // required
    { // TopicSearchFilter
      Operator: "StringEquals" || "StringLike", // required
      Name: "QUICKSIGHT_USER" || "QUICKSIGHT_VIEWER_OR_OWNER" || "DIRECT_QUICKSIGHT_VIEWER_OR_OWNER" || "QUICKSIGHT_OWNER" || "DIRECT_QUICKSIGHT_OWNER" || "DIRECT_QUICKSIGHT_SOLE_OWNER" || "TOPIC_NAME", // required
      Value: "STRING_VALUE", // required
    },
  ],
  NextToken: "STRING_VALUE",
  MaxResults: Number("int"),
};
const command = new SearchTopicsCommand(input);
const response = await client.send(command);
// { // SearchTopicsResponse
//   TopicSummaryList: [ // TopicSummaries
//     { // TopicSummary
//       Arn: "STRING_VALUE",
//       TopicId: "STRING_VALUE",
//       Name: "STRING_VALUE",
//       UserExperienceVersion: "LEGACY" || "NEW_READER_EXPERIENCE",
//     },
//   ],
//   NextToken: "STRING_VALUE",
//   Status: Number("int"),
//   RequestId: "STRING_VALUE",
// };

SearchTopicsCommand Input

See SearchTopicsCommandInput for more details

Parameter
Type
Description
AwsAccountId
Required
string | undefined

The ID of the Amazon Web Services account that contains the topic that you want to find.

Filters
Required
TopicSearchFilter[] | undefined

The filters that you want to use to search for the topic.

MaxResults
number | undefined

The maximum number of results to be returned per request.

NextToken
string | undefined

The token for the next set of results, or null if there are no more results.

SearchTopicsCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.
NextToken
string | undefined

The token for the next set of results, or null if there are no more results.

RequestId
string | undefined

The Amazon Web Services request ID for this operation.

Status
number | undefined

The HTTP status of the request.

TopicSummaryList
TopicSummary[] | undefined

A list of topic summaries that is returned by the search topic request.

Throws

Name
Fault
Details
InternalFailureException
server

An internal failure occurred.

InvalidNextTokenException
client

The NextToken value isn't valid.

InvalidParameterValueException
client

One or more parameters has a value that isn't valid.

ResourceNotFoundException
client

One or more resources can't be found.

ThrottlingException
client

Access is throttled.

UnsupportedUserEditionException
client

This error indicates that you are calling an operation on an Amazon QuickSight subscription where the edition doesn't include support for that operation. Amazon Amazon QuickSight currently has Standard Edition and Enterprise Edition. Not every operation and capability is available in every edition.

QuickSightServiceException
Base exception class for all service exceptions from QuickSight service.