Requires any of the roles: | bookingsupplier-administrator-write, superadmin, bookingsupplier-administrator-read |
GET | /gdpr/customers/{CustomerId} | Get all customer information stored on the customer | Get all information stored on the customer |
---|
namespace BokaMera.API.ServiceModel.Dtos
open System
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations
[<AllowNullLiteral>]
type GDPRCustomerBookingsResponse() =
///<summary>
///The company ID associated with this booking
///</summary>
[<ApiMember(Description="The company ID associated with this booking")>]
member val CompanyId:Guid = new Guid() with get,set
///<summary>
///The unique identifier of the booking
///</summary>
[<ApiMember(Description="The unique identifier of the booking")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The customer ID associated with this booking
///</summary>
[<ApiMember(Description="The customer ID associated with this booking")>]
member val CustomerId:Guid = new Guid() with get,set
///<summary>
///The service ID for this booking
///</summary>
[<ApiMember(Description="The service ID for this booking")>]
member val ServiceId:Int32 = new Int32() with get,set
///<summary>
///The current status of the booking
///</summary>
[<ApiMember(Description="The current status of the booking")>]
member val StatusId:Int32 = new Int32() with get,set
///<summary>
///The start date and time of the booking
///</summary>
[<ApiMember(Description="The start date and time of the booking")>]
member val From:DateTime = new DateTime() with get,set
///<summary>
///The end date and time of the booking
///</summary>
[<ApiMember(Description="The end date and time of the booking")>]
member val To:DateTime = new DateTime() with get,set
///<summary>
///The date when the booking was cancelled or unbooked
///</summary>
[<ApiMember(Description="The date when the booking was cancelled or unbooked")>]
member val UnbookedOn:Nullable<DateTime> = new Nullable<DateTime>() with get,set
///<summary>
///Comments added when the booking was cancelled
///</summary>
[<ApiMember(Description="Comments added when the booking was cancelled")>]
member val UnbookedComments:String = null with get,set
///<summary>
///Comments added when the booking was created
///</summary>
[<ApiMember(Description="Comments added when the booking was created")>]
member val BookedComments:String = null with get,set
///<summary>
///The name of the person who made the booking
///</summary>
[<ApiMember(Description="The name of the person who made the booking")>]
member val BookedBy:String = null with get,set
///<summary>
///General comments about the booking
///</summary>
[<ApiMember(Description="General comments about the booking")>]
member val Comments:String = null with get,set
///<summary>
///Custom text field 1
///</summary>
[<ApiMember(Description="Custom text field 1")>]
member val TextField1:String = null with get,set
///<summary>
///Custom text field 2
///</summary>
[<ApiMember(Description="Custom text field 2")>]
member val TextField2:String = null with get,set
///<summary>
///Custom text field 3
///</summary>
[<ApiMember(Description="Custom text field 3")>]
member val TextField3:String = null with get,set
///<summary>
///Custom text field 4
///</summary>
[<ApiMember(Description="Custom text field 4")>]
member val TextField4:String = null with get,set
///<summary>
///Custom text field 5
///</summary>
[<ApiMember(Description="Custom text field 5")>]
member val TextField5:String = null with get,set
///<summary>
///Custom text field 6
///</summary>
[<ApiMember(Description="Custom text field 6")>]
member val TextField6:String = null with get,set
///<summary>
///Custom text field 7
///</summary>
[<ApiMember(Description="Custom text field 7")>]
member val TextField7:String = null with get,set
///<summary>
///Custom text field 8
///</summary>
[<ApiMember(Description="Custom text field 8")>]
member val TextField8:String = null with get,set
///<summary>
///Custom text field 9
///</summary>
[<ApiMember(Description="Custom text field 9")>]
member val TextField9:String = null with get,set
///<summary>
///Custom text field 10
///</summary>
[<ApiMember(Description="Custom text field 10")>]
member val TextField10:String = null with get,set
///<summary>
///Custom text field 11
///</summary>
[<ApiMember(Description="Custom text field 11")>]
member val TextField11:String = null with get,set
///<summary>
///Custom text field 12
///</summary>
[<ApiMember(Description="Custom text field 12")>]
member val TextField12:String = null with get,set
///<summary>
///Custom text field 13
///</summary>
[<ApiMember(Description="Custom text field 13")>]
member val TextField13:String = null with get,set
///<summary>
///Custom text field 14
///</summary>
[<ApiMember(Description="Custom text field 14")>]
member val TextField14:String = null with get,set
///<summary>
///Custom text field 15
///</summary>
[<ApiMember(Description="Custom text field 15")>]
member val TextField15:String = null with get,set
///<summary>
///Custom text field 16
///</summary>
[<ApiMember(Description="Custom text field 16")>]
member val TextField16:String = null with get,set
///<summary>
///Custom text field 17
///</summary>
[<ApiMember(Description="Custom text field 17")>]
member val TextField17:String = null with get,set
///<summary>
///Custom text field 18
///</summary>
[<ApiMember(Description="Custom text field 18")>]
member val TextField18:String = null with get,set
///<summary>
///Custom text field 19
///</summary>
[<ApiMember(Description="Custom text field 19")>]
member val TextField19:String = null with get,set
///<summary>
///Custom text field 20
///</summary>
[<ApiMember(Description="Custom text field 20")>]
member val TextField20:String = null with get,set
///<summary>
///The date when the booking was last updated
///</summary>
[<ApiMember(Description="The date when the booking was last updated")>]
member val UpdatedDate:DateTime = new DateTime() with get,set
///<summary>
///The date when the booking was created
///</summary>
[<ApiMember(Description="The date when the booking was created")>]
member val CreatedDate:DateTime = new DateTime() with get,set
///<summary>
///Comments sent to the customer about this booking
///</summary>
[<ApiMember(Description="Comments sent to the customer about this booking")>]
member val CommentsToCustomer:String = null with get,set
[<AllowNullLiteral>]
type GDPRCustomerMessageLogResponse() =
///<summary>
///The company ID associated with this message
///</summary>
[<ApiMember(Description="The company ID associated with this message")>]
member val CompanyId:Guid = new Guid() with get,set
///<summary>
///The unique identifier of the message
///</summary>
[<ApiMember(Description="The unique identifier of the message")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The booking ID this message is related to, if any
///</summary>
[<ApiMember(Description="The booking ID this message is related to, if any")>]
member val BookingId:Nullable<Int32> = new Nullable<Int32>() with get,set
///<summary>
///The recipient of the message
///</summary>
[<ApiMember(Description="The recipient of the message")>]
member val Receiver:String = null with get,set
///<summary>
///The sender of the message
///</summary>
[<ApiMember(Description="The sender of the message")>]
member val Sender:String = null with get,set
///<summary>
///The title or subject of the message
///</summary>
[<ApiMember(Description="The title or subject of the message")>]
member val MessageTitle:String = null with get,set
///<summary>
///The body content of the message
///</summary>
[<ApiMember(Description="The body content of the message")>]
member val MessageBody:String = null with get,set
///<summary>
///The name of the person who created the message
///</summary>
[<ApiMember(Description="The name of the person who created the message")>]
member val CreatedBy:String = null with get,set
///<summary>
///The date when the message was created
///</summary>
[<ApiMember(Description="The date when the message was created")>]
member val Created:DateTime = new DateTime() with get,set
///<summary>
///Whether the message was successfully sent
///</summary>
[<ApiMember(Description="Whether the message was successfully sent")>]
member val Sent:Boolean = new Boolean() with get,set
///<summary>
///The date when the message was sent
///</summary>
[<ApiMember(Description="The date when the message was sent")>]
member val SentDate:Nullable<DateTime> = new Nullable<DateTime>() with get,set
///<summary>
///The method used to send the message (e.g., email, SMS)
///</summary>
[<ApiMember(Description="The method used to send the message (e.g., email, SMS)")>]
member val SendMethodId:Int32 = new Int32() with get,set
[<AllowNullLiteral>]
type InvoiceAddressResponse() =
member val InvoiceAddressId:Guid = new Guid() with get,set
member val UserId:Nullable<Guid> = new Nullable<Guid>() with get,set
member val CorporateIdentityNumber:String = null with get,set
member val InvoiceAddress1:String = null with get,set
member val InvoiceAddress2:String = null with get,set
member val InvoiceCity:String = null with get,set
member val InvoicePostalCode:String = null with get,set
member val InvoiceCountryCode:String = null with get,set
[<AllowNullLiteral>]
type UserProfileResponse() =
member val Id:Guid = new Guid() with get,set
member val Firstname:String = null with get,set
member val Lastname:String = null with get,set
member val Phone:String = null with get,set
member val Email:String = null with get,set
member val InvoiceAddress:InvoiceAddressResponse = null with get,set
[<AllowNullLiteral>]
type GDPRCustomerInfoResponse() =
///<summary>
///The unique identifier of the user
///</summary>
[<ApiMember(Description="The unique identifier of the user")>]
member val UserId:Guid = new Guid() with get,set
///<summary>
///The user's first name
///</summary>
[<ApiMember(Description="The user's first name")>]
member val Firstname:String = null with get,set
///<summary>
///The user's last name
///</summary>
[<ApiMember(Description="The user's last name")>]
member val Lastname:String = null with get,set
///<summary>
///The user's phone number
///</summary>
[<ApiMember(Description="The user's phone number")>]
member val Phone:String = null with get,set
///<summary>
///The user's email address
///</summary>
[<ApiMember(Description="The user's email address")>]
member val Email:String = null with get,set
///<summary>
///Whether the user account is currently active
///</summary>
[<ApiMember(Description="Whether the user account is currently active")>]
member val Active:Boolean = new Boolean() with get,set
///<summary>
///The user's Facebook username
///</summary>
[<ApiMember(Description="The user's Facebook username")>]
member val FacebookUsername:String = null with get,set
///<summary>
///Custom text field 1
///</summary>
[<ApiMember(Description="Custom text field 1")>]
member val TextField1:String = null with get,set
///<summary>
///Custom text field 2
///</summary>
[<ApiMember(Description="Custom text field 2")>]
member val TextField2:String = null with get,set
///<summary>
///Custom text field 3
///</summary>
[<ApiMember(Description="Custom text field 3")>]
member val TextField3:String = null with get,set
///<summary>
///Custom text field 4
///</summary>
[<ApiMember(Description="Custom text field 4")>]
member val TextField4:String = null with get,set
///<summary>
///Custom text field 5
///</summary>
[<ApiMember(Description="Custom text field 5")>]
member val TextField5:String = null with get,set
///<summary>
///Custom text field 6
///</summary>
[<ApiMember(Description="Custom text field 6")>]
member val TextField6:String = null with get,set
///<summary>
///Custom text field 7
///</summary>
[<ApiMember(Description="Custom text field 7")>]
member val TextField7:String = null with get,set
///<summary>
///Custom text field 8
///</summary>
[<ApiMember(Description="Custom text field 8")>]
member val TextField8:String = null with get,set
///<summary>
///Custom text field 9
///</summary>
[<ApiMember(Description="Custom text field 9")>]
member val TextField9:String = null with get,set
///<summary>
///Custom text field 10
///</summary>
[<ApiMember(Description="Custom text field 10")>]
member val TextField10:String = null with get,set
///<summary>
///Custom text field 11
///</summary>
[<ApiMember(Description="Custom text field 11")>]
member val TextField11:String = null with get,set
///<summary>
///Custom text field 12
///</summary>
[<ApiMember(Description="Custom text field 12")>]
member val TextField12:String = null with get,set
///<summary>
///Custom text field 13
///</summary>
[<ApiMember(Description="Custom text field 13")>]
member val TextField13:String = null with get,set
///<summary>
///Custom text field 14
///</summary>
[<ApiMember(Description="Custom text field 14")>]
member val TextField14:String = null with get,set
///<summary>
///Custom text field 15
///</summary>
[<ApiMember(Description="Custom text field 15")>]
member val TextField15:String = null with get,set
///<summary>
///Custom text field 16
///</summary>
[<ApiMember(Description="Custom text field 16")>]
member val TextField16:String = null with get,set
///<summary>
///Custom text field 17
///</summary>
[<ApiMember(Description="Custom text field 17")>]
member val TextField17:String = null with get,set
///<summary>
///Custom text field 18
///</summary>
[<ApiMember(Description="Custom text field 18")>]
member val TextField18:String = null with get,set
///<summary>
///Custom text field 19
///</summary>
[<ApiMember(Description="Custom text field 19")>]
member val TextField19:String = null with get,set
///<summary>
///Custom text field 20
///</summary>
[<ApiMember(Description="Custom text field 20")>]
member val TextField20:String = null with get,set
///<summary>
///The date when the customer information was last updated
///</summary>
[<ApiMember(Description="The date when the customer information was last updated")>]
member val Updated:DateTime = new DateTime() with get,set
///<summary>
///The date when the customer information was created
///</summary>
[<ApiMember(Description="The date when the customer information was created")>]
member val Created:DateTime = new DateTime() with get,set
[<AllowNullLiteral>]
type GDPRCustomerCommentsResponse() =
///<summary>
///The company ID associated with this comment
///</summary>
[<ApiMember(Description="The company ID associated with this comment")>]
member val CompanyId:Guid = new Guid() with get,set
///<summary>
///The unique identifier of the comment
///</summary>
[<ApiMember(Description="The unique identifier of the comment")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The customer ID this comment is associated with
///</summary>
[<ApiMember(Description="The customer ID this comment is associated with")>]
member val CustomerId:Guid = new Guid() with get,set
///<summary>
///The content of the comment
///</summary>
[<ApiMember(Description="The content of the comment")>]
member val Comments:String = null with get,set
///<summary>
///The date when the comment was last updated
///</summary>
[<ApiMember(Description="The date when the comment was last updated")>]
member val Updated:DateTime = new DateTime() with get,set
///<summary>
///The date when the comment was created
///</summary>
[<ApiMember(Description="The date when the comment was created")>]
member val Created:DateTime = new DateTime() with get,set
///<summary>
///URL to any image associated with the comment
///</summary>
[<ApiMember(Description="URL to any image associated with the comment")>]
member val ImageUrl:Uri = null with get,set
[<AllowNullLiteral>]
type GDPRCustomerNewsletterLogResponse() =
///<summary>
///The company ID associated with this newsletter
///</summary>
[<ApiMember(Description="The company ID associated with this newsletter")>]
member val CompanyId:Guid = new Guid() with get,set
///<summary>
///The unique identifier of the newsletter log entry
///</summary>
[<ApiMember(Description="The unique identifier of the newsletter log entry")>]
member val Id:Int32 = new Int32() with get,set
///<summary>
///The newsletter ID this log entry is related to, if any
///</summary>
[<ApiMember(Description="The newsletter ID this log entry is related to, if any")>]
member val NewslettersId:Nullable<Int32> = new Nullable<Int32>() with get,set
///<summary>
///The recipient of the newsletter
///</summary>
[<ApiMember(Description="The recipient of the newsletter")>]
member val Receiver:String = null with get,set
///<summary>
///The sender of the newsletter
///</summary>
[<ApiMember(Description="The sender of the newsletter")>]
member val Sender:String = null with get,set
///<summary>
///The title or subject of the newsletter
///</summary>
[<ApiMember(Description="The title or subject of the newsletter")>]
member val MessageTitle:String = null with get,set
///<summary>
///The body content of the newsletter
///</summary>
[<ApiMember(Description="The body content of the newsletter")>]
member val MessageBody:String = null with get,set
///<summary>
///Whether the newsletter was successfully sent
///</summary>
[<ApiMember(Description="Whether the newsletter was successfully sent")>]
member val Sent:Boolean = new Boolean() with get,set
///<summary>
///The date when the newsletter was created
///</summary>
[<ApiMember(Description="The date when the newsletter was created")>]
member val Created:DateTime = new DateTime() with get,set
[<AllowNullLiteral>]
type GDPRCustomerQueryResponse() =
///<summary>
///List of all bookings associated with the customer
///</summary>
[<ApiMember(Description="List of all bookings associated with the customer")>]
member val Bookings:ResizeArray<GDPRCustomerBookingsResponse> = new ResizeArray<GDPRCustomerBookingsResponse>() with get,set
///<summary>
///List of all message logs associated with the customer
///</summary>
[<ApiMember(Description="List of all message logs associated with the customer")>]
member val MessageLog:ResizeArray<GDPRCustomerMessageLogResponse> = new ResizeArray<GDPRCustomerMessageLogResponse>() with get,set
///<summary>
///The user profile information for the customer
///</summary>
[<ApiMember(Description="The user profile information for the customer")>]
member val UserProfile:UserProfileResponse = null with get,set
///<summary>
///Detailed customer information
///</summary>
[<ApiMember(Description="Detailed customer information")>]
member val Customer:GDPRCustomerInfoResponse = null with get,set
///<summary>
///List of all comments associated with the customer
///</summary>
[<ApiMember(Description="List of all comments associated with the customer")>]
member val CustomerComment:ResizeArray<GDPRCustomerCommentsResponse> = new ResizeArray<GDPRCustomerCommentsResponse>() with get,set
///<summary>
///List of all newsletter logs associated with the customer
///</summary>
[<ApiMember(Description="List of all newsletter logs associated with the customer")>]
member val NewsletterLog:ResizeArray<GDPRCustomerNewsletterLogResponse> = new ResizeArray<GDPRCustomerNewsletterLogResponse>() with get,set
///<summary>
///Response status information
///</summary>
[<ApiMember(Description="Response status information")>]
member val ResponseStatus:ResponseStatus = null with get,set
[<ValidateRequest(Validator="IsAuthenticated")>]
[<AllowNullLiteral>]
type GDPRCustomerQuery() =
///<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")>]
member val CompanyId:Nullable<Guid> = new Nullable<Guid>() with get,set
///<summary>
///Id of the customer
///</summary>
[<ApiMember(Description="Id of the customer", IsRequired=true, ParameterType="path")>]
member val CustomerId:Guid = new Guid() with get,set
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=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: testapi.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","InvoiceAddress":{"UserId":"00000000-0000-0000-0000-000000000000","CorporateIdentityNumber":"String","InvoiceAddress1":"String","InvoiceAddress2":"String","InvoiceCity":"String","InvoicePostalCode":"String","InvoiceCountryCode":"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"}}}