ClubReady Api

<back to all web services

UserAccountRequest

The following routes are available for this service:
PUT/users/{UserId}Update user account info
namespace ClubReady.Core.Api.Models

open System
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations

    [<AllowNullLiteral>]
    type ApiDtoBase() = 
        member val ApiKey:String = null with get,set
        member val StoreId:Nullable<Int32> = new Nullable<Int32>() with get,set
        member val ChainId:Nullable<Int32> = new Nullable<Int32>() with get,set

    [<AllowNullLiteral>]
    type UserAccountRequestDto() = 
        inherit ApiDtoBase()
        member val UserId:Int32 = new Int32() with get,set
        member val FirstName:String = null with get,set
        member val LastName:String = null with get,set
        member val HomePhone:String = null with get,set
        member val CellPhone:String = null with get,set
        member val Address1:String = null with get,set
        member val City:String = null with get,set
        member val State:String = null with get,set
        member val Zip:String = null with get,set
        member val Email:String = null with get,set
        member val Gender:String = null with get,set
        member val DateOfBirth:Nullable<DateTime> = new Nullable<DateTime>() with get,set
        member val Username:String = null with get,set
        member val ExternalId:String = null with get,set
        member val EmergencyContactName:String = null with get,set
        member val EmergencyContactPhone:String = null with get,set
        member val EmergencyContactType:String = null with get,set
        member val ProspectTypeId:Nullable<Int32> = new Nullable<Int32>() with get,set

    type RestrictedResourceType =
        | Store = 0
        | Chain = 1
        | User = 2
        | Undefined = 3

    [<AllowNullLiteral>]
    type UserAccountRequest() = 
        inherit UserAccountRequestDto()
        ///<summary>
        ///Api Key - grants access to resources
        ///</summary>
        [<ApiMember(DataType="string", Description="Api Key - grants access to resources", IsRequired=true, Name="ApiKey", ParameterType="query")>]
        member val ApiKey:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="integer", Description="", IsRequired=true, Name="UserId", ParameterType="query")>]
        member val UserId:Int32 = new Int32() with get,set

        ///<summary>
        ///StoreId OR ChainId is required
        ///</summary>
        [<ApiMember(DataType="integer", Description="StoreId OR ChainId is required", Name="StoreId", ParameterType="query")>]
        member val StoreId:Nullable<Int32> = new Nullable<Int32>() with get,set

        ///<summary>
        ///StoreId OR ChainId is required
        ///</summary>
        [<ApiMember(DataType="integer", Description="StoreId OR ChainId is required", Name="ChainId", ParameterType="query")>]
        member val ChainId:Nullable<Int32> = new Nullable<Int32>() with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="FirstName", ParameterType="query")>]
        member val FirstName:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="LastName", ParameterType="query")>]
        member val LastName:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="HomePhone", ParameterType="query")>]
        member val HomePhone:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="CellPhone", ParameterType="query")>]
        member val CellPhone:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="Address1", ParameterType="query")>]
        member val Address1:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="City", ParameterType="query")>]
        member val City:String = null with get,set

        ///<summary>
        ///(Format:2 characters; Example:'MO')
        ///</summary>
        [<ApiMember(DataType="string", Description="(Format:2 characters; Example:'MO')", Name="State", ParameterType="query")>]
        member val State:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="Zip", ParameterType="query")>]
        member val Zip:String = null with get,set

        ///<summary>
        ///
        ///</summary>
        [<ApiMember(DataType="string", Description="", Name="Email", ParameterType="query")>]
        member val Email:String = null with get,set

        ///<summary>
        ///Gender (Format:'M'|'F')
        ///</summary>
        [<ApiMember(DataType="string", Description="Gender (Format:'M'|'F')", Name="Gender", ParameterType="query")>]
        member val Gender:String = null with get,set

        ///<summary>
        ///Date of Birth (Format:YYYY-MM-DD)
        ///</summary>
        [<ApiMember(DataType="date", Description="Date of Birth (Format:YYYY-MM-DD)", Name="DateOfBirth", ParameterType="query")>]
        member val DateOfBirth:Nullable<DateTime> = new Nullable<DateTime>() with get,set

        ///<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")>]
        member val Username:String = null with get,set

        ///<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")>]
        member val ExternalId:String = null with get,set

        ///<summary>
        ///Emergency contact name
        ///</summary>
        [<ApiMember(DataType="string", Description="Emergency contact name", Name="EmergencyContactName", ParameterType="query")>]
        member val EmergencyContactName:String = null with get,set

        ///<summary>
        ///Emergency contact phone number
        ///</summary>
        [<ApiMember(DataType="string", Description="Emergency contact phone number", Name="EmergencyContactPhone", ParameterType="query")>]
        member val EmergencyContactPhone:String = null with get,set

        ///<summary>
        ///Emergency contact relationship
        ///</summary>
        [<ApiMember(DataType="string", Description="Emergency contact relationship", Name="EmergencyContactType", ParameterType="query")>]
        member val EmergencyContactType:String = null with get,set

        ///<summary>
        ///Prospect Type Id
        ///</summary>
        [<ApiMember(DataType="integer", Description="Prospect Type Id", Name="ProspectTypeId", ParameterType="query")>]
        member val ProspectTypeId:Nullable<Int32> = new Nullable<Int32>() with get,set

        member val RestrictedId:Nullable<Int32> = new Nullable<Int32>() with get,set
        member val RestrictedResourceType:RestrictedResourceType = new RestrictedResourceType() with get,set

F# 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"}