Export Room
    • Dark
      Light
    • PDF

    Export Room

    • Dark
      Light
    • PDF

    Article summary

    Post
    /api/v1/rooms.export

    Export room to a file or email.

    Permission required: mail-messages

    Changelog

    VersionDescription
    3.8.0Added
    Header parameters
    X-Auth-Token
    stringRequired

    The authToken of the authenticated user.

    ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
    X-User-Id
    stringRequired

    The userId of the authenticated user.

    ExamplerbAXPnMktTFbNpwtJ
    Body parameters
    Example
    {
      "rid": "iu7jtPAhvEeAS5tNq",
      "type": "file",
      "dateFrom": "2000-01-01",
      "dateTo": "2021-11-25",
      "format": "html",
      "toUsers": [
        "test.user"
      ],
      "toEmails": [
        "[email protected]"
      ],
      "messages": [
        "yd6NBgNoiWATgDoFt",
        "BoCjicj9DdYoMHHeo",
        "tajMB3aX3sawFWe8W"
      ],
      "subject": "Test Subject "
    }
    object
    rid
    string Required

    The room Id.

    type
    string Required

    How you want the room to be exported. The type of export selected determines the remaining required parameters. It can be either email or file.

    dateFrom
    string

    Start date to begin fetching. Use dateFrom if the type is file. By default, it selects the oldest possible date.

    dateTo
    string

    End date for fetching. By default it selects the current date. Use dateTo if the type is file.

    format
    string Required

    The file type to export as. It can either be html or json. Use format if the type is file.

    toUsers
    Array of string Required

    An array of users that should recieve the export. ecieve the export. It is required if type is email.

    string
    toEmails
    Array of string Required

    An array of any additional emails that should recieve the export. It is required if type is email.

    string
    messages
    Array of string Required

    An array of messageId for the messages that should be exported. It is required if type is email.

    string
    subject
    string Required

    The subject of the email. It is required if type is email.

    Responses
    200

    OK

    Success
    {
      "success": true
    }
    object
    success
    boolean
    400

    Bad Request

    Invalid Room ID
    {
      "success": false,
      "error": "[error-invalid-room]",
      "errorType": "error-invalid-room"
    }
    Invalid Format
    {
      "success": false,
      "error": "[error-invalid-format]",
      "errorType": "error-invalid-format"
    }
    Invalid Params
    {
      "success": false,
      "error": "[error-invalid-params]",
      "errorType": "error-invalid-params"
    }
    object
    success
    boolean
    error
    string
    errorType
    string
    401

    Unauthorized

    Authorization Error
    {
      "status": "error",
      "message": "You must be logged in to do this."
    }
    object
    status
    string
    message
    string
    403

    Forbidden

    Permission Error
    {
      "success": false,
      "error": "User does not have the permissions required for this action [error-unauthorized]"
    }
    object
    success
    boolean
    error
    string

    Was this article helpful?

    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.