/* Options:
Date: 2025-09-05 23:40:59
Version: 8.23
Tip: To override a DTO option, remove "//" prefix before updating
BaseUrl: https://api.bokamera.se
//GlobalNamespace:
//MakePartial: True
//MakeVirtual: True
//MakeInternal: False
//MakeDataContractsExtensible: False
//AddNullableAnnotations: False
//AddReturnMarker: True
//AddDescriptionAsComments: True
//AddDataContractAttributes: False
//AddIndexesToDataMembers: False
//AddGeneratedCodeAttributes: False
//AddResponseStatus: False
//AddImplicitVersion:
//InitializeCollections: True
//ExportValueTypes: False
IncludeTypes: CreateCustomer.*
//ExcludeTypes:
//AddNamespaces:
//AddDefaultXmlNamespace: http://schemas.servicestack.net/types
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using System.Globalization;
using ServiceStack.Data;
using System.Net;
using System.Net.Http.Headers;
using BokaMera.API.ServiceModel.Dtos;
using BokaMera.API.ServiceModel.Db;
namespace BokaMera.API.ServiceModel.Db
{
public partial class BaseModel
{
}
public partial class UserAccessKeys
: BaseModel
{
[Required]
public virtual Guid CompanyId { get; set; }
[Required]
public virtual int AccessKeyTypeId { get; set; }
[Required]
public virtual string Value { get; set; }
[Required]
public virtual Guid CustomerId { get; set; }
public virtual string Description { get; set; }
[Required]
public virtual Guid Id { get; set; }
}
}
namespace BokaMera.API.ServiceModel.Dtos
{
public partial class AddCustomField
{
public virtual int Id { get; set; }
public virtual string Value { get; set; }
}
public partial class AddUserAccessKey
{
///
///Specify 'Id' to update an existing access key, leave empty to create a new one
///
[ApiMember(Description="Specify 'Id' to update an existing access key, leave empty to create a new one")]
public virtual Guid? Id { get; set; }
///
///The company ID associated with this access key
///
[ApiMember(Description="The company ID associated with this access key")]
public virtual Guid? CompanyId { get; set; }
///
///The type of access key to create
///
[ApiMember(Description="The type of access key to create")]
public virtual int AccessKeyTypeId { get; set; }
///
///The actual key value or token
///
[ApiMember(Description="The actual key value or token")]
public virtual string Value { get; set; }
///
///The customer ID this access key is associated with
///
[ApiMember(Description="The customer ID this access key is associated with")]
public virtual Guid? CustomerId { get; set; }
///
///A description or note about this access key
///
[ApiMember(Description="A description or note about this access key")]
public virtual string Description { get; set; }
}
[Route("/customers", "POST")]
[ApiResponse(Description="Returned if there is a validation error on the input parameters", StatusCode=400)]
[ApiResponse(Description="Returned if the current user is not allowed to perform the action", StatusCode=401)]
[ValidateRequest("IsAuthenticated")]
public partial class CreateCustomer
: IReturn
{
public CreateCustomer()
{
CustomFields = new List{};
AccessKeys = new List{};
}
///
///Enter the company and id for the customer, if blank company id and you are an admin, your company id will be used.
///
[ApiMember(Description="Enter the company and id for the customer, if blank company id and you are an admin, your company id will be used.", ParameterType="query")]
public virtual Guid? CompanyId { get; set; }
[ApiMember(IsRequired=true)]
public virtual string Firstname { get; set; }
[ApiMember(IsRequired=true)]
public virtual string Lastname { get; set; }
[ApiMember(IsRequired=true)]
public virtual string Phone { get; set; }
[ApiMember]
public virtual string Email { get; set; }
///
///If Custom Fields are added to the customer, here you will send the id and the value for each custom field to be updated
///
[ApiMember(Description="If Custom Fields are added to the customer, here you will send the id and the value for each custom field to be updated")]
public virtual List CustomFields { get; set; }
///
///List of Access Keys
///
[ApiMember(Description="List of Access Keys")]
public virtual List AccessKeys { get; set; }
///
///Customer invoice adress
///
[ApiMember(Description="Customer invoice adress")]
public virtual InvoiceAddressToHandle InvoiceAddress { get; set; }
}
public partial class CustomerQueryResponse
{
public CustomerQueryResponse()
{
CustomFields = new List{};
CustomFieldValues = new List{};
Comments = new List{};
AccessKeys = new List{};
}
public virtual Guid Id { get; set; }
public virtual string Firstname { get; set; }
public virtual string Lastname { get; set; }
public virtual string Email { get; set; }
public virtual string Phone { get; set; }
public virtual string ImageUrl { get; set; }
public virtual List CustomFields { get; set; }
public virtual List CustomFieldValues { get; set; }
public virtual List Comments { get; set; }
public virtual List AccessKeys { get; set; }
public virtual DateTime Updated { get; set; }
public virtual DateTime Created { get; set; }
public virtual Object ResponseStatus { get; set; }
public virtual bool SubscribedToNewsletter { get; set; }
public virtual InvoiceAddressResponse InvoiceAddress { get; set; }
}
public partial class InvoiceAddressToHandle
{
public virtual string CorporateIdentityNumber { get; set; }
public virtual string InvoiceAddress1 { get; set; }
public virtual string InvoiceAddress2 { get; set; }
public virtual string InvoiceCity { get; set; }
public virtual string InvoicePostalCode { get; set; }
public virtual string InvoiceCountryCode { get; set; }
}
public partial class UpdateCustomerResponse
: CustomerQueryResponse
{
public UpdateCustomerResponse()
{
DeletedAccessKeys = new List{};
CreatedOrUpdatedAccessKeys = new List{};
}
public virtual string FacebookUserName { get; set; }
public virtual Guid? UserId { get; set; }
public virtual Guid? CompanyId { get; set; }
public virtual DateTime? CreatedDate { get; set; }
public virtual List DeletedAccessKeys { get; set; }
public virtual List CreatedOrUpdatedAccessKeys { get; set; }
}
}