Append New Message
Este endpoint permite agregar un nuevo mensaje a un TrustFeed en específico. Se necesita como parámetro el trust_feed_uuid para especificar a qué TrustFeed agregar el mensaje. Se pueden agregar varios tipos de mensajes, los cuales son de tipo compact, video y full_image.Los campos que recibe son:
- output_type
- title
- text
- media
- media_type
- action_type
- action_text
- action_link
Como respuesta, el endpoint devuelve el mensaje creado.
#
EndpointKey | Value | Description |
---|---|---|
Content-Type | application/json | |
Authorization | Bearer {{access_token}} | access_token obtained in Atenea |
URL Variables:
Key | Description |
---|---|
trust_feed_uuid | uuid del TrustFeed al cual se quiera agregar el mensaje |
caution
Recuerda que para utilizar este endpoint es necesario un access token obtenido en el servicio Atenea
#
BodyComo se mencionó antes, existen muchos tipos de mensajes, a continuación se mostrará ejemplos del payload para cada uno:
- Compact
- Video
- Full Image
Descripcíón de campos
Key | Required | Data Type | Description |
---|---|---|---|
output_type | false | String | Indica el tipo del mensjae a agregar. Algunos ejemplos de datos pueden ser trust_feed_compact o trust_feed_full_image |
title | true | String | Indica el título que tendrá el mensaje a agregar |
text | true | String | Indica el texto infomativo que saldrá en nuestro mensaje |
media | false | String | Campo que contiene la URL de algún recurso que se desee adjuntar al mensaje, por ejemplo imágenes, videos, etc. |
media_type | false | String | Campo encargado de indicar el tipo de recurso otorgado en la URL del campo media. Un ejemplo de valor puede ser img |
action_type | false | String | Campo que indica la acción del mensaje. Por ejemplo, si la intención del mensaje es mostrar una URL para accederla, el valor que se debiese usar es url |
action_text | false | String | Campo para indicar el texto o "label" del botón para el action_type otorgado |
action_link | false | String | Campo para indicar el enlace a acceder del action_type antes mencionado |
#
Code Examples#
Para Compact Message:- Curl
- JavaScript
- Python
#
Para Video Message:- Curl
- JavaScript
- Python
#
Para Full_image:- Curl
- JavaScript
- Python
#
Responses#
COMPACT MESSAGE - HTTP CODE: 201 CREATED- Added
- Added/Email
- Added/Call
#
VIDEO MESSAGE - HTTP CODE: 201 CREATED- Added
- Added/Email
- Added/Call
#
FULL_IMAGE MESSAGE - HTTP CODE: 201 CREATED- Added
- Added/Email
- Added/Call