BokaMera.API.Host

<back to all web services

GDPRCustomerQuery

Requires Authentication
Requires any of the roles:bookingsupplier-administrator-write, superadmin, bookingsupplier-administrator-read
The following routes are available for this service:
GET/gdpr/customers/{CustomerId}Get all customer information stored on the customerGet all information stored on the customer
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports BokaMera.API.ServiceModel.Dtos

Namespace Global

    Namespace BokaMera.API.ServiceModel.Dtos

        Public Partial Class GDPRCustomerBookingsResponse
            Public Overridable Property CompanyId As Guid
            Public Overridable Property Id As Integer
            Public Overridable Property CustomerId As Guid
            Public Overridable Property ServiceId As Integer
            Public Overridable Property StatusId As Integer
            Public Overridable Property From As Date
            Public Overridable Property To As Date
            Public Overridable Property UnbookedOn As Nullable(Of Date)
            Public Overridable Property UnbookedComments As String
            Public Overridable Property BookedComments As String
            Public Overridable Property BookedBy As String
            Public Overridable Property Comments As String
            Public Overridable Property TextField1 As String
            Public Overridable Property TextField2 As String
            Public Overridable Property TextField3 As String
            Public Overridable Property TextField4 As String
            Public Overridable Property TextField5 As String
            Public Overridable Property TextField6 As String
            Public Overridable Property TextField7 As String
            Public Overridable Property TextField8 As String
            Public Overridable Property TextField9 As String
            Public Overridable Property TextField10 As String
            Public Overridable Property TextField11 As String
            Public Overridable Property TextField12 As String
            Public Overridable Property TextField13 As String
            Public Overridable Property TextField14 As String
            Public Overridable Property TextField15 As String
            Public Overridable Property TextField16 As String
            Public Overridable Property TextField17 As String
            Public Overridable Property TextField18 As String
            Public Overridable Property TextField19 As String
            Public Overridable Property TextField20 As String
            Public Overridable Property UpdatedDate As Date
            Public Overridable Property CreatedDate As Date
            Public Overridable Property CommentsToCustomer As String
        End Class

        Public Partial Class GDPRCustomerCommentsResponse
            Public Overridable Property CompanyId As Guid
            Public Overridable Property Id As Integer
            Public Overridable Property CustomerId As Guid
            Public Overridable Property Comments As String
            Public Overridable Property Updated As Date
            Public Overridable Property Created As Date
            Public Overridable Property ImageUrl As Uri
        End Class

        Public Partial Class GDPRCustomerInfoResponse
            Public Overridable Property UserId As Guid
            Public Overridable Property Firstname As String
            Public Overridable Property Lastname As String
            Public Overridable Property Phone As String
            Public Overridable Property Email As String
            Public Overridable Property Active As Boolean
            Public Overridable Property FacebookUsername As String
            Public Overridable Property TextField1 As String
            Public Overridable Property TextField2 As String
            Public Overridable Property TextField3 As String
            Public Overridable Property TextField4 As String
            Public Overridable Property TextField5 As String
            Public Overridable Property TextField6 As String
            Public Overridable Property TextField7 As String
            Public Overridable Property TextField8 As String
            Public Overridable Property TextField9 As String
            Public Overridable Property TextField10 As String
            Public Overridable Property TextField11 As String
            Public Overridable Property TextField12 As String
            Public Overridable Property TextField13 As String
            Public Overridable Property TextField14 As String
            Public Overridable Property TextField15 As String
            Public Overridable Property TextField16 As String
            Public Overridable Property TextField17 As String
            Public Overridable Property TextField18 As String
            Public Overridable Property TextField19 As String
            Public Overridable Property TextField20 As String
            Public Overridable Property Updated As Date
            Public Overridable Property Created As Date
        End Class

        Public Partial Class GDPRCustomerMessageLogResponse
            Public Overridable Property CompanyId As Guid
            Public Overridable Property Id As Integer
            Public Overridable Property BookingId As Nullable(Of Integer)
            Public Overridable Property Receiver As String
            Public Overridable Property Sender As String
            Public Overridable Property MessageTitle As String
            Public Overridable Property MessageBody As String
            Public Overridable Property CreatedBy As String
            Public Overridable Property Created As Date
            Public Overridable Property Sent As Boolean
            Public Overridable Property SentDate As Nullable(Of Date)
            Public Overridable Property SendMethodId As Integer
        End Class

        Public Partial Class GDPRCustomerNewsletterLogResponse
            Public Overridable Property CompanyId As Guid
            Public Overridable Property Id As Integer
            Public Overridable Property NewslettersId As Nullable(Of Integer)
            Public Overridable Property Receiver As String
            Public Overridable Property Sender As String
            Public Overridable Property MessageTitle As String
            Public Overridable Property MessageBody As String
            Public Overridable Property Sent As Boolean
            Public Overridable Property Created As Date
        End Class

        <ValidateRequest(Validator:="IsAuthenticated")>
        Public Partial Class GDPRCustomerQuery
            Implements ICompany
            '''<Summary>
            '''Enter the company and id you want to see the information for a resource, if blank company id and you are an admin, your company id will be used. If blank id, all resources will be shown 
            '''</Summary>
            <ApiMember(Description:="Enter the company and id you want to see the information for a resource, if blank company id and you are an admin, your company id will be used. If blank id, all resources will be shown ", IsRequired:=true, ParameterType:="query")>
            Public Overridable Property CompanyId As Nullable(Of Guid)

            '''<Summary>
            '''Id of the customer
            '''</Summary>
            <ApiMember(Description:="Id of the customer", IsRequired:=true, ParameterType:="path")>
            Public Overridable Property CustomerId As Guid
        End Class

        Public Partial Class GDPRCustomerQueryResponse
            Public Sub New()
                Bookings = New List(Of GDPRCustomerBookingsResponse)
                MessageLog = New List(Of GDPRCustomerMessageLogResponse)
                CustomerComment = New List(Of GDPRCustomerCommentsResponse)
                NewsletterLog = New List(Of GDPRCustomerNewsletterLogResponse)
            End Sub

            Public Overridable Property Bookings As List(Of GDPRCustomerBookingsResponse)
            Public Overridable Property MessageLog As List(Of GDPRCustomerMessageLogResponse)
            Public Overridable Property UserProfile As UserProfileResponse
            Public Overridable Property Customer As GDPRCustomerInfoResponse
            Public Overridable Property CustomerComment As List(Of GDPRCustomerCommentsResponse)
            Public Overridable Property NewsletterLog As List(Of GDPRCustomerNewsletterLogResponse)
            Public Overridable Property ResponseStatus As ResponseStatus
        End Class

        Public Partial Class UserProfileResponse
            Public Overridable Property Id As Guid
            Public Overridable Property Firstname As String
            Public Overridable Property Lastname As String
            Public Overridable Property Phone As String
            Public Overridable Property Email As String
        End Class
    End Namespace
End Namespace

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

GET /gdpr/customers/{CustomerId} HTTP/1.1 
Host: api.bokamera.se 
Accept: text/csv
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"Bookings":[{"Id":0,"ServiceId":0,"StatusId":0,"UnbookedOn":"0001-01-01T00:00:00","UnbookedComments":"String","BookedComments":"String","BookedBy":"String","Comments":"String","TextField1":"String","TextField2":"String","TextField3":"String","TextField4":"String","TextField5":"String","TextField6":"String","TextField7":"String","TextField8":"String","TextField9":"String","TextField10":"String","TextField11":"String","TextField12":"String","TextField13":"String","TextField14":"String","TextField15":"String","TextField16":"String","TextField17":"String","TextField18":"String","TextField19":"String","TextField20":"String","CommentsToCustomer":"String"}],"MessageLog":[{"Id":0,"BookingId":0,"Receiver":"String","Sender":"String","MessageTitle":"String","MessageBody":"String","CreatedBy":"String","Sent":false,"SentDate":"0001-01-01T00:00:00","SendMethodId":0}],"UserProfile":{"Firstname":"String","Lastname":"String","Phone":"String","Email":"String"},"Customer":{"Firstname":"String","Lastname":"String","Phone":"String","Email":"String","Active":false,"FacebookUsername":"String","TextField1":"String","TextField2":"String","TextField3":"String","TextField4":"String","TextField5":"String","TextField6":"String","TextField7":"String","TextField8":"String","TextField9":"String","TextField10":"String","TextField11":"String","TextField12":"String","TextField13":"String","TextField14":"String","TextField15":"String","TextField16":"String","TextField17":"String","TextField18":"String","TextField19":"String","TextField20":"String"},"CustomerComment":[{"Id":0,"Comments":"String"}],"NewsletterLog":[{"Id":0,"NewslettersId":0,"Receiver":"String","Sender":"String","MessageTitle":"String","MessageBody":"String","Sent":false}],"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}