ClubManager.Api

<back to all web services

WebService.GetHeaderMenuRequest

Requires Authentication
The following routes are available for this service:
POST,GET/api/Web/GetHeaderMenu
import Foundation
import ServiceStack

public class HeaderMenu : Codable
{
    public var header:String?
    public var headerMenuItems:[HeaderMenuItem] = []

    required public init(){}
}

public class HeaderMenuItem : Codable
{
    public var name:String?
    public var url:String?
    public var isCurrent:Bool?
    public var feature:Feature?
    public var hideFeature:Bool?
    public var roles:[String] = []
    public var subHeaderMenuItems:[SubHeaderMenuItem] = []

    required public init(){}
}

// @Flags()
public enum Feature : Int, Codable
{
    case None = 0
    case Standard = 1
    case Bookings = 2
    case Rota = 4
    case GoCardless = 8
    case HomeScreen = 16
    case EPos = 32
    case Attendance = 64
    case Sales = 128
    case PaymentCollections = 256
    case MailChimp = 512
    case MultiSite = 1024
    case AccountingDashboard = 2048
    case OtherDashboards = 4096
    case Reports = 8192
    case AdvancedAccounting = 16384
    case MemberLicenseDates = 32768
    case FaceRecognition = 65536
    case MemberAccountCreation = 131072
    case Automation = 262144
    case FacebookMarketing = 524288
    case Grades = 1048576
    case ZoomIntegration = 2097152
    case SalesTargetChart = 4194304
    case CustomApp = 8388608
    case CustomAttributesOnPortal = 16777216
    case NoExport = 33554432
    case EnterpriseClubPerformanceDashboards = 67108864
}

public class SubHeaderMenuItem : Codable
{
    public var name:String?
    public var Description:String?
    public var url:String?
    public var icon:String?
    public var roles:[String] = []
    public var feature:Feature?
    public var hideForCMGo:Bool?
    public var showFeatureUnavailable:Bool?
    public var hasIcon:Bool?
    public var hasFontAwesomeIcon:Bool?

    required public init(){}
}


Swift WebService.GetHeaderMenuRequest DTOs

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

HTTP + JSV

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

POST /api/Web/GetHeaderMenu HTTP/1.1 
Host: api.clubmanagercentral.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	UserId: 0,
	MemberId: 0
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	Header: String,
	HeaderMenuItems: 
	[
		{
			Name: String,
			Url: String,
			IsCurrent: False,
			Feature: 0,
			HideFeature: False,
			Roles: 
			[
				String
			],
			SubHeaderMenuItems: 
			[
				{
					Name: String,
					Description: String,
					Url: String,
					Icon: String,
					Roles: 
					[
						String
					],
					Feature: 0,
					HideForCMGo: False,
					ShowFeatureUnavailable: False,
					HasIcon: True,
					HasFontAwesomeIcon: False
				}
			]
		}
	]
}