Skip to content

prepare API model / client class for sending through web portal #1615

Description

@tomholub

part of #1545

Both endpoints accept Authorization header Bearer: IDTOKEN

grabbing a reply token before uploading a message

POST https://fes.<domain>/api/v1/message/new-reply-token

response (json):

data class MessageReplyTokenResponse(
  val replyToken: String
)

uploading message to web portal

POST https://fes.<domain>/api/v1/message

The content of the POST are a http multipart request with fields:

| multipart name | type | structure |
| details | application/json | see below |
| content | application/octet-stream | bytes |

request details structure (json)

data class MessageUploadRequest(
  val associateReplyToken: String, // the value you received when calling the first endpoint
  val from: String, // sender email
  val to: List<String>, // who message will be sent to
  val cc: List<String> = emptyList(), // same, cc
  val bcc: List<String> = emptyList() // same, bcc
)

response structure (json)

data class MessageUploadResponse(
  val url: String
)

With the above info you should be able to successfully make a request to upload a message to web portal. You will get back URL, which if you follow, should exist.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions