---
title: "Save a view"
method: POST
path: "/v1/views"
tags: ["Views"]
---

# Save a view

`POST /v1/views`

## Request

- Base URL: `https://api.mentio.dev`
- URL: `https://api.mentio.dev/v1/views`
- Auth: HTTP bearer

Save a named filter over mentions. The filter takes the same fields as GET /v1/mentions (lists are any-of, `not` lists none-of, every condition ANDed), plus `anyOf`, groups of those conditions of which at least one must hold; an empty filter is every mention. Nothing is materialized: the view selects whatever matches when it is read.

## Request body

- object
  - `name` string, required: Unique per workspace, case-insensitive.
  - `description` string: What the view is for, shown under its name.
  - `filter` object: The filter; empty selects every mention.
    - `q` string: Substring in the post text or the author's name.
    - `keywordIds` string[]: Only matches of any of these keywords.
    - `notKeywordIds` string[]: Never matches of these keywords.
    - `keywordKinds` string[]: Only matches of keywords of any of these kinds: brand, competitor, topic.
    - `groupIds` string[]: Only matches of keywords in any of these groups (grp_...).
    - `notGroupIds` string[]: Never matches of keywords in these groups.
    - `platforms` string[]: Only posts from any of these platforms.
    - `notPlatforms` string[]: Never posts from these platforms.
    - `status` 'open' | 'ignored' | 'done': Only mentions in this status: open, ignored, done.
    - `relevant` boolean: true: only mentions the classifier scored relevant; false: only the rest.
    - `minRelevance` integer: Only mentions scored at least this.
    - `minConfidence` number: Only mentions whose classifier confidence is at least this.
    - `sentiments` string[]: Only these sentiments.
    - `notSentiments` string[]: Never these sentiments; an unscored mention still passes.
    - `intents` string[]: Only mentions carrying any of these intent or topic tags.
    - `notIntents` string[]: Never mentions carrying these tags.
    - `automated` boolean: true: only posts that read as machine-made; false: only the rest.
    - `languages` string[]: Only posts in any of these languages (ISO 639-1).
    - `notLanguages` string[]: Never posts in these languages; an unknown language still passes.
    - `countries` string[]: Only posts whose author is in any of these countries (ISO 3166-1 alpha-2: us, in, de). An unknown country never passes.
    - `notCountries` string[]: Never posts whose author is in these countries; an unknown country still passes.
    - `organization` boolean: true: only posts by companies, brands and organizations; false: only posts by people.
    - `tags` string[]: Only authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
    - `notTags` string[]: Never authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
    - `linkHosts` string[]: Only posts linking to any of these hosts, the host itself or a subdomain of it.
    - `notLinkHosts` string[]: Never posts linking to these hosts.
    - `subreddits` string[]: Only Reddit posts from any of these subreddits (names without the r/, any case); every other post fails it.
    - `notSubreddits` string[]: Never Reddit posts from these subreddits; posts from other platforms still pass.
    - `minFollowers` integer: Only authors with at least this many followers; unknown reach never passes.
    - `maxFollowers` integer: Only authors with at most this many followers; unknown reach never passes.
    - `isReply` boolean: true: only replies and comments; false: only top-level posts.
    - `kind` 'post' | 'comment' | 'repository': Only posts (post), only comments (comment) or only GitHub repository events (repository).
    - `excludeAuthors` string[]: Never these authors: display names, handles or profile URLs.
    - `ratings` integer[]: Only app store reviews with any of these star ratings; every other post fails it.
    - `notRatings` integer[]: Never reviews with these star ratings; posts that are not reviews still pass.
    - `minLikes` integer: Only posts with at least this many likes (upvotes, reactions), as the platform reported them when the post was found. A post without that count never passes.
    - `minReposts` integer: Only posts with at least this many reposts (shares, retweets), as the platform reported them when the post was found. A post without that count never passes.
    - `minReplies` integer: Only posts with at least this many replies (comments), as the platform reported them when the post was found. A post without that count never passes.
    - `minQuotes` integer: Only posts with at least this many quotes, as the platform reported them when the post was found. A post without that count never passes.
    - `minViews` integer: Only posts with at least this many views (plays), as the platform reported them when the post was found. A post without that count never passes.
    - `minBookmarks` integer: Only posts with at least this many bookmarks (saves), as the platform reported them when the post was found. A post without that count never passes.
    - `anyOf` FilterGroup[]: OR across groups: a mention passes when it meets every condition of at least one group (1 to 10 groups). The other conditions still apply to every mention: the whole filter is (other conditions) AND (group 1 OR group 2 ...). A group takes the conditions of a view filter (platforms, sentiments, intents, keywordKinds, the not lists ...), with no anyOf of its own.
      - `q` string: Substring in the post text or the author's name.
      - `keywordIds` string[]: Only matches of any of these keywords.
      - `notKeywordIds` string[]: Never matches of these keywords.
      - `keywordKinds` string[]: Only matches of keywords of any of these kinds: brand, competitor, topic.
      - `groupIds` string[]: Only matches of keywords in any of these groups (grp_...).
      - `notGroupIds` string[]: Never matches of keywords in these groups.
      - `platforms` string[]: Only posts from any of these platforms.
      - `notPlatforms` string[]: Never posts from these platforms.
      - `status` 'open' | 'ignored' | 'done': Only mentions in this status: open, ignored, done.
      - `relevant` boolean: true: only mentions the classifier scored relevant; false: only the rest.
      - `minRelevance` integer: Only mentions scored at least this.
      - `minConfidence` number: Only mentions whose classifier confidence is at least this.
      - `sentiments` string[]: Only these sentiments.
      - `notSentiments` string[]: Never these sentiments; an unscored mention still passes.
      - `intents` string[]: Only mentions carrying any of these intent or topic tags.
      - `notIntents` string[]: Never mentions carrying these tags.
      - `automated` boolean: true: only posts that read as machine-made; false: only the rest.
      - `languages` string[]: Only posts in any of these languages (ISO 639-1).
      - `notLanguages` string[]: Never posts in these languages; an unknown language still passes.
      - `countries` string[]: Only posts whose author is in any of these countries (ISO 3166-1 alpha-2: us, in, de). An unknown country never passes.
      - `notCountries` string[]: Never posts whose author is in these countries; an unknown country still passes.
      - `organization` boolean: true: only posts by companies, brands and organizations; false: only posts by people.
      - `tags` string[]: Only authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
      - `notTags` string[]: Never authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
      - `linkHosts` string[]: Only posts linking to any of these hosts, the host itself or a subdomain of it.
      - `notLinkHosts` string[]: Never posts linking to these hosts.
      - `subreddits` string[]: Only Reddit posts from any of these subreddits (names without the r/, any case); every other post fails it.
      - `notSubreddits` string[]: Never Reddit posts from these subreddits; posts from other platforms still pass.
      - `minFollowers` integer: Only authors with at least this many followers; unknown reach never passes.
      - `maxFollowers` integer: Only authors with at most this many followers; unknown reach never passes.
      - `isReply` boolean: true: only replies and comments; false: only top-level posts.
      - `kind` 'post' | 'comment' | 'repository': Only posts (post), only comments (comment) or only GitHub repository events (repository).
      - `excludeAuthors` string[]: Never these authors: display names, handles or profile URLs.
      - `ratings` integer[]: Only app store reviews with any of these star ratings; every other post fails it.
      - `notRatings` integer[]: Never reviews with these star ratings; posts that are not reviews still pass.
      - `minLikes` integer: Only posts with at least this many likes (upvotes, reactions), as the platform reported them when the post was found. A post without that count never passes.
      - `minReposts` integer: Only posts with at least this many reposts (shares, retweets), as the platform reported them when the post was found. A post without that count never passes.
      - `minReplies` integer: Only posts with at least this many replies (comments), as the platform reported them when the post was found. A post without that count never passes.
      - `minQuotes` integer: Only posts with at least this many quotes, as the platform reported them when the post was found. A post without that count never passes.
      - `minViews` integer: Only posts with at least this many views (plays), as the platform reported them when the post was found. A post without that count never passes.
      - `minBookmarks` integer: Only posts with at least this many bookmarks (saves), as the platform reported them when the post was found. A post without that count never passes.

## Response `201`

The saved view

- View
  - `id` string, required: View id (vw_...).
  - `name` string, required
  - `description` string, required
  - `filter` object, required
    - `q` string: Substring in the post text or the author's name.
    - `keywordIds` string[]: Only matches of any of these keywords.
    - `notKeywordIds` string[]: Never matches of these keywords.
    - `keywordKinds` string[]: Only matches of keywords of any of these kinds: brand, competitor, topic.
    - `groupIds` string[]: Only matches of keywords in any of these groups (grp_...).
    - `notGroupIds` string[]: Never matches of keywords in these groups.
    - `platforms` string[]: Only posts from any of these platforms.
    - `notPlatforms` string[]: Never posts from these platforms.
    - `status` 'open' | 'ignored' | 'done': Only mentions in this status: open, ignored, done.
    - `relevant` boolean: true: only mentions the classifier scored relevant; false: only the rest.
    - `minRelevance` integer: Only mentions scored at least this.
    - `minConfidence` number: Only mentions whose classifier confidence is at least this.
    - `sentiments` string[]: Only these sentiments.
    - `notSentiments` string[]: Never these sentiments; an unscored mention still passes.
    - `intents` string[]: Only mentions carrying any of these intent or topic tags.
    - `notIntents` string[]: Never mentions carrying these tags.
    - `automated` boolean: true: only posts that read as machine-made; false: only the rest.
    - `languages` string[]: Only posts in any of these languages (ISO 639-1).
    - `notLanguages` string[]: Never posts in these languages; an unknown language still passes.
    - `countries` string[]: Only posts whose author is in any of these countries (ISO 3166-1 alpha-2: us, in, de). An unknown country never passes.
    - `notCountries` string[]: Never posts whose author is in these countries; an unknown country still passes.
    - `organization` boolean: true: only posts by companies, brands and organizations; false: only posts by people.
    - `tags` string[]: Only authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
    - `notTags` string[]: Never authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
    - `linkHosts` string[]: Only posts linking to any of these hosts, the host itself or a subdomain of it.
    - `notLinkHosts` string[]: Never posts linking to these hosts.
    - `subreddits` string[]: Only Reddit posts from any of these subreddits (names without the r/, any case); every other post fails it.
    - `notSubreddits` string[]: Never Reddit posts from these subreddits; posts from other platforms still pass.
    - `minFollowers` integer: Only authors with at least this many followers; unknown reach never passes.
    - `maxFollowers` integer: Only authors with at most this many followers; unknown reach never passes.
    - `isReply` boolean: true: only replies and comments; false: only top-level posts.
    - `kind` 'post' | 'comment' | 'repository': Only posts (post), only comments (comment) or only GitHub repository events (repository).
    - `excludeAuthors` string[]: Never these authors: display names, handles or profile URLs.
    - `ratings` integer[]: Only app store reviews with any of these star ratings; every other post fails it.
    - `notRatings` integer[]: Never reviews with these star ratings; posts that are not reviews still pass.
    - `minLikes` integer: Only posts with at least this many likes (upvotes, reactions), as the platform reported them when the post was found. A post without that count never passes.
    - `minReposts` integer: Only posts with at least this many reposts (shares, retweets), as the platform reported them when the post was found. A post without that count never passes.
    - `minReplies` integer: Only posts with at least this many replies (comments), as the platform reported them when the post was found. A post without that count never passes.
    - `minQuotes` integer: Only posts with at least this many quotes, as the platform reported them when the post was found. A post without that count never passes.
    - `minViews` integer: Only posts with at least this many views (plays), as the platform reported them when the post was found. A post without that count never passes.
    - `minBookmarks` integer: Only posts with at least this many bookmarks (saves), as the platform reported them when the post was found. A post without that count never passes.
    - `anyOf` FilterGroup[]: OR across groups: a mention passes when it meets every condition of at least one group (1 to 10 groups). The other conditions still apply to every mention: the whole filter is (other conditions) AND (group 1 OR group 2 ...). A group takes the conditions of a view filter (platforms, sentiments, intents, keywordKinds, the not lists ...), with no anyOf of its own.
      - `q` string: Substring in the post text or the author's name.
      - `keywordIds` string[]: Only matches of any of these keywords.
      - `notKeywordIds` string[]: Never matches of these keywords.
      - `keywordKinds` string[]: Only matches of keywords of any of these kinds: brand, competitor, topic.
      - `groupIds` string[]: Only matches of keywords in any of these groups (grp_...).
      - `notGroupIds` string[]: Never matches of keywords in these groups.
      - `platforms` string[]: Only posts from any of these platforms.
      - `notPlatforms` string[]: Never posts from these platforms.
      - `status` 'open' | 'ignored' | 'done': Only mentions in this status: open, ignored, done.
      - `relevant` boolean: true: only mentions the classifier scored relevant; false: only the rest.
      - `minRelevance` integer: Only mentions scored at least this.
      - `minConfidence` number: Only mentions whose classifier confidence is at least this.
      - `sentiments` string[]: Only these sentiments.
      - `notSentiments` string[]: Never these sentiments; an unscored mention still passes.
      - `intents` string[]: Only mentions carrying any of these intent or topic tags.
      - `notIntents` string[]: Never mentions carrying these tags.
      - `automated` boolean: true: only posts that read as machine-made; false: only the rest.
      - `languages` string[]: Only posts in any of these languages (ISO 639-1).
      - `notLanguages` string[]: Never posts in these languages; an unknown language still passes.
      - `countries` string[]: Only posts whose author is in any of these countries (ISO 3166-1 alpha-2: us, in, de). An unknown country never passes.
      - `notCountries` string[]: Never posts whose author is in these countries; an unknown country still passes.
      - `organization` boolean: true: only posts by companies, brands and organizations; false: only posts by people.
      - `tags` string[]: Only authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
      - `notTags` string[]: Never authors tagged with any of these, in the workspace's tags or those of the mention's own keyword group.
      - `linkHosts` string[]: Only posts linking to any of these hosts, the host itself or a subdomain of it.
      - `notLinkHosts` string[]: Never posts linking to these hosts.
      - `subreddits` string[]: Only Reddit posts from any of these subreddits (names without the r/, any case); every other post fails it.
      - `notSubreddits` string[]: Never Reddit posts from these subreddits; posts from other platforms still pass.
      - `minFollowers` integer: Only authors with at least this many followers; unknown reach never passes.
      - `maxFollowers` integer: Only authors with at most this many followers; unknown reach never passes.
      - `isReply` boolean: true: only replies and comments; false: only top-level posts.
      - `kind` 'post' | 'comment' | 'repository': Only posts (post), only comments (comment) or only GitHub repository events (repository).
      - `excludeAuthors` string[]: Never these authors: display names, handles or profile URLs.
      - `ratings` integer[]: Only app store reviews with any of these star ratings; every other post fails it.
      - `notRatings` integer[]: Never reviews with these star ratings; posts that are not reviews still pass.
      - `minLikes` integer: Only posts with at least this many likes (upvotes, reactions), as the platform reported them when the post was found. A post without that count never passes.
      - `minReposts` integer: Only posts with at least this many reposts (shares, retweets), as the platform reported them when the post was found. A post without that count never passes.
      - `minReplies` integer: Only posts with at least this many replies (comments), as the platform reported them when the post was found. A post without that count never passes.
      - `minQuotes` integer: Only posts with at least this many quotes, as the platform reported them when the post was found. A post without that count never passes.
      - `minViews` integer: Only posts with at least this many views (plays), as the platform reported them when the post was found. A post without that count never passes.
      - `minBookmarks` integer: Only posts with at least this many bookmarks (saves), as the platform reported them when the post was found. A post without that count never passes.
  - `createdAt` string, required: ISO 8601 timestamp, UTC.
  - `updatedAt` string, required: ISO 8601 timestamp, UTC.

## Other responses

- `400`: Invalid filter (an empty anyOf group, for one), or filter_too_complex: more values than one query can carry
- `401`: Missing or invalid API key
- `409`: A view with that name already exists (duplicate_view)

---

[API](https://skmtc.dev/mentio/apis/mentio-api.md) · [All operations](https://skmtc.dev/mentio/apis/mentio-api/llms.txt) · [OpenAPI document](https://skmtc.dev/mentio/apis/mentio-api/revisions/b16a21d0ed02?raw)
