Test

<back to all web services

GetChatHistory

The following routes are available for this service:
All Verbs/chathistory
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports Test.ServiceInterface

Namespace Global

    Namespace Test.ServiceInterface

        Public Partial Class ChatMessage
            Public Overridable Property Id As Long
            Public Overridable Property Channel As String
            Public Overridable Property FromUserId As String
            Public Overridable Property FromName As String
            Public Overridable Property DisplayName As String
            Public Overridable Property Message As String
            Public Overridable Property UserAuthId As String
            Public Overridable Property Private As Boolean
        End Class

        Public Partial Class GetChatHistory
            Public Sub New()
                Channels = New String(){}
            End Sub

            Public Overridable Property Channels As String()
            Public Overridable Property AfterId As Nullable(Of Long)
            Public Overridable Property Take As Nullable(Of Integer)
        End Class

        Public Partial Class GetChatHistoryResponse
            Public Sub New()
                Results = New List(Of ChatMessage)
            End Sub

            Public Overridable Property Results As List(Of ChatMessage)
            Public Overridable Property ResponseStatus As ResponseStatus
        End Class
    End Namespace
End Namespace

VB.NET GetChatHistory DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /chathistory HTTP/1.1 
Host: test.servicestack.net 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"channels":["String"],"afterId":0,"take":0}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"results":[{"id":0,"channel":"String","fromUserId":"String","fromName":"String","displayName":"String","message":"String","userAuthId":"String","private":false}],"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}