> ## Documentation Index
> Fetch the complete documentation index at: https://v0.x-docs.novu.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Update notification action status

> This API is deprecated, use v2 API instead. Update in-app notification's action status by its unique key identifier **messageId** and type field **type**. 
      **type** field can be **primary** or **secondary**

<Warning>
  Enter your API key in the `Authorization` field like the example shown below:

  E.g `ApiKey 18d2e625f05d80e`
</Warning>


## OpenAPI

````yaml post /v1/subscribers/{subscriberId}/messages/{messageId}/actions/{type}
openapi: 3.0.0
info:
  title: Novu API
  description: >-
    Novu REST API. Please see https://docs.novu.co/api-reference for more
    details.
  version: '1.0'
  contact:
    name: Novu Support
    url: https://discord.gg/novu
    email: support@novu.co
  termsOfService: https://novu.co/terms
  license:
    name: MIT
    url: https://opensource.org/license/mit
servers:
  - url: https://api.novu.co
  - url: https://eu.api.novu.co
security: []
tags:
  - name: Events
    description: >-
      Events represent a change in state of a subscriber. They are used to
      trigger workflows, and enable you to send notifications to subscribers
      based on their actions.
    externalDocs:
      url: https://docs.novu.co/workflows
  - name: Subscribers
    description: >-
      A subscriber in Novu represents someone who should receive a message. A
      subscriber’s profile information contains important attributes about the
      subscriber that will be used in messages (name, email). The subscriber
      object can contain other key-value pairs that can be used to further
      personalize your messages.
    externalDocs:
      url: https://docs.novu.co/subscribers/subscribers
  - name: Topics
    description: >-
      Topics are a way to group subscribers together so that they can be
      notified of events at once. A topic is identified by a custom key. This
      can be helpful for things like sending out marketing emails or notifying
      users of new features. Topics can also be used to send notifications to
      the subscribers who have been grouped together based on their interests,
      location, activities and much more.
    externalDocs:
      url: https://docs.novu.co/subscribers/topics
  - name: Notification
    description: >-
      A notification conveys information from source to recipient, triggered by
      a workflow acting as a message blueprint. Notifications can be individual
      or bundled as digest for user-friendliness.
    externalDocs:
      url: https://docs.novu.co/getting-started/introduction
  - name: Integrations
    description: >-
      With the help of the Integration Store, you can easily integrate your
      favorite delivery provider. During the runtime of the API, the
      Integrations Store is responsible for storing the configurations of all
      the providers.
    externalDocs:
      url: https://docs.novu.co/channels-and-providers/integration-store
  - name: Layouts
    description: >-
      Novu allows the creation of layouts - a specific HTML design or structure
      to wrap content of email notifications. Layouts can be manipulated and
      assigned to new or existing workflows within the Novu platform, allowing
      users to create, manage, and assign these layouts to workflows, so they
      can be reused to structure the appearance of notifications sent through
      the platform.
    externalDocs:
      url: https://docs.novu.co/content-creation-design/layouts
  - name: Workflows
    description: >-
      All notifications are sent via a workflow. Each workflow acts as a
      container for the logic and blueprint that are associated with a type of
      notification in your system.
    externalDocs:
      url: https://docs.novu.co/workflows
  - name: Notification Templates
    description: >-
      Deprecated. Use Workflows (/workflows) instead, which provide the same
      functionality under a new name.
  - name: Workflow groups
    description: Workflow groups are used to organize workflows into logical groups.
  - name: Changes
    description: >-
      Changes represent a change in state of an environment. They are analagous
      to a pending pull request in git, enabling you to test changes before they
      are applied to your environment and atomically apply them when you are
      ready.
    externalDocs:
      url: >-
        https://docs.novu.co/platform/environments#promoting-pending-changes-to-production
  - name: Environments
    description: >-
      Novu uses the concept of environments to ensure logical separation of your
      data and configuration. This means that subscribers, and preferences
      created in one environment are never accessible to another.
    externalDocs:
      url: https://docs.novu.co/platform/environments
  - name: Inbound Parse
    description: >-
      Inbound Webhook is a feature that allows processing of incoming emails for
      a domain or subdomain. The feature parses the contents of the email and
      POSTs the information to a specified URL in a multipart/form-data format.
    externalDocs:
      url: https://docs.novu.co/platform/inbound-parse-webhook
  - name: Feeds
    description: >-
      Novu provides a notification activity feed that monitors every outgoing
      message associated with its relevant metadata. This can be used to monitor
      activity and discover potential issues with a specific provider or a
      channel type.
    externalDocs:
      url: https://docs.novu.co/activity-feed
  - name: Tenants
    description: >-
      A tenant represents a group of users. As a developer, when your apps have
      organizations, they are referred to as tenants. Tenants in Novu provides
      the ability to tailor specific notification experiences to users of
      different groups or organizations.
    externalDocs:
      url: https://docs.novu.co/tenants
  - name: Messages
    description: >-
      A message in Novu represents a notification delivered to a recipient on a
      particular channel. Messages contain information about the request that
      triggered its delivery, a view of the data sent to the recipient, and a
      timeline of its lifecycle events. Learn more about messages.
    externalDocs:
      url: https://docs.novu.co/workflows/messages
  - name: Organizations
    description: >-
      An organization serves as a separate entity within your Novu account. Each
      organization you create has its own separate integration store, workflows,
      subscribers, and API keys. This separation of resources allows you to
      manage multi-tenant environments and separate domains within a single
      account.
    externalDocs:
      url: https://docs.novu.co/platform/organizations
  - name: Execution Details
    description: >-
      Execution details are used to track the execution of a workflow. They
      provided detailed information on the execution of a workflow, including
      the status of each step, the input and output of each step, and the
      overall status of the execution.
    externalDocs:
      url: https://docs.novu.co/activity-feed
externalDocs:
  description: Novu Documentation
  url: https://docs.novu.co
paths:
  /v1/subscribers/{subscriberId}/messages/{messageId}/actions/{type}:
    post:
      tags:
        - Subscribers
      summary: Mark message action as seen
      operationId: SubscribersController_markActionAsSeen
      parameters:
        - name: messageId
          required: true
          in: path
          schema:
            type: string
        - name: type
          required: true
          in: path
          schema:
            type: string
        - name: subscriberId
          required: true
          in: path
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MarkMessageActionAsSeenDto'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessageResponseDto'
        '409':
          description: >-
            The request could not be completed due to a conflict with the
            current state of the target resource.
          content:
            application/json:
              schema:
                type: string
                example: >-
                  Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is
                  currently being processed. Please retry after 1 second
        '429':
          description: 'The client has sent too many requests in a given amount of time. '
          content:
            application/json:
              schema:
                type: string
                example: API rate limit exceeded
        '503':
          description: >-
            The server is currently unable to handle the request due to a
            temporary overload or scheduled maintenance, which will likely be
            alleviated after some delay.
          content:
            application/json:
              schema:
                type: string
                example: Please wait some time, then try again.
      security:
        - api-key: []
      x-codeSamples:
        - lang: typescript
          label: SubscribersController_markActionAsSeen
          source: >-
            import { Novu } from "@novu/api";

            import { MarkMessageActionAsSeenDtoStatus } from
            "@novu/api/models/components";


            const novu = new Novu({
              apiKey: "<YOUR_API_KEY_HERE>",
            });


            async function run() {
              const result = await novu.subscribers.messages.updateAsSeen({
                messageId: "<value>",
                type: "<value>",
                subscriberId: "<value>",
                markMessageActionAsSeenDto: {
                  status: MarkMessageActionAsSeenDtoStatus.Done,
                },
              });

              // Handle the result
              console.log(result)
            }


            run();
components:
  schemas:
    MarkMessageActionAsSeenDto:
      type: object
      properties:
        status:
          enum:
            - pending
            - done
          type: string
          description: Message action status
        payload:
          type: object
          description: Message action payload
      required:
        - status
    MessageResponseDto:
      type: object
      properties:
        _id:
          type: string
        _templateId:
          type: string
        _environmentId:
          type: string
        _messageTemplateId:
          type: string
        _organizationId:
          type: string
        _notificationId:
          type: string
        _subscriberId:
          type: string
        subscriber:
          $ref: '#/components/schemas/SubscriberResponseDto'
        template:
          $ref: '#/components/schemas/WorkflowResponse'
        templateIdentifier:
          type: string
        createdAt:
          type: string
        lastSeenDate:
          type: string
        lastReadDate:
          type: string
        content:
          oneOf:
            - $ref: '#/components/schemas/EmailBlock'
            - type: string
        transactionId:
          type: string
        subject:
          type: string
        channel:
          type: string
          enum:
            - in_app
            - email
            - sms
            - chat
            - push
        read:
          type: boolean
        seen:
          type: boolean
        email:
          type: string
        phone:
          type: string
        directWebhookUrl:
          type: string
        providerId:
          type: string
        deviceTokens:
          type: array
          items:
            type: string
        title:
          type: string
        cta:
          $ref: '#/components/schemas/MessageCTA'
        _feedId:
          type: string
          nullable: true
        status:
          type: string
          enum:
            - sent
            - error
            - warning
        errorId:
          type: string
        errorText:
          type: string
        payload:
          type: object
          description: The payload that was used to send the notification trigger
        overrides:
          type: object
          description: Provider specific overrides used when triggering the notification
      required:
        - _templateId
        - _environmentId
        - _messageTemplateId
        - _organizationId
        - _notificationId
        - _subscriberId
        - createdAt
        - content
        - transactionId
        - channel
        - read
        - seen
        - cta
        - status
        - errorId
        - errorText
        - payload
        - overrides
    SubscriberResponseDto:
      type: object
      properties:
        _id:
          type: string
          description: >-
            The internal id novu generated for your subscriber, this is not the
            subscriberId matching your query. See `subscriberId` for that
        firstName:
          type: string
        lastName:
          type: string
        email:
          type: string
        phone:
          type: string
        avatar:
          type: string
        locale:
          type: string
        subscriberId:
          type: string
          description: >-
            The internal identifier you used to create this subscriber, usually
            correlates to the id the user in your systems
        channels:
          description: Channels settings for subscriber
          type: array
          items:
            $ref: '#/components/schemas/ChannelSettings'
        isOnline:
          type: boolean
        lastOnlineAt:
          type: string
        _organizationId:
          type: string
        _environmentId:
          type: string
        deleted:
          type: boolean
        createdAt:
          type: string
        updatedAt:
          type: string
        __v:
          type: number
      required:
        - subscriberId
        - _organizationId
        - _environmentId
        - deleted
        - createdAt
        - updatedAt
    WorkflowResponse:
      type: object
      properties:
        _id:
          type: string
        name:
          type: string
        description:
          type: string
        active:
          type: boolean
        draft:
          type: boolean
        preferenceSettings:
          $ref: '#/components/schemas/PreferenceChannels'
        critical:
          type: boolean
        tags:
          type: array
          items:
            type: string
        steps:
          type: array
          items:
            $ref: '#/components/schemas/NotificationStep'
        _organizationId:
          type: string
        _creatorId:
          type: string
        _environmentId:
          type: string
        triggers:
          type: array
          items:
            $ref: '#/components/schemas/NotificationTrigger'
        _notificationGroupId:
          type: string
        _parentId:
          type: string
        deleted:
          type: boolean
        deletedAt:
          type: string
        deletedBy:
          type: string
        notificationGroup:
          $ref: '#/components/schemas/NotificationGroup'
        data:
          type: object
        workflowIntegrationStatus:
          type: object
      required:
        - name
        - description
        - active
        - draft
        - preferenceSettings
        - critical
        - tags
        - steps
        - _organizationId
        - _creatorId
        - _environmentId
        - triggers
        - _notificationGroupId
        - deleted
        - deletedAt
        - deletedBy
    EmailBlock:
      type: object
      properties:
        type:
          enum:
            - text
            - button
          type: string
        content:
          type: string
        url:
          type: string
        styles:
          $ref: '#/components/schemas/EmailBlockStyles'
      required:
        - type
        - content
    MessageCTA:
      type: object
      properties:
        type:
          type: string
          enum:
            - redirect
        data:
          $ref: '#/components/schemas/MessageCTAData'
        action:
          $ref: '#/components/schemas/MessageAction'
      required:
        - data
    ChannelSettings:
      type: object
      properties:
        providerId:
          type: string
          enum:
            - slack
            - discord
            - msteams
            - mattermost
            - ryver
            - zulip
            - grafana-on-call
            - getstream
            - rocket-chat
            - whatsapp-business
            - fcm
            - apns
            - expo
            - one-signal
            - pushpad
            - push-webhook
            - pusher-beams
          description: The provider identifier for the credentials
        integrationIdentifier:
          type: string
          description: The integration identifier
        credentials:
          description: Credentials payload for the specified provider
          allOf:
            - $ref: '#/components/schemas/ChannelCredentials'
        _integrationId:
          type: string
          description: Id of the integration that is used for this channel
      required:
        - providerId
        - credentials
        - _integrationId
    PreferenceChannels:
      type: object
      properties:
        email:
          type: boolean
        sms:
          type: boolean
        in_app:
          type: boolean
        chat:
          type: boolean
        push:
          type: boolean
    NotificationStep:
      type: object
      properties:
        _id:
          type: string
        uuid:
          type: string
        name:
          type: string
        _templateId:
          type: string
        active:
          type: boolean
        shouldStopOnFail:
          type: boolean
        template:
          $ref: '#/components/schemas/MessageTemplate'
        filters:
          type: array
          items:
            $ref: '#/components/schemas/StepFilter'
        _parentId:
          type: object
        metadata:
          oneOf:
            - $ref: '#/components/schemas/DigestRegularMetadata'
            - $ref: '#/components/schemas/DigestTimedMetadata'
            - $ref: '#/components/schemas/DelayRegularMetadata'
            - $ref: '#/components/schemas/DelayScheduledMetadata'
        replyCallback:
          type: object
        variants:
          $ref: '#/components/schemas/NotificationStepVariant'
    NotificationTrigger:
      type: object
      properties:
        type:
          type: string
          enum:
            - event
        identifier:
          type: string
        variables:
          type: array
          items:
            $ref: '#/components/schemas/NotificationTriggerVariable'
        subscriberVariables:
          type: array
          items:
            $ref: '#/components/schemas/NotificationTriggerVariable'
      required:
        - type
        - identifier
        - variables
    NotificationGroup:
      type: object
      properties:
        _id:
          type: string
        name:
          type: string
        _environmentId:
          type: string
        _organizationId:
          type: string
        _parentId:
          type: string
      required:
        - name
        - _environmentId
        - _organizationId
    EmailBlockStyles:
      type: object
      properties:
        textAlign:
          enum:
            - left
            - right
            - center
          type: string
    MessageCTAData:
      type: object
      properties:
        url:
          type: string
    MessageAction:
      type: object
      properties:
        status:
          enum:
            - pending
            - done
          type: string
        buttons:
          type: array
          items:
            $ref: '#/components/schemas/MessageButton'
        result:
          $ref: '#/components/schemas/MessageActionResult'
    ChannelCredentials:
      type: object
      properties:
        webhookUrl:
          type: string
          description: >-
            Webhook url used by chat app integrations. The webhook should be
            obtained from the chat app provider.
        channel:
          type: string
          description: Channel specification for Mattermost chat notifications
        deviceTokens:
          description: >-
            Contains an array of the subscriber device tokens for a given
            provider. Used on Push integrations
          type: array
          items:
            type: string
        alertUid:
          type: string
          description: alert_uid for grafana on-call webhook payload
        title:
          type: string
          description: title to be used with grafana on call webhook
        imageUrl:
          type: string
          description: image_url property fo grafana on call webhook
        state:
          type: string
          description: state property fo grafana on call webhook
        externalUrl:
          type: string
          description: link_to_upstream_details property fo grafana on call webhook
      required:
        - webhookUrl
    MessageTemplate:
      type: object
      properties: {}
    StepFilter:
      type: object
      properties:
        isNegated:
          type: boolean
        type:
          type: string
          enum:
            - BOOLEAN
            - TEXT
            - DATE
            - NUMBER
            - STATEMENT
            - LIST
            - MULTI_LIST
            - GROUP
        value:
          type: string
          enum:
            - AND
            - OR
        children:
          type: array
          items:
            $ref: '#/components/schemas/FieldFilterPart'
      required:
        - isNegated
        - type
        - value
        - children
    DigestRegularMetadata:
      type: object
      properties:
        amount:
          type: number
        unit:
          type: string
          enum:
            - seconds
            - minutes
            - hours
            - days
            - weeks
            - months
        digestKey:
          type: string
        type:
          type: string
          enum:
            - regular
            - backoff
        backoff:
          type: boolean
        backoffAmount:
          type: number
        backoffUnit:
          type: string
          enum:
            - seconds
            - minutes
            - hours
            - days
            - weeks
            - months
        updateMode:
          type: boolean
      required:
        - type
    DigestTimedMetadata:
      type: object
      properties:
        amount:
          type: number
        unit:
          type: string
          enum:
            - seconds
            - minutes
            - hours
            - days
            - weeks
            - months
        digestKey:
          type: string
        type:
          type: string
          enum:
            - timed
        timed:
          $ref: '#/components/schemas/TimedConfig'
      required:
        - type
    DelayRegularMetadata:
      type: object
      properties:
        amount:
          type: number
        unit:
          type: string
          enum:
            - seconds
            - minutes
            - hours
            - days
            - weeks
            - months
        type:
          type: string
          enum:
            - regular
      required:
        - type
    DelayScheduledMetadata:
      type: object
      properties:
        type:
          type: string
          enum:
            - scheduled
        delayPath:
          type: string
      required:
        - type
        - delayPath
    NotificationStepVariant:
      type: object
      properties:
        _id:
          type: string
        uuid:
          type: string
        name:
          type: string
        _templateId:
          type: string
        active:
          type: boolean
        shouldStopOnFail:
          type: boolean
        template:
          $ref: '#/components/schemas/MessageTemplate'
        filters:
          type: array
          items:
            $ref: '#/components/schemas/StepFilter'
        _parentId:
          type: object
        metadata:
          oneOf:
            - $ref: '#/components/schemas/DigestRegularMetadata'
            - $ref: '#/components/schemas/DigestTimedMetadata'
            - $ref: '#/components/schemas/DelayRegularMetadata'
            - $ref: '#/components/schemas/DelayScheduledMetadata'
        replyCallback:
          type: object
    NotificationTriggerVariable:
      type: object
      properties:
        name:
          type: string
      required:
        - name
    MessageButton:
      type: object
      properties:
        type:
          enum:
            - primary
            - secondary
            - clicked
          type: string
        content:
          type: string
        resultContent:
          type: string
      required:
        - type
        - content
    MessageActionResult:
      type: object
      properties:
        payload:
          type: object
        type:
          enum:
            - primary
            - secondary
            - clicked
          type: string
    FieldFilterPart:
      type: object
      properties:
        field:
          type: string
        value:
          type: string
        operator:
          type: string
          enum:
            - LARGER
            - SMALLER
            - LARGER_EQUAL
            - SMALLER_EQUAL
            - EQUAL
            - NOT_EQUAL
            - ALL_IN
            - ANY_IN
            - NOT_IN
            - BETWEEN
            - NOT_BETWEEN
            - LIKE
            - NOT_LIKE
            - IN
        'on':
          type: string
          enum:
            - subscriber
            - payload
      required:
        - field
        - value
        - operator
        - 'on'
    TimedConfig:
      type: object
      properties:
        atTime:
          type: string
        weekDays:
          type: array
          items:
            type: string
            enum:
              - monday
              - tuesday
              - wednesday
              - thursday
              - friday
              - saturday
              - sunday
        monthDays:
          type: array
          items:
            type: string
        ordinal:
          type: string
          enum:
            - '1'
            - '2'
            - '3'
            - '4'
            - '5'
            - last
        ordinalValue:
          type: string
          enum:
            - day
            - weekday
            - weekend
            - sunday
            - monday
            - tuesday
            - wednesday
            - thursday
            - friday
            - saturday
        monthlyType:
          type: string
          enum:
            - each
            - 'on'
  securitySchemes:
    api-key:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        API key authentication. Allowed headers-- "Authorization: ApiKey
        <api_key>".

````