Create Message

POST /api/v1.0/messages

This endpoint creates a new message.

application/json

Body Required

  • type string Required

    Message Type

  • text string Required

    Message Text

  • url string Required

    URL

  • doc_attachment string Required

    Document Attachment

  • entity_key string Required

    Entity Key

  • chat_id string Required

    Chat ID

  • message_id string Required

    Message ID

  • task_id string Required

    Task ID

  • file_id string Required

    File ID

  • doc_id string Required

    Document ID

  • task object
  • external_files array[string]

    List of External files

  • nifty_files array[string]

    List of Nifty Files

  • date string(date-time)

    Date

  • bot_name string

    BOT Name

  • bot_avatar string

    BOT Avtar

  • hidden array[string]

    Hidden

  • emails string

    Emails

  • annotation_id string

    Annotation ID

  • context_text string

    Context Text

  • audio_duration string

    Audion Duration

Responses

  • 201 application/json

    The resource created successfully

    Hide response attributes Show response attributes object
    • message string Required
    • data object Required
  • 401

    The client request has not been completed because it lacks valid authentication credentials for the requested resource.

  • 403

    The client does not have access rights to the content.

  • 405

    The request method is known by the server but is not supported by the target resource.

POST /api/v1.0/messages
curl \
 --request POST 'https://openapi.niftypm.com/api/v1.0/messages' \
 --header "Content-Type: application/json" \
 --data '{"type":"string","text":"string","url":"string","doc_attachment":"string","entity_key":"string","chat_id":"string","message_id":"string","task_id":"string","file_id":"string","doc_id":"string","task":{},"external_files":["string"],"nifty_files":["string"],"date":"2025-05-04T09:42:00Z","bot_name":"string","bot_avatar":"string","hidden":["string"],"emails":"string","annotation_id":"string","context_text":"string","audio_duration":"string"}'
Request examples
{
  "type": "string",
  "text": "string",
  "url": "string",
  "doc_attachment": "string",
  "entity_key": "string",
  "chat_id": "string",
  "message_id": "string",
  "task_id": "string",
  "file_id": "string",
  "doc_id": "string",
  "task": {},
  "external_files": [
    "string"
  ],
  "nifty_files": [
    "string"
  ],
  "date": "2025-05-04T09:42:00Z",
  "bot_name": "string",
  "bot_avatar": "string",
  "hidden": [
    "string"
  ],
  "emails": "string",
  "annotation_id": "string",
  "context_text": "string",
  "audio_duration": "string"
}
Response examples (201)
{
  "message": "string",
  "data": {}
}