ClubReady Api

<back to all web services

UserAccountRequest

The following routes are available for this service:
PUT/users/{UserId}Update user account info
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

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 UserAccountRequestDto
            Inherits ApiDtoBase
            Public Overridable Property UserId As Integer
            Public Overridable Property FirstName As String
            Public Overridable Property LastName As String
            Public Overridable Property HomePhone As String
            Public Overridable Property CellPhone As String
            Public Overridable Property Address1 As String
            Public Overridable Property City As String
            Public Overridable Property State As String
            Public Overridable Property Zip As String
            Public Overridable Property Email As String
            Public Overridable Property Gender As String
            Public Overridable Property DateOfBirth As Nullable(Of Date)
            Public Overridable Property Username As String
            Public Overridable Property ExternalId As String
            Public Overridable Property EmergencyContactName As String
            Public Overridable Property EmergencyContactPhone As String
            Public Overridable Property EmergencyContactType As String
            Public Overridable Property ProspectTypeId As Nullable(Of Integer)
        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 UserAccountRequest
            Inherits UserAccountRequestDto
            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>
            '''
            '''</Summary>
            <ApiMember(DataType:="integer", Description:="", IsRequired:=true, Name:="UserId", ParameterType:="query")>
            Public Overridable Property UserId As Integer

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

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

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="FirstName", ParameterType:="query")>
            Public Overridable Property FirstName As String

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="LastName", ParameterType:="query")>
            Public Overridable Property LastName As String

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="HomePhone", ParameterType:="query")>
            Public Overridable Property HomePhone As String

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="CellPhone", ParameterType:="query")>
            Public Overridable Property CellPhone As String

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="Address1", ParameterType:="query")>
            Public Overridable Property Address1 As String

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="City", ParameterType:="query")>
            Public Overridable Property City As String

            '''<Summary>
            '''(Format:2 characters; Example:'MO')
            '''</Summary>
            <ApiMember(DataType:="string", Description:="(Format:2 characters; Example:'MO')", Name:="State", ParameterType:="query")>
            Public Overridable Property State As String

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="Zip", ParameterType:="query")>
            Public Overridable Property Zip As String

            '''<Summary>
            '''
            '''</Summary>
            <ApiMember(DataType:="string", Description:="", Name:="Email", ParameterType:="query")>
            Public Overridable Property Email As String

            '''<Summary>
            '''Gender (Format:'M'|'F')
            '''</Summary>
            <ApiMember(DataType:="string", Description:="Gender (Format:'M'|'F')", Name:="Gender", ParameterType:="query")>
            Public Overridable Property Gender As String

            '''<Summary>
            '''Date of Birth (Format:YYYY-MM-DD)
            '''</Summary>
            <ApiMember(DataType:="date", Description:="Date of Birth (Format:YYYY-MM-DD)", Name:="DateOfBirth", ParameterType:="query")>
            Public Overridable Property DateOfBirth As Nullable(Of Date)

            '''<Summary>
            '''Username should be between 4 and 255 characters long
            '''</Summary>
            <ApiMember(DataType:="string", Description:="Username should be between 4 and 255 characters long", Name:="Username", ParameterType:="query")>
            Public Overridable Property Username As String

            '''<Summary>
            '''Unique ID for the user from your system. We store internally as ExternalUserId
            '''</Summary>
            <ApiMember(DataType:="string", Description:="Unique ID for the user from your system. We store internally as ExternalUserId", Name:="ExternalId", ParameterType:="query")>
            Public Overridable Property ExternalId As String

            '''<Summary>
            '''Emergency contact name
            '''</Summary>
            <ApiMember(DataType:="string", Description:="Emergency contact name", Name:="EmergencyContactName", ParameterType:="query")>
            Public Overridable Property EmergencyContactName As String

            '''<Summary>
            '''Emergency contact phone number
            '''</Summary>
            <ApiMember(DataType:="string", Description:="Emergency contact phone number", Name:="EmergencyContactPhone", ParameterType:="query")>
            Public Overridable Property EmergencyContactPhone As String

            '''<Summary>
            '''Emergency contact relationship
            '''</Summary>
            <ApiMember(DataType:="string", Description:="Emergency contact relationship", Name:="EmergencyContactType", ParameterType:="query")>
            Public Overridable Property EmergencyContactType As String

            '''<Summary>
            '''Prospect Type Id
            '''</Summary>
            <ApiMember(DataType:="integer", Description:="Prospect Type Id", Name:="ProspectTypeId", ParameterType:="query")>
            Public Overridable Property ProspectTypeId As Nullable(Of Integer)

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

VB.NET UserAccountRequest 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.

PUT /users/{UserId} HTTP/1.1 
Host: clubready.com 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"ApiKey":"String","UserId":0,"StoreId":0,"ChainId":0,"FirstName":"String","LastName":"String","HomePhone":"String","CellPhone":"String","Address1":"String","City":"String","State":"String","Zip":"String","Email":"String","Gender":"String","DateOfBirth":"0001-01-01T00:00:00.0000000","Username":"String","ExternalId":"String","EmergencyContactName":"String","EmergencyContactPhone":"String","EmergencyContactType":"String","ProspectTypeId":0,"RestrictedId":0,"RestrictedResourceType":"User"}