feat: Conversation and contact endpoint (#3198)

This commit is contained in:
Tejaswini Chile
2021-10-20 18:14:56 +05:30
committed by GitHub
parent b0041ccf3f
commit 658a511b88
11 changed files with 200 additions and 24 deletions

View File

@@ -2,7 +2,7 @@ class Api::V1::Accounts::ConversationsController < Api::V1::Accounts::BaseContro
include Events::Types
include DateRangeHelper
before_action :conversation, except: [:index, :meta, :search, :create]
before_action :conversation, except: [:index, :meta, :search, :create, :filter]
before_action :contact_inbox, only: [:create]
def index
@@ -31,6 +31,10 @@ class Api::V1::Accounts::ConversationsController < Api::V1::Accounts::BaseContro
def show; end
def filter
@conversations = Current.account.conversations.limit(10)
end
def mute
@conversation.mute!
head :ok