ClubManager.Api

<back to all web services

ViewUserGetUsers

Requires Authentication
Required role:API
The following routes are available for this service:
All Verbs/api/Query/UserGetUsers
import Foundation
import ServiceStack

// @AutoQueryViewer(Description="", IconUrl="octicon:database", Title="UserGetUsers")
public class ViewUserGetUsers : QueryDb<UserGetUsersInstance>
{
    required public init(){ super.init() }

    required public init(from decoder: Decoder) throws {
        try super.init(from: decoder)
    }

    public override func encode(to encoder: Encoder) throws {
        try super.encode(to: encoder)
    }
}

public class UserGetUsersInstance : Codable
{
    public var user:UserInstance?
    // @References(typeof(UserInstance))
    public var userId:Int?

    public var userName:String?
    public var name:String?
    public var email:String?
    public var mobilePhone:String?
    public var enabled:Bool?
    public var lastLogin:Date?
    public var created:Date?
    public var training:Bool?
    public var deleted:Bool?
    public var coursesCompleted:Int?
    public var displayHomeNotification:Bool?
    public var twoFactorEnabled:Bool?
    public var emailConfirmed:Bool?
    public var mobilePhoneConfirmed:Bool?
    public var notifications:Bool?
    public var changePassword:Date?
    public var activated:Date?
    public var member:MemberInstance?
    // @References(typeof(MemberInstance))
    public var memberId:Int?

    public var parentBranchId:Int?
    public var domain:String?
    public var identity:String?
    public var branchName:String?
    public var branchKey:String?
    public var publishableKey:String?
    public var secretKey:String?

    required public init(){}
}

public class UserInstance : Codable
{
    public var userId:Int?
    public var userName:String?
    public var name:String?
    public var email:String?
    public var mobilePhone:String?
    public var enabled:Bool?
    public var lastLogin:Date?
    public var created:Date?
    public var training:Bool?
    public var deleted:Bool?
    public var coursesCompleted:Int?
    public var displayHomeNotification:Bool?
    public var twoFactorEnabled:Bool?
    public var emailConfirmed:Bool?
    public var mobilePhoneConfirmed:Bool?
    public var notifications:Bool?
    public var changePassword:Date?
    public var activated:Date?

    required public init(){}
}

public class MemberInstance : Codable
{
    public var memberId:Int?
    public var memberType:Int?
    public var membershipNumber:String?
    public var cardNumber:String?
    public var companyName:String?
    public var surname:String?
    public var forenames:String?
    public var title:String?
    public var gender:Int?
    public var dateOfBirth:Date?
    public var address1:String?
    public var address2:String?
    public var city:String?
    public var county:String?
    public var postcode:String?
    public var homePhone:String?
    public var mobilePhone:String?
    public var emailAddress:String?
    public var emailOptOut:Bool?
    public var smsOptOut:Bool?
    public var phoneOptOut:Bool?
    public var letterOptOut:Bool?
    public var directDebitAccountHolder:String?
    public var directDebitAccountNumber:String?
    public var directDebitSortCode:String?
    public var joinedDate:Date?
    public var directDebitBankAddress:String?
    public var fullName:String?
    public var externalReference:String?
    public var photo:[UInt8] = []
    public var photoModifiedDate:Date?
    public var notes:String?
    public var deleted:Bool?
    public var demo:Bool?
    public var useExternalStatus:Bool?
    public var externalStatus:Int?
    public var freeText:String?
    public var memberKey:String?
    public var balance:Double?
    public var creditLimit:Double?
    public var createdDate:Date?
    public var modifiedDate:Date?
    public var deletedDate:Date?
    public var externalSource:Int?
    public var retentionMetric:Double?
    public var monthlyAttendanceFrequency:Double?
    public var assignedToUserId:Int?
    public var createdByUserId:Int?
    public var deletedByUserId:Int?
    public var lossReason:LossReasonInstance?
    // @References(typeof(LossReasonInstance))
    public var lossReasonId:Int?

    public var wonOrLost:Int?
    public var wonOrLostDate:Date?
    public var giftAidPermission:Bool?
    public var photoPermission:Bool?
    public var firstAidPermission:Bool?
    public var emergencyContact:String?
    public var wonOrLostByUser:UserInstance?
    // @References(typeof(UserInstance))
    public var wonOrLostByUserId:Int?

    public var agreedToTerms:Date?
    public var onlineBookingBanned:Bool?
    public var country:String?
    public var fingerprintEnrolled:Date?
    public var lastPaymentAmount:Double?
    public var pin:String?
    public var prospectingPoints:Int?
    public var achievementPoints:Int?
    public var parentForenames:String?
    public var parentSurname:String?

    required public init(){}
}

public class LossReasonInstance : Codable
{
    public var lossReasonId:Int?
    public var reason:String?
    public var deleted:Bool?
    public var demo:Bool?
    public var selectable:Bool?

    required public init(){}
}


Swift ViewUserGetUsers 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.

POST /api/Query/UserGetUsers HTTP/1.1 
Host: api.clubmanagercentral.com 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"Skip":0,"Take":0,"OrderBy":"String","OrderByDesc":"String","Include":"String","Fields":"String","Meta":{"String":"String"}}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"Offset":0,"Total":0,"Results":[{"User":{"UserId":0,"UserName":"String","Name":"String","Email":"String","MobilePhone":"String","Enabled":false,"LastLogin":"0001-01-01T00:00:00.0000000","Created":"0001-01-01T00:00:00.0000000","Training":false,"Deleted":false,"CoursesCompleted":0,"DisplayHomeNotification":false,"TwoFactorEnabled":false,"EmailConfirmed":false,"MobilePhoneConfirmed":false,"Notifications":false,"ChangePassword":"0001-01-01T00:00:00.0000000","Activated":"0001-01-01T00:00:00.0000000"},"UserId":0,"UserName":"String","Name":"String","Email":"String","MobilePhone":"String","Enabled":false,"LastLogin":"0001-01-01T00:00:00.0000000","Created":"0001-01-01T00:00:00.0000000","Training":false,"Deleted":false,"CoursesCompleted":0,"DisplayHomeNotification":false,"TwoFactorEnabled":false,"EmailConfirmed":false,"MobilePhoneConfirmed":false,"Notifications":false,"ChangePassword":"0001-01-01T00:00:00.0000000","Activated":"0001-01-01T00:00:00.0000000","Member":{"MemberId":0,"MemberType":0,"MembershipNumber":"String","CardNumber":"String","CompanyName":"String","Surname":"String","Forenames":"String","Title":"String","Gender":0,"DateOfBirth":"0001-01-01T00:00:00.0000000","Address1":"String","Address2":"String","City":"String","County":"String","Postcode":"String","HomePhone":"String","MobilePhone":"String","EmailAddress":"String","EmailOptOut":false,"SmsOptOut":false,"PhoneOptOut":false,"LetterOptOut":false,"DirectDebitAccountHolder":"String","DirectDebitAccountNumber":"String","DirectDebitSortCode":"String","JoinedDate":"0001-01-01T00:00:00.0000000","DirectDebitBankAddress":"String","FullName":"String","ExternalReference":"String","Photo":"AA==","PhotoModifiedDate":"0001-01-01T00:00:00.0000000","Notes":"String","Deleted":false,"Demo":false,"UseExternalStatus":false,"ExternalStatus":0,"FreeText":"String","MemberKey":"00000000000000000000000000000000","Balance":0,"CreditLimit":0,"CreatedDate":"0001-01-01T00:00:00.0000000","ModifiedDate":"0001-01-01T00:00:00.0000000","DeletedDate":"0001-01-01T00:00:00.0000000","ExternalSource":0,"RetentionMetric":0,"MonthlyAttendanceFrequency":0,"AssignedToUserId":0,"CreatedByUserId":0,"DeletedByUserId":0,"LossReason":{"LossReasonId":0,"Reason":"String","Deleted":false,"Demo":false,"Selectable":false},"LossReasonId":0,"WonOrLost":0,"WonOrLostDate":"0001-01-01T00:00:00.0000000","GiftAidPermission":false,"PhotoPermission":false,"FirstAidPermission":false,"EmergencyContact":"String","WonOrLostByUser":{"UserId":0,"UserName":"String","Name":"String","Email":"String","MobilePhone":"String","Enabled":false,"LastLogin":"0001-01-01T00:00:00.0000000","Created":"0001-01-01T00:00:00.0000000","Training":false,"Deleted":false,"CoursesCompleted":0,"DisplayHomeNotification":false,"TwoFactorEnabled":false,"EmailConfirmed":false,"MobilePhoneConfirmed":false,"Notifications":false,"ChangePassword":"0001-01-01T00:00:00.0000000","Activated":"0001-01-01T00:00:00.0000000"},"WonOrLostByUserId":0,"AgreedToTerms":"0001-01-01T00:00:00.0000000","OnlineBookingBanned":false,"Country":"String","FingerprintEnrolled":"0001-01-01T00:00:00.0000000","LastPaymentAmount":0,"Pin":"String","ProspectingPoints":0,"AchievementPoints":0,"ParentForenames":"String","ParentSurname":"String"},"MemberId":0,"ParentBranchId":0,"Domain":"String","Identity":"String","BranchName":"String","BranchKey":"00000000000000000000000000000000","PublishableKey":"String","SecretKey":"String"}],"Meta":{"String":"String"},"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}