BokaMera.API.Host

<back to all web services

EAccountingCustomerQuery

The following routes are available for this service:
GET/eaccounting/customers
"use strict";
export class QueryBase {
    /** @param {{Skip?:number,Take?:number,OrderBy?:string,OrderByDesc?:string,Include?:string,Fields?:string,Meta?:{ [index:string]: string; }}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {?number} */
    Skip;
    /** @type {?number} */
    Take;
    /** @type {?string} */
    OrderBy;
    /** @type {?string} */
    OrderByDesc;
    /** @type {?string} */
    Include;
    /** @type {?string} */
    Fields;
    /** @type {?{ [index:string]: string; }} */
    Meta;
}
/** @typedef T {any} */
export class QueryData extends QueryBase {
    /** @param {{Skip?:number,Take?:number,OrderBy?:string,OrderByDesc?:string,Include?:string,Fields?:string,Meta?:{ [index:string]: string; }}} [init] */
    constructor(init) { super(init); Object.assign(this, init) }
}
export class EAccountingInvoiceAddress {
    /** @param {{CorporateIdentityNumber?:string,InvoiceAddress1?:string,InvoiceAddress2?:string,InvoiceCity?:string,InvoicePostalCode?:string,InvoiceCountryCode?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    CorporateIdentityNumber;
    /** @type {string} */
    InvoiceAddress1;
    /** @type {string} */
    InvoiceAddress2;
    /** @type {string} */
    InvoiceCity;
    /** @type {string} */
    InvoicePostalCode;
    /** @type {string} */
    InvoiceCountryCode;
}
export class EAccountingTermsOfPaymentQueryResponse {
    /** @param {{Id?:string,Name?:string,NameEnglish?:string,NumberOfDays?:number,TermsOfPaymentTypeId?:number,TermsOfPaymentTypeText?:string,AvailableForSales?:boolean,AvailableForPurchase?:boolean}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Id;
    /** @type {string} */
    Name;
    /** @type {string} */
    NameEnglish;
    /** @type {number} */
    NumberOfDays;
    /** @type {number} */
    TermsOfPaymentTypeId;
    /** @type {string} */
    TermsOfPaymentTypeText;
    /** @type {boolean} */
    AvailableForSales;
    /** @type {boolean} */
    AvailableForPurchase;
}
export class CustomerLabelQueryResponse {
    /** @param {{Id?:string,Name?:string,Description?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Id;
    /** @type {string} */
    Name;
    /** @type {string} */
    Description;
}
export class DirectDebitCustomerSettingsQueryResponse {
    /** @param {{MandateId?:string,MandateType?:number,SequenceType?:number,SigningDate?:string,EndDate?:string,LatestDirectDebit?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    MandateId;
    /** @type {number} */
    MandateType;
    /** @type {number} */
    SequenceType;
    /** @type {string} */
    SigningDate;
    /** @type {string} */
    EndDate;
    /** @type {string} */
    LatestDirectDebit;
}
export class EAccountingCustomerQueryResponse {
    /** @param {{Id?:string,CustomerNumber?:string,CorporateIdentityNumber?:string,ContactPersonEmail?:string,ContactPersonMobile?:string,ContactPersonName?:string,ContactPersonPhone?:string,CurrencyCode?:string,GLN?:string,InvoiceCity?:string,InvoicePostalCode?:string,EmailAddress?:string,EmailAddressOrder?:string,EmailAddressQuote?:string,InvoiceAddress?:EAccountingInvoiceAddress,DeliveryCustomerName?:string,DeliveryAddress1?:string,DeliveryAddress2?:string,DeliveryCity?:string,DeliveryCountryCode?:string,DeliveryPostalCode?:string,DeliveryMethodId?:string,DeliveryTermId?:string,PayToAccountId?:string,Name?:string,Note?:string,ReverseChargeOnConstructionServices?:boolean,WebshopCustomerNumber?:number,MobilePhone?:string,Telephone?:string,TermsOfPaymentId?:string,EAccountingTermsOfPayment?:EAccountingTermsOfPaymentQueryResponse,VatNumber?:string,WwwAddress?:string,LastInvoiceDate?:string,IsPrivatePerson?:boolean,IsNorthernIreland?:boolean,DiscountPercentage?:number,ChangedUtc?:string,IsActive?:boolean,ForceBookkeepVat?:boolean,EdiGlnNumber?:string,SalesDocumentLanguage?:string,ElectronicAddress?:string,ElectronicReference?:string,EdiServiceDelivererId?:string,AutoInvoiceActivationEmailSentDate?:string,AutoInvoiceRegistrationRequestSentDate?:string,EmailAddresses?:string[],CustomerLabels?:CustomerLabelQueryResponse[],MessageThreads?:string[],Notes?:string[],IsFutureInvoiceDateAllowed?:boolean,DeliveryBasedVat?:boolean,SalesPriceListId?:string,Iban?:string,DirectDebitCustomerSettings?:DirectDebitCustomerSettingsQueryResponse,DiscountAgreementId?:string,UnpaidInvoicesAmount?:number}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    Id;
    /** @type {string} */
    CustomerNumber;
    /** @type {string} */
    CorporateIdentityNumber;
    /** @type {string} */
    ContactPersonEmail;
    /** @type {string} */
    ContactPersonMobile;
    /** @type {string} */
    ContactPersonName;
    /** @type {string} */
    ContactPersonPhone;
    /** @type {string} */
    CurrencyCode;
    /** @type {string} */
    GLN;
    /** @type {string} */
    InvoiceCity;
    /** @type {string} */
    InvoicePostalCode;
    /** @type {string} */
    EmailAddress;
    /** @type {string} */
    EmailAddressOrder;
    /** @type {string} */
    EmailAddressQuote;
    /** @type {EAccountingInvoiceAddress} */
    InvoiceAddress;
    /** @type {string} */
    DeliveryCustomerName;
    /** @type {string} */
    DeliveryAddress1;
    /** @type {string} */
    DeliveryAddress2;
    /** @type {string} */
    DeliveryCity;
    /** @type {string} */
    DeliveryCountryCode;
    /** @type {string} */
    DeliveryPostalCode;
    /** @type {string} */
    DeliveryMethodId;
    /** @type {string} */
    DeliveryTermId;
    /** @type {string} */
    PayToAccountId;
    /** @type {string} */
    Name;
    /** @type {string} */
    Note;
    /** @type {boolean} */
    ReverseChargeOnConstructionServices;
    /** @type {?number} */
    WebshopCustomerNumber;
    /** @type {string} */
    MobilePhone;
    /** @type {string} */
    Telephone;
    /** @type {string} */
    TermsOfPaymentId;
    /** @type {EAccountingTermsOfPaymentQueryResponse} */
    EAccountingTermsOfPayment;
    /** @type {string} */
    VatNumber;
    /** @type {string} */
    WwwAddress;
    /** @type {string} */
    LastInvoiceDate;
    /** @type {boolean} */
    IsPrivatePerson;
    /** @type {boolean} */
    IsNorthernIreland;
    /** @type {?number} */
    DiscountPercentage;
    /** @type {?string} */
    ChangedUtc;
    /** @type {boolean} */
    IsActive;
    /** @type {boolean} */
    ForceBookkeepVat;
    /** @type {string} */
    EdiGlnNumber;
    /** @type {string} */
    SalesDocumentLanguage;
    /** @type {string} */
    ElectronicAddress;
    /** @type {string} */
    ElectronicReference;
    /** @type {string} */
    EdiServiceDelivererId;
    /** @type {?string} */
    AutoInvoiceActivationEmailSentDate;
    /** @type {?string} */
    AutoInvoiceRegistrationRequestSentDate;
    /** @type {string[]} */
    EmailAddresses = [];
    /** @type {CustomerLabelQueryResponse[]} */
    CustomerLabels = [];
    /** @type {string[]} */
    MessageThreads = [];
    /** @type {string[]} */
    Notes = [];
    /** @type {boolean} */
    IsFutureInvoiceDateAllowed;
    /** @type {boolean} */
    DeliveryBasedVat;
    /** @type {string} */
    SalesPriceListId;
    /** @type {string} */
    Iban;
    /** @type {DirectDebitCustomerSettingsQueryResponse} */
    DirectDebitCustomerSettings;
    /** @type {string} */
    DiscountAgreementId;
    /** @type {number} */
    UnpaidInvoicesAmount;
}
export class EAccountingCustomerQuery extends QueryData {
    /** @param {{CompanyId?:string,Skip?:number,Take?:number,OrderBy?:string,OrderByDesc?:string,Include?:string,Fields?:string,Meta?:{ [index:string]: string; }}} [init] */
    constructor(init) { super(init); Object.assign(this, init) }
    /** @type {?string} */
    CompanyId;
}
export class AccessKeyTypeResponse {
    /** @param {{Id?:number,KeyType?:string,Description?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    Id;
    /** @type {string} */
    KeyType;
    /** @type {string} */
    Description;
}
/** @typedef T {any} */
export class QueryResponse {
    /** @param {{Offset?:number,Total?:number,Results?:T[],Meta?:{ [index:string]: string; },ResponseStatus?:ResponseStatus}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {number} */
    Offset;
    /** @type {number} */
    Total;
    /** @type {T[]} */
    Results = [];
    /** @type {?{ [index:string]: string; }} */
    Meta;
    /** @type {?ResponseStatus} */
    ResponseStatus;
}

JavaScript EAccountingCustomerQuery 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.

GET /eaccounting/customers HTTP/1.1 
Host: api.bokamera.se 
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	Offset: 0,
	Total: 0,
	Results: 
	[
		{
			Id: String,
			CustomerNumber: String,
			CorporateIdentityNumber: String,
			ContactPersonEmail: String,
			ContactPersonMobile: String,
			ContactPersonName: String,
			ContactPersonPhone: String,
			CurrencyCode: String,
			GLN: String,
			InvoiceCity: String,
			InvoicePostalCode: String,
			EmailAddress: String,
			EmailAddressOrder: String,
			EmailAddressQuote: String,
			InvoiceAddress: 
			{
				CorporateIdentityNumber: String,
				InvoiceAddress1: String,
				InvoiceAddress2: String,
				InvoiceCity: String,
				InvoicePostalCode: String,
				InvoiceCountryCode: String
			},
			DeliveryCustomerName: String,
			DeliveryAddress1: String,
			DeliveryAddress2: String,
			DeliveryCity: String,
			DeliveryCountryCode: String,
			DeliveryPostalCode: String,
			DeliveryMethodId: String,
			DeliveryTermId: String,
			PayToAccountId: String,
			Name: String,
			Note: String,
			ReverseChargeOnConstructionServices: False,
			WebshopCustomerNumber: 0,
			MobilePhone: String,
			Telephone: String,
			TermsOfPaymentId: String,
			EAccountingTermsOfPayment: 
			{
				Id: String,
				Name: String,
				NameEnglish: String,
				NumberOfDays: 0,
				TermsOfPaymentTypeId: 0,
				TermsOfPaymentTypeText: String,
				AvailableForSales: False,
				AvailableForPurchase: False
			},
			VatNumber: String,
			WwwAddress: String,
			LastInvoiceDate: String,
			IsPrivatePerson: False,
			IsNorthernIreland: False,
			DiscountPercentage: 0,
			ChangedUtc: "0001-01-01T00:00:00",
			IsActive: False,
			ForceBookkeepVat: False,
			EdiGlnNumber: String,
			SalesDocumentLanguage: String,
			ElectronicAddress: String,
			ElectronicReference: String,
			EdiServiceDelivererId: String,
			AutoInvoiceActivationEmailSentDate: "0001-01-01T00:00:00",
			AutoInvoiceRegistrationRequestSentDate: "0001-01-01T00:00:00",
			EmailAddresses: 
			[
				String
			],
			CustomerLabels: 
			[
				{
					Id: String,
					Name: String,
					Description: String
				}
			],
			MessageThreads: 
			[
				String
			],
			Notes: 
			[
				String
			],
			IsFutureInvoiceDateAllowed: False,
			DeliveryBasedVat: False,
			SalesPriceListId: String,
			Iban: String,
			DirectDebitCustomerSettings: 
			{
				MandateId: String,
				MandateType: 0,
				SequenceType: 0
			},
			DiscountAgreementId: String,
			UnpaidInvoicesAmount: 0
		}
	],
	Meta: 
	{
		String: String
	},
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	}
}