Chore: Add additional information to conversation meta (#795)
Chore: Add additional information to conversation meta
This commit is contained in:
parent
96da27f1f6
commit
d4ff9f5b45
2 changed files with 4 additions and 2 deletions
|
@ -1,7 +1,9 @@
|
||||||
json.meta do
|
json.meta do
|
||||||
json.labels @conversation.label_list
|
json.labels @conversation.label_list
|
||||||
json.additional_attributes @conversation.additional_attributes
|
json.additional_attributes @conversation.additional_attributes
|
||||||
json.contact_id @conversation.contact_id
|
json.contact @conversation.contact.push_event_data
|
||||||
|
json.assignee @conversation.assignee.push_event_data if @conversation.assignee.present?
|
||||||
|
json.agent_last_seen_at @conversation.agent_last_seen_at
|
||||||
end
|
end
|
||||||
|
|
||||||
json.payload do
|
json.payload do
|
||||||
|
|
|
@ -116,7 +116,7 @@ RSpec.describe 'Conversation Messages API', type: :request do
|
||||||
as: :json
|
as: :json
|
||||||
|
|
||||||
expect(response).to have_http_status(:success)
|
expect(response).to have_http_status(:success)
|
||||||
expect(JSON.parse(response.body, symbolize_names: true)[:meta][:contact_id]).to eq(conversation.contact_id)
|
expect(JSON.parse(response.body, symbolize_names: true)[:meta][:contact][:id]).to eq(conversation.contact_id)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue