| GET | /user/{userId}/authorize | Get user if exists and is not disabled |
|---|
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports Richemont.Booster2.PublicApi.Security.ServiceModel
Namespace Global
Namespace Richemont.Booster2.PublicApi.Security.ServiceModel
Public Partial Class Auth
Public Sub New()
posGroups = New List(Of Integer)
roles = New List(Of Guid)
End Sub
'''<Summary>
'''Brand Trigram
'''</Summary>
<ApiMember(Description:="Brand Trigram", IsRequired:=true)>
Public Overridable Property brand As String
'''<Summary>
'''List of Pos Group - in case of internal user
'''</Summary>
<ApiMember(Description:="List of Pos Group - in case of internal user")>
Public Overridable Property posGroups As List(Of Integer)
'''<Summary>
'''Pos Code - in case of external users
'''</Summary>
<ApiMember(Description:="Pos Code - in case of external users")>
Public Overridable Property posCode As String
'''<Summary>
'''List of user roles
'''</Summary>
<ApiMember(Description:="List of user roles", IsRequired:=true)>
Public Overridable Property roles As List(Of Guid)
End Class
Public Partial Class GetUserAuth
'''<Summary>
'''User's UserID
'''</Summary>
<ApiMember(Description:="User's UserID", IsRequired:=true)>
Public Overridable Property userId As String
End Class
Public Partial Class GetUserAuthResponse
Inherits List(Of Auth)
End Class
End Namespace
End Namespace
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /user/{userId}/authorize HTTP/1.1
Host: dev-api-booster.richemont.com
Accept: application/xml
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <ArrayOfAuth xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Richemont.Booster2.PublicApi.Security.ServiceModel" />