Please check the API reference documentation for PartnerAPI here https://e-racuni.com/obracuni/ApiDocumentation .
PartnerAPI exposes the functionality of the partner list GUI to developer. Most of partner editing features are available via API methods in this category. The API user account needs to own the same privileges as the regular GUI to get access to features via the API.
Below you will find examples on how to use the partner API. Some examples are written using JSON request notation, some examples are written in XML and some examples use curl command line tool to illustrate multiple way on how you can use the API.
Please use the API developer panel to generate API request source in a language of your preference. JSON, XML, Linux command line and PHP request source can be automatically generated by the API developer panel tool. API developer panel is available at: |
Here is a simple example on how to create a B2B customerusing JSON API request.
POST https://e-racuni.com/WebServicesSI/API
Content-Type: application/json
{
"username": "MICKA",
"md5pass": "1234567890a1c85dc0c1234218acb900",
"token": "1234562ADC3A123001234D00B0C71E0EC",
"method": "SalesInvoiceCreate",
"parameters": {
"partner": {
"companyType": "Ltd",
"companyName": "Pravna oseba",
"eMail": "pravna.oseba@oseba.si",
"Addresses": [
{
"type": "Primary",
"country": "SI",
"postalCode": "2000",
"street": "Mariborska 1"
}
],
"BuyerData": {
"buyerCode": "testBuyer0202"
}
}
}
}
Here is a simple example on how to create a B2C customerusing JSON API request.
POST https://e-racuni.com/WebServicesSI/API
Content-Type: application/json
{
"username": "MICKA",
"md5pass": "1234567890a1c85dc0c1234218acb900",
"token": "1234562ADC3A123001234D00B0C71E0EC",
"method": "SalesInvoiceCreate",
"parameters": {
"partner": {
"gender": "female",
"lastName": "Fizična",
"firstName": "Oseba",
"eMail": "fizicna.oseba@oseba.si",
"Addresses": [
{
"type": "Primary",
"country": "SI",
"postalCode": "2000",
"street": "Mariborska 1"
}
],
"BuyerData": {
"buyerCode": "testBuyer0202"
}
}
}
}
PartnerGetByID | Get partner by partner ID. |
PartnerGetByCode | Get partner by partner's code. |
PartnerGetByDocumentID | Get partner by partner's documentID (internal identificator from program). |
PartnerCreate | Create new partner. |
PartnerUpdate | Update existing partner. |
PartnerImport | Import partner by creating new and/or updating existing ones. |
PartnerDelete | Delete partner. |
PartnerList | Get list of partners for specified criteria. |
PartnerListBuyers | Get list of buyers for specified criteria. |
PartnerListSuppliers | Get list of suppliers for specified criteria. |
PartnerListEmployees | Get list of employees for specified criteria. |
PartnerBuyerCreditLimitGet | Get partner buyer credit limit with unpaid amount by invoices and posted debt. |
PartnerAttachmentAdd | Add attachment to partner. |
PartnerAttachmentSetDefault | Add attachment to partner and set is as default. |
PartnerAttachmentGet | Get default attachment of partner. |
PartnerAttachmentList | Get all attachments of partner. |
PartnerAvatarAdd | Add partner's avatar. |
PartnerAvatarGet | Get partner's avatar. |
PartnerAvatarRemove | Remove partner's avatar. |
Get partner by partner ID.
Parameters
ID | Partner ID (partner taxNumber accepted too). Partner ID is external number (matična številka) in case of legal person and in case of natural person it is registration number (EMŠO) |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerGetByID">
<parameter name="ID" value="73691234" />
</method>
</request>
HTTP/1.1 200 OK
Server: e-racuni.com web server
Date: Tue, 1 March 2010 11:00:05 GMT
Content-Type: text/xml
Content-Length: 328
<?xml version="1.0" encoding="utf-8"?>
<response status="ok">
<Partner>
<ID>02169711</ID> <!-- Partner ID.
<partnerCode>111</partnerCode> <!-- Partner code.
<taxNumber>02169711</taxNumber> <!-- Tax number
<vatID>1587277000</vatID> <!-- VAT number
<companyName>Micka d.o.o </companyName> <!-- Company name
<companyType>Organization</ companyType> <!-- Type of company. (Contractor, Ltd, Plc, Co, Organization, Subsidiary, Association, Direction, Unit, Division, Edu, Gov, Charity, Cooperative)
<vatRegistration>Unknown</vatRegistration> <!-- VAT reg type (Unknown, None, Registered)
<dateOfRegistration></ dateOfRegistration> <!-- Company establishment date
<branchClassification></branchClassification> <!-- Branch classification
<firstName>Micka</firstName> <!-- For legal person is first name of contact person
<lastName>Kovac</lastName> <!-- For legal person is last name of contact person
<gender>female</ gender> <!-- Type of person sex. (male, female, unknown)
<dateOfBirth></dateOfBirth> <!-- For natural person only birth date
<maritalStatus></maritalStatus> <!-- For natural person (single, married, widowed, concubinance)
<mobilePhone>064/123456</mobilePhone>
<fax>05/625 94 40</fax>
<eMail>micka@kovac.com,zlatko@kovac.com</eMail> <!-- comma delimited list of emails
<remarks>test partner for testing web services</remarks><!-- remarks for partner
<homepage>www.testWS.com</homepage> <!-- homapege of partner
<Addresses>
<Address>
<type>Primary</type> <!--Primary address (possible address types are: Invoicing, Primary, Delivery)
<street>Iztokova 22</street>
<city>Maribor</city>
<postalCode>2000</postalCode>
<country>SI</country>
<telephone>05/625 94 39</telephone>
<fax>05/625 94 39</fax>
<eMail>test@gmail.com<eMail>
</Address>
<Address >
<type>Invoicing</type> <!--Invoicing address, can include tags "firstAddressLine" and "additionalLine" for additional data for invoicing
<additionalLine>Test Company</additionalLine>
<firstAddressLine>Iztok Kladnik</firstAddressLine>
<street>Iztokova 22</street>
<city>Maribor</city>
<postalCode>2000</postalCode>
<country>SI</country>
<telephone>05/625 94 39</telephone>
</Address>
<Address >
<type>Delivery</type> <!--Delivery address, can include tag "additionalLine" for name of recipient
<addressCode>PE0001</addressCode>
<additionalLine>Test Company</additionalLine>
<street>Iztokova 22</street>
<city>Maribor</city>
<postalCode>2000</postalCode>
<country>SI</country>
<telephone>05/625 94 39</telephone>
</Address>
</Addresses>
<EmployeeData>
<status>active</status> <!-- Employee status (active, inactive)
<distanceFromHomeKm>12</distanceFromHomeKm> <!-- Distance from home in kilometers
<transportRelationToWork>mb-sb</transportRelationToWork> <!-- Route to the place of work
<amountOfBusTicket>20</amountOfBusTicket> <!-- Buss transportation ticket price
<ownVehicleModel>audi</ownVehicleModel> <!-- Own vehicle model
<ownVehicleRegNr>mb es-123</ownVehicleRegNr> <!-- Registration number of the own vehicle
<Employments>
<Employment>
<jobTitle></jobTitle> <!-- Employee job title
<employmentType></employmentType> <!-- Type of employment. (groupContract, individualContract, craftsman, entrepreneurshipHolder, companyOwner, lumpWorker)
<payClass></payClass> <!-- Payment class
<isHandicappedPerson>handicappedNot</isHandicappedPerson> <!-- Is handicapped person (handicapedNot, handicappedToQuota, handicappedOverQuota, handicappedHalfOverQuotaAndHalfWork)
<beginDate>2000-02-01</beginDate> <!-- Start date of employment contract
<employmentContractEndDate></employmentContractEndDate> <!-- Optional - End date of employment contract
<primaryEmployment>true</primaryEmployment> <!-- Is primary employment (true, false)
<previousWorkExperienceYears></previousWorkExperienceYears> <!-- Years of previous work experience
<previousWorkExperienceMonths></previousWorkExperienceMonths> <!-- Months of previous work experience
<previousWorkExperienceDays></previousWorkExperienceDays> <!-- Days of previous work experience
<workingAgeAllowancePercentage></workingAgeAllowancePercentage> <!-- percentage of working age allowance
<grossSalary></grossSalary> <!-- Gross salary
<grossSalaryCurrency></grossSalaryCurrency> <!-- Currency
<grossSalaryCalculationFactor></grossSalaryCalculationFactor> <!-- Numeric factor for gross salary calculation
<workingHoursPerWeek></workingHoursPerWeek> <!-- Number of working hours per week
<taxRelief></taxRelief> <!-- Tax relief
<specialTaxRelief></specialTaxRelief> <!-- Special tax relief
<hasLowSalaryTaxRelief>false</hasLowSalaryTaxRelief> <!-- Has Tax relief for low salary (true,false)
<sickLeaveOver30hourPrice></sickLeaveOver30hourPrice> <!-- Price for hour for sick leave over 30 days
<sickLeaveOver30hourPriceCurrency>EUR</sickLeaveOver30hourPriceCurrency> <!-- Price currency for sick leave over 30 days
<addPensionInsuranceAmount></> <!-- Additional pension insurance amount (employee cost)
<addPensionInsurancePercent></> <!-- Additional pension insurance percent (employee cost)
<addPensionInsuranceAccountNumber></> <!-- Additional pension insurance account number (employee cost)
<addPensionInsuranceAccountReference></> <!-- Additional pension insurance account ref. (employee cost)
<addPensionInsuranceEmployerCostAmount></> <!-- Additional pension insurance amount (employer cost)
<addPensionInsuranceEmployerCostPercent></> <!-- Additional pension insurance percentage (employer cost)
<addPensionInsuranceEmployerCostAccountNumber></> <!-- Additional pension insurance account number (employer cost)
<addPensionInsuranceEmployerCostAccountReference></> <!-- Additional pension insurance account ref. (employer cost)
</Employment>
</Employments>
</EmployeeData>
<BuyerData>
<buyerCode>00000105</buyerCode>
<buyerGroupCode>01</buyerGroupCode>
<costPosition>1</costPosition>
<discountPercentage>5.000</discountPercentage>
<numberOfDaysForPayment>15</numberOfDaysForPayment>
<numberOfDaysForPaymentBaseDate>fromDocumentDate</numberOfDaysForPaymentBaseDate> <!-- allowed values: fromDocumentDate, fromServiceOrDeliveryDate
<serialNumberForCollectionCenter></serialNumberForCollectionCenter>
<status>trustworthyBuyer</status> <!-- allowed values: defaultBuyer, buyerOnBlackList, trustworthyBuyer, buyerDoesNotExistAnymore.
<buyerCreditLimit>900.00</buyerCreditLimit> <!-- buyer credit limit
<buyerCreditLimitCurrency>EUR</buyerCreditLimitCurrency>
<invoicingCurrency>EUR</invoicingCurrency> <!-- invoicing currency, this property is usssed for creating invoices for this buyer
<invoicingLanguage>EUR</invoicingLanguage> <!-- allowed values: 'Slovene' 'English' 'German' 'Croatian' 'Italian' 'Hungarian' 'Czech' 'Slovak' 'Serbian' 'Polish' 'Bulgarian'
<invoicingTemplateName>templateTestBuyer</invoicingTemplateName> <!-- name of template used for printing invoices for this buyer
</BuyerData>
<SupplierData>
<acceptsOrdersReceivedAtLeastDaysInAdvance>30</acceptsOrdersReceivedAtLeastDaysInAdvance>
<costPosition>1</costPosition>
<defaultExpensesAccount>120</defaultExpensesAccount>
<numberOfDaysForPayment>14</numberOfDaysForPayment>
<numberOfDaysForPaymentBaseDate>fromDocumentDate</numberOfDaysForPaymentBaseDate> <!-- allowed values: fromDocumentDate, fromServiceOrDeliveryDate, fromDocumentReceivedDate
<status>defaultSupplier</status> <!-- defaultSupplier, supplierOnBlackList, trustworthySupplier, supplierDoesNotExistAnymore
<supplierCode>1122</supplierCode>
</SupplierData>
<BankAccounts>
<BankAccount>
<bank>SKB</bank>
<accountNumber>02343-0254045370</accountNumber>
<accountReference>99</accountReference>
<IBAN></IBAN>
<SWIFT>253</SWIFT>
<description></description>
</BankAccount>
<BankAccount>
<bank>Nova KBM d.d.</bank>
<accountNumber>04430-0000256970</accountNumber>
<accountReference>99</accountReference>
<IBAN></IBAN>
<SWIFT></SWIFT>
<currency></currency>
<status>Active</status>
<description></description>
</BankAccount>
</BankAccounts>
<ContactPersons>
<ContactPerson>
<contactPersonFullName>Contact person 1</contactPersonFullName>
<contactPersonFunction>Programmer</contactPersonFunction>
<eMail>test@gmail.com</eMail>
<mobilePhoneNumber>030 999 666</mobilePhoneNumber>
</ContactPerson>
<ContactPerson>
<contactPersonFullName>Contact person 1</contactPersonFullName>
<contactPersonFunction>Support</contactPersonFunction>
<eMail>test@gmail.com</eMail>
<phone>03 746 4362</phone>
<remarks>Leed programmer</remarks>
</ContactPerson>
</ContactPersons>
</Partner>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description="Partner not found, "><error/>
</response>
Get partner by partner code.
Parameters
partnerCode | Partner code. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerGetByCode">
<parameter name="partnerCode" value="1234" />
</method>
</request>
Response
Response structure is identical to the structure of response in PartnerGetByID
Get partner by partner documentID.
Parameters
documentID | Partner documentID (internal id from program). |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerGetByDocumentID">
<parameter name="documentID" value="34:1234" />
</method>
</request>
Response
Response structure is identical to the structure of response in PartnerGetByID
Create new partner. (for more detailed partner's data structure look in API for PartnerGetByID)
Parameters
partner | Partner's data in xml substructure. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerCreate">
<parameter name="partner">
<companyType>Organization</companyType> <!-- Mandatory when creating info about company
<companyName>Micka d.o.o </companyName> <!-- Mandatory when creating info about company
<taxNumber>02169711</taxNumber> <!-- optional data
<mobilePhone>064/123456</mobilePhone>
<fax>05/625 94 40</fax>
<eMail>micka@kovac.com,zlatko@kovac.com</eMail>
...
<!-- optional data in sub elements (see properties in PartnerGetByID)
<Addresses>
<Address>
<type></type> <!--(possible address types are: Invoicing, Primary, Delivery)
...
</Address>
</Addresses>
<BuyerData></BuyerData>
<SupplierData></SupplierData>
<EmployeeData></EmployeeData>
<BankAccounts> <!-- Bank accounts where structure is the same as displayed in abowe example og Get by ID API call
<BankAccount></BankAccount>
</BankAccounts>
<ContactPersons> <!-- Contact persons where structure is the same as displayed in abowe example og Get by ID API call
<ContactPerson></ContactPerson>
</ContactPersons>
</parameter>
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- missing mandatory attributes, invalid values, no privileges,
</response>
Update existing partner.
Parameters
partner | Partner's data in xml substructure. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerUpdate">
<parameter name="partner">
<partnerCode>7369</partnerCode>
<!--other params as in PartnerCreate
</parameter>
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- missing mandatory attributes, invalid values, no privileges,
</response>
Delete partner.
Parameters
ID | Partner's ID. |
taxNumber | Partner's tax number. |
partnerCode | Partner's code. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerDelete">
<parameter name="ID" value="7369" />
</method>
</request>
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerDelete">
<parameter name="taxNumber" value="SI12345678" />
</method>
</request>
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerDelete">
<parameter name="partnerCode" value="PA7369" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/>
</response>
Import partner by creating new and/or updating existing ones. Parameter importType can be used to specify type of import. If parameter is not specified, createOrUpdate is used as default. For updating partner with this api call, partner's data must contain code as unique identifier.
Parameters
importType | Flag for the type of import
|
partner | Partner's data in xml substructure. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerImport">
<parameter name="importType" value="createOrUpdate" />
<parameter name="partner"> <!-- parameter here is the same as for PartnerUpdate or PartnerCreate depending on importType
</parameter>
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<ID></ID>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- missing mandatory attributes, invalid values, no privileges,
</response>
Get list of partners for specified criteria.
Parameters
partnerType | Type of partners to be answered. If this parameter is missing, answer all types of partners. Possible types are:
|
searchKey | Search key. The value from this field is used for searching for: ( company name for partners as legal person, given name and name for partners as physical person) |
partnerCode | Partner's code |
taxNumber | Tax number |
street | Street |
postalCodeOrCity | Postal code or City |
mobileOrPhoneNumber | Mobile or phone number |
companyType | Company type where parameter value is the same as possible values of tag companyType described abowe |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerList">
<parameter name="searchKey" type="String" value="MICKA D O O" />
<parameter name="postalCodeOrCity" type="String" value="Maribor" />
<parameter name="street" type="String" value="Iztokova" />
<parameter name="partnerCode" type="String" value="111" />
<parameter name="partnerType" value="buyer"/>
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<Partner>
<!-- structure of each partner is the same as in PartnerGetByID
</Partner>
<Partner>
</Partner>
...
</response>
Get list of buyers for specified criteria. Response structure is identical to API "PartnerList"
Parameters
searchKey | Search key. The value from this field is used for searching for: (company name for partners as legal person, given name and name for partners as physical person) |
partnerCode | Partner's code |
buyerCode | Buyer's code |
taxNumber | Tax number |
street | Street |
postalCodeOrCity | Postal code or City |
mobileOrPhoneNumber | Mobile or phone number |
buyerCountry | Buyer country iso code |
status | Status of the buyers to be answered. It is optional and possible types are:
|
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerListBuyers">
<parameter name="buyerCode" type="String" value="111" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<Partner>
<!-- structure of each partner is the same as in PartnerGetByID
</Partner>
<Partner>
</Partner>
...
</response>
Get list of suppliers for specified criteria. Response structure is identical to API "PartnerList"
Parameters
searchKey | Search key. The value from this field is used for searching for: (company name for partners as legal person, given name and name for partners as physical person) |
partnerCode | Partner's code |
supplierCode | Supplier's code |
taxNumber | Tax number |
street | Street |
postalCodeOrCity | Postal code or City |
mobileOrPhoneNumber | Mobile or phone number |
status | Status of the suppliers to be answered. It is optional and possible types are:
|
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerListSupplier">
<parameter name="supplierCode" type="String" value="111" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<Partner>
<!-- structure of each partner is the same as in PartnerGetByID
</Partner>
<Partner>
</Partner>
...
</response>
Get list of employees for specified criteria. Response structure is identical to API "PartnerList"
Parameters
searchKey | Search key. The value from this field is used for searching for: (company name for partners as legal person, given name and name for partners as physical person) |
partnerCode | Partner's code |
taxNumber | Tax number |
status | Status of the employees. Possible types are:
|
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerListEmployees">
<parameter name="partnerCode" type="String" value="111" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<Partner>
<!-- structure of each partner is the same as in PartnerGetByID
</Partner>
<Partner>
</Partner>
...
</response>
Get partner buyer credit limit with unpaid amount by invoices and posted debt.
Parameters
ID | Partner's ID. |
taxNumber | Partner's tax number. |
partnerCode | Partner's code. |
creditLimitDate | Date on which credit limit is calculated, if parameter is empty or not present, todays date is taken. |
currency | Curreny of results, if not specified default currency is taken |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerBuyerCreditLimitGet">
<parameter name="partnerCode" value="100011" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<buyerCreditLimit>20,00</buyerCreditLimit>
<unpaidInvoicesAmount>16.278,76</unpaidInvoicesAmount>
<postedDebt>5.167,96</postedDebt>
<currency>EUR</currency>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description="Partner not found, Partner xyz is not defined as buyer!, Buyer kyz does not have defined credit limit or it is below minimum required amount! "><error/>
</response>
Add image/attachment to partner.
Parameters
partnerCode | Partner code. |
documentID | Partner's document ID. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerAttachmentAdd">
<parameter name="partnerCode" type="String" value="00001" />
<parameter name="attachment">
<contents encoding="BASE64">BASE64...</contents>
<fileName>att.jpg</fileName>
</parameter>
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<message>Successfully added attachment att.jpg to partner 00001.</message>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "partnerCode" or "documentID" is required, Can not find partner for code: 00001, Parameter <attachment> is missing, Parameter <attachment> cannot parse contents
</response>
Add attachment to partner and set it as default.
Parameters
partnerCode | Partner code. |
documentID | Partner's document ID. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerAttachmentSetDefault">
<parameter name="partnerCode" type="String" value="2020-00001" />
<parameter name="attachment">
<contents encoding="BASE64">BASE64...</contents>
<fileName>att.jpg</fileName>
</parameter>
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<message>Successfully added attachment att.jpg to partner 2020-00001.</message>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "partnerCode" or "documentID" is required., Can not find partner for code: 00001, Parameter <attachment> is missing, Parameter <attachment> cannot parse contents
</response>
Get default attachment of partner.
Parameters
partnerCode | Partner code. |
documentID | Partner's document ID. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerAttachmentGet">
<parameter name="partnerCode" type="String" value="00001" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<Partner>
<Attachments>
<Attachment>
<fileName>att.jpg</fileName>
<contents encoding="BASE64">BASE64</contents>
</Attachment>
</Attachments>
</Partner>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "partnerCode" or "documentID" is required., Can not find partner for code: 00001, partner does not have attachemnts.
</response>
Get all images/attachments of article.
Parameters
partnerCode | Partner code. |
documentID | Partner's document ID. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerAttachmentList">
<parameter name="partnerCode" type="String" value="2020-00001" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<Partner>
<Attachments>
<Attachment>
<fileName>att1.jpg</fileName>
<contents encoding="BASE64">1BASE64</contents>
</Attachment>
<Attachment>
<fileName>att2.jpg</fileName>
<contents encoding="BASE64">2BASE64</contents>
</Attachment>
<Attachment>
<fileName>att3.jpg</fileName>
<contents encoding="BASE64">3BASE64</contents>
</Attachment>
</Attachments>
</Partner>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "partnerCode" or "documentID" is required., Can not find partner for code: 00001, partner does not have attachemnts.
</response>
Add avatar to partner. If partner already has avatar, old one is removed and new one set.
Parameters
partnerCode | Partner code. |
documentID | Partner's document ID. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerAvatarAdd">
<parameter name="partnerCode" type="String" value="00001" />
<parameter name="attachment">
<contents encoding="BASE64">BASE64...</contents>
<fileName>att.jpg</fileName>
</parameter>
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<message>Successfully added avatar att.jpg to partner 00001.</message>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "partnerCode" or "documentID" is required, Can not find partner for code: 00001, Parameter <attachment> is missing, Parameter <attachment> cannot parse contents
</response>
Get partner's avatar.
Parameters
partnerCode | Partner code. |
documentID | Partner's document ID. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerAvatarGet">
<parameter name="partnerCode" type="String" value="00001" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<Partner>
<Attachments>
<Attachment>
<fileName>att.jpg</fileName>
<contents encoding="BASE64">BASE64</contents>
</Attachment>
</Attachments>
</Partner>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "partnerCode" or "documentID" is required., Can not find partner for code: 00001, partner does not have avatar.
</response>
Remove partner's avatar.
Parameters
partnerCode | Partner code. |
documentID | Partner's document ID. |
Example request and response
POST /WebServicesSI/API HTTP/1.1
Host: eurofaktura.com
User-Agent: Mozilla/4.0
Content-Length: 410
Content-Type: application/octet-stream
<?xml version="1.0" encoding="utf-8"?>
<request>
<login username="micka" md5pass="ddb43e9f119c6805f4770ecc4f6466ba" token="E7DF3E6E94FB4579BBA8F54979010B5C" />
<method name="PartnerAvatarRemove">
<parameter name="partnerCode" type="String" value="00001" />
</method>
</request>
Response
<?xml version="1.0" encoding="utf-8"?>
<response status="ok" >
<message>Successfully removed avatar att.jpg to partner 00001.</message>
</response>
Response on error
<?xml version="1.0" encoding="utf-8"?>
<response status="error" >
<error description=""><error/> <!-- Possible errors: Access denied. User account does not have sufficient privileges for the given request, Parameter named "partnerCode" or "documentID" is required., Can not find partner for code: 00001, partner does not have avatar.
</response>