Requires any of the roles: | bookingsupplier-administrator-write, superadmin |
PUT | /eaccounting/customers | Update E-Accounting Customer |
---|
export class InvoiceAddress
{
public CorporateIdentityNumber: string;
public InvoiceAddress1: string;
public InvoiceAddress2: string;
public InvoiceCity: string;
public InvoicePostalCode: string;
public InvoiceCountryCode: string;
public constructor(init?: Partial<InvoiceAddress>) { (Object as any).assign(this, init); }
}
export class EAccountingTermsOfPayment
{
public Id: string;
public Name: string;
public NameEnglish: string;
public NumberOfDays: number;
public TermsOfPaymentTypeId: number;
public TermsOfPaymentTypeText: string;
public AvailableForSales: boolean;
public AvailableForPurchase: boolean;
public constructor(init?: Partial<EAccountingTermsOfPayment>) { (Object as any).assign(this, init); }
}
export class CustomerLabel
{
public Id: string;
public Name: string;
public Description: string;
public constructor(init?: Partial<CustomerLabel>) { (Object as any).assign(this, init); }
}
export class DirectDebitCustomerSettings
{
public MandateId: string;
public MandateType: number;
public SequenceType: number;
public SigningDate: string;
public EndDate: string;
public LatestDirectDebit: string;
public constructor(init?: Partial<DirectDebitCustomerSettings>) { (Object as any).assign(this, init); }
}
export class CreateEAccountingCustomer extends InvoiceAddress
{
public CustomerNumber: string;
public ContactPersonEmail: string;
public ContactPersonMobile: string;
public ContactPersonName: string;
public ContactPersonPhone: string;
public CurrencyCode: string;
public GLN: string;
public EmailAddress: string;
public EmailAddressOrder: string;
public EmailAddressQuote: string;
public DeliveryCustomerName: string;
public DeliveryAddress1: string;
public DeliveryAddress2: string;
public DeliveryCity: string;
public DeliveryCountryCode: string;
public DeliveryPostalCode: string;
public DeliveryMethodId: string;
public DeliveryTermId: string;
public PayToAccountId: string;
public Name: string;
public Note: string;
public ReverseChargeOnConstructionServices: boolean;
public WebshopCustomerNumber?: number;
public MobilePhone: string;
public Telephone: string;
public TermsOfPaymentId: string;
public EAccountingTermsOfPayment: EAccountingTermsOfPayment;
public VatNumber: string;
public WwwAddress: string;
public LastInvoiceDate: string;
public IsPrivatePerson: boolean;
public IsNorthernIreland: boolean;
public DiscountPercentage: number;
public ChangedUtc?: string;
public IsActive: boolean;
public ForceBookkeepVat: boolean;
public EdiGlnNumber: string;
public SalesDocumentLanguage: string;
public ElectronicAddress: string;
public ElectronicReference: string;
public EdiServiceDelivererId: string;
public AutoInvoiceActivationEmailSentDate?: string;
public AutoInvoiceRegistrationRequestSentDate?: string;
public EmailAddresses: string[];
public CustomerLabels: CustomerLabel[];
public MessageThreads: string[];
public Notes: string[];
public IsFutureInvoiceDateAllowed: boolean;
public DeliveryBasedVat: boolean;
public SalesPriceListId: string;
public Iban: string;
public DirectDebitCustomerSettings: DirectDebitCustomerSettings;
public DiscountAgreementId: string;
public UnpaidInvoicesAmount: number;
public constructor(init?: Partial<CreateEAccountingCustomer>) { super(init); (Object as any).assign(this, init); }
}
export class EAccountingCustomerResponse extends CreateEAccountingCustomer
{
public Id: string;
public constructor(init?: Partial<EAccountingCustomerResponse>) { super(init); (Object as any).assign(this, init); }
}
// @ApiResponse(Description="You were unauthorized to call this service", StatusCode=401)
// @ValidateRequest(Validator="IsAuthenticated")
export class UpdateEaccountingCustomer implements ICompany
{
/** @description Customer Id in e-accounting. */
// @ApiMember(Description="Customer Id in e-accounting.", IsRequired=true)
public Id: string;
/** @description */
// @ApiMember(Description="")
public InvoiceCity: string;
/** @description Max length: 10 characters */
// @ApiMember(Description="Max length: 10 characters")
public InvoicePostalCode: string;
/** @description Max length: 50 characters */
// @ApiMember(Description="Max length: 50 characters")
public Name: string;
/** @description */
// @ApiMember(Description="")
public TermsOfPaymentId: string;
/** @description */
// @ApiMember(Description="")
public IsPrivatePerson: boolean;
/** @description */
// @ApiMember(Description="")
public IsActive: boolean;
/** @description */
// @ApiMember(Description="")
public Telephone: string;
/** @description */
// @ApiMember(Description="")
public EmailAddress: string;
/** @description */
// @ApiMember(Description="")
public MobilePhone: string;
/** @description The company id, if empty will use the company id for the user you are logged in with. */
// @ApiMember(Description="The company id, if empty will use the company id for the user you are logged in with.")
public CompanyId?: string;
public constructor(init?: Partial<UpdateEaccountingCustomer>) { (Object as any).assign(this, init); }
}
TypeScript UpdateEaccountingCustomer DTOs
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.
PUT /eaccounting/customers HTTP/1.1
Host: api.bokamera.se
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<EAccountingDtos.UpdateEaccountingCustomer xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos">
<CompanyId>00000000-0000-0000-0000-000000000000</CompanyId>
<EmailAddress>String</EmailAddress>
<Id>String</Id>
<InvoiceCity>String</InvoiceCity>
<InvoicePostalCode>String</InvoicePostalCode>
<IsActive>false</IsActive>
<IsPrivatePerson>false</IsPrivatePerson>
<MobilePhone>String</MobilePhone>
<Name>String</Name>
<Telephone>String</Telephone>
<TermsOfPaymentId>String</TermsOfPaymentId>
</EAccountingDtos.UpdateEaccountingCustomer>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <EAccountingClientDtos.EAccountingCustomerResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos"> <CorporateIdentityNumber>String</CorporateIdentityNumber> <InvoiceAddress1>String</InvoiceAddress1> <InvoiceAddress2>String</InvoiceAddress2> <InvoiceCity>String</InvoiceCity> <InvoiceCountryCode>String</InvoiceCountryCode> <InvoicePostalCode>String</InvoicePostalCode> <AutoInvoiceActivationEmailSentDate>0001-01-01T00:00:00</AutoInvoiceActivationEmailSentDate> <AutoInvoiceRegistrationRequestSentDate>0001-01-01T00:00:00</AutoInvoiceRegistrationRequestSentDate> <ChangedUtc>0001-01-01T00:00:00</ChangedUtc> <ContactPersonEmail>String</ContactPersonEmail> <ContactPersonMobile>String</ContactPersonMobile> <ContactPersonName>String</ContactPersonName> <ContactPersonPhone>String</ContactPersonPhone> <CurrencyCode>String</CurrencyCode> <CustomerLabels> <EAccountingClientDtos.CustomerLabel> <Description>String</Description> <Id>String</Id> <Name>String</Name> </EAccountingClientDtos.CustomerLabel> </CustomerLabels> <CustomerNumber>String</CustomerNumber> <DeliveryAddress1>String</DeliveryAddress1> <DeliveryAddress2>String</DeliveryAddress2> <DeliveryBasedVat>false</DeliveryBasedVat> <DeliveryCity>String</DeliveryCity> <DeliveryCountryCode>String</DeliveryCountryCode> <DeliveryCustomerName>String</DeliveryCustomerName> <DeliveryMethodId>String</DeliveryMethodId> <DeliveryPostalCode>String</DeliveryPostalCode> <DeliveryTermId>String</DeliveryTermId> <DirectDebitCustomerSettings> <EndDate>0001-01-01T00:00:00</EndDate> <LatestDirectDebit>0001-01-01T00:00:00</LatestDirectDebit> <MandateId>String</MandateId> <MandateType>0</MandateType> <SequenceType>0</SequenceType> <SigningDate>0001-01-01T00:00:00</SigningDate> </DirectDebitCustomerSettings> <DiscountAgreementId>String</DiscountAgreementId> <DiscountPercentage>0</DiscountPercentage> <EAccountingTermsOfPayment> <AvailableForPurchase>false</AvailableForPurchase> <AvailableForSales>false</AvailableForSales> <Id>String</Id> <Name>String</Name> <NameEnglish>String</NameEnglish> <NumberOfDays>0</NumberOfDays> <TermsOfPaymentTypeId>0</TermsOfPaymentTypeId> <TermsOfPaymentTypeText>String</TermsOfPaymentTypeText> </EAccountingTermsOfPayment> <EdiGlnNumber>String</EdiGlnNumber> <EdiServiceDelivererId>String</EdiServiceDelivererId> <ElectronicAddress>String</ElectronicAddress> <ElectronicReference>String</ElectronicReference> <EmailAddress>String</EmailAddress> <EmailAddressOrder>String</EmailAddressOrder> <EmailAddressQuote>String</EmailAddressQuote> <EmailAddresses xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:string>String</d2p1:string> </EmailAddresses> <ForceBookkeepVat>false</ForceBookkeepVat> <GLN>String</GLN> <Iban>String</Iban> <IsActive>false</IsActive> <IsFutureInvoiceDateAllowed>false</IsFutureInvoiceDateAllowed> <IsNorthernIreland>false</IsNorthernIreland> <IsPrivatePerson>false</IsPrivatePerson> <LastInvoiceDate>String</LastInvoiceDate> <MessageThreads xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:string>String</d2p1:string> </MessageThreads> <MobilePhone>String</MobilePhone> <Name>String</Name> <Note>String</Note> <Notes xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:string>String</d2p1:string> </Notes> <PayToAccountId>String</PayToAccountId> <ReverseChargeOnConstructionServices>false</ReverseChargeOnConstructionServices> <SalesDocumentLanguage>String</SalesDocumentLanguage> <SalesPriceListId>String</SalesPriceListId> <Telephone>String</Telephone> <TermsOfPaymentId>String</TermsOfPaymentId> <UnpaidInvoicesAmount>0</UnpaidInvoicesAmount> <VatNumber>String</VatNumber> <WebshopCustomerNumber>0</WebshopCustomerNumber> <WwwAddress>String</WwwAddress> <Id>String</Id> </EAccountingClientDtos.EAccountingCustomerResponse>