ClubReady Api

<back to all web services

UserListDateAddedRequest

The following routes are available for this service:
GET/users/date-addedList of users added in a certain date range.
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports ClubReady.Web.Api.Members.Model
Imports ClubReady.Core.Api.Models
Imports ClubReady.Web.Api
Imports ClubReady.Core.Users.Models

Namespace Global

    Namespace ClubReady.Core.Api.Models

        Public Partial Class ApiDtoBase
            Public Overridable Property ApiKey As String
            Public Overridable Property StoreId As Nullable(Of Integer)
            Public Overridable Property ChainId As Nullable(Of Integer)
        End Class

        Public Partial Class UserListDateAddedRequestDto
            Inherits ApiDtoBase
            Public Overridable Property FromDate As Date
            Public Overridable Property ToDate As Date
        End Class

        Public Partial Class UserListDateAddedResponseDto
            Public Sub New()
                Users = New List(Of ClubClient)
            End Sub

            Public Overridable Property Users As List(Of ClubClient)
        End Class
    End Namespace

    Namespace ClubReady.Core.Users.Models

        Public Partial Class ClubClient
            Public Overridable Property UserId As Integer
            Public Overridable Property Username As String
            Public Overridable Property FirstName As String
            Public Overridable Property LastName As String
            Public Overridable Property StoreId As Nullable(Of Integer)
            Public Overridable Property DateAdded As Nullable(Of Date)
            Public Overridable Property ReferredBy As Nullable(Of Integer)
            Public Overridable Property AddedBy As Nullable(Of Integer)
            Public Overridable Property ReferralTypeId As Nullable(Of Integer)
            Public Overridable Property ReferralTypeName As String
        End Class
    End Namespace

    Namespace ClubReady.Web.Api

        Public Enum RestrictedResourceType
            Store
            Chain
            User
            Undefined
        End Enum
    End Namespace

    Namespace ClubReady.Web.Api.Members.Model

        Public Partial Class UserListDateAddedRequest
            Inherits UserListDateAddedRequestDto
            Implements IRestrictedApiRequest
            '''<Summary>
            '''Api Key - grants access to resources
            '''</Summary>
            <ApiMember(DataType:="string", Description:="Api Key - grants access to resources", IsRequired:=true, Name:="ApiKey", ParameterType:="query")>
            Public Overridable Property ApiKey As String

            '''<Summary>
            '''Chain ID
            '''</Summary>
            <ApiMember(DataType:="integer", Description:="Chain ID", Name:="ChainId", ParameterType:="query")>
            Public Overridable Property ChainId As Nullable(Of Integer)

            '''<Summary>
            '''Store ID
            '''</Summary>
            <ApiMember(DataType:="integer", Description:="Store ID", Name:="StoreId", ParameterType:="query")>
            Public Overridable Property StoreId As Nullable(Of Integer)

            '''<Summary>
            '''UTC Format
            '''</Summary>
            <ApiMember(DataType:="date", Description:="UTC Format", IsRequired:=true, Name:="FromDate", ParameterType:="query")>
            Public Overridable Property FromDate As Date

            '''<Summary>
            '''Max 24 Hours (UTC Format)
            '''</Summary>
            <ApiMember(DataType:="date", Description:="Max 24 Hours (UTC Format)", IsRequired:=true, Name:="ToDate", ParameterType:="query")>
            Public Overridable Property ToDate As Date

            Public Overridable Property RestrictedId As Nullable(Of Integer)
            Public Overridable Property RestrictedResourceType As RestrictedResourceType
        End Class

        Public Partial Class UserListDateAddedResponse
            Inherits UserListDateAddedResponseDto
            Public Sub New()
                Users = New List(Of ClubClient)
            End Sub

            Public Overridable Property Users As List(Of ClubClient)
        End Class
    End Namespace
End Namespace

VB.NET UserListDateAddedRequest DTOs

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

HTTP + CSV

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

GET /users/date-added HTTP/1.1 
Host: clubready.com 
Accept: text/csv
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"Users":[{"UserId":0,"Username":"String","FirstName":"String","LastName":"String","StoreId":0,"DateAdded":"0001-01-01T00:00:00.0000000","ReferredBy":0,"AddedBy":0,"ReferralTypeId":0,"ReferralTypeName":"String"}]}