Run my Accounts RESTful API
Customers
List of customers
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/customers
Parameters/filters: none
Entity: List of customer
Create or mute customer
POST https://service.runmyaccounts.com/api/latest/clients/{clientname}/customers
Parameters/filters: none
Entity: customer
Get customer by number
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/customers/{customernumber}
Parameters/filters: none
Entity: customer
Parts
List of parts
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/parts
Parameters/filters: none
Entity: part
Invoice and credit note
List of invoices
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/invoices
Parameters/filters:
Parameter | Description | Default |
---|---|---|
status | Invoice status. One of OPEN, PAID, OVERDUE | |
from | Filters invoices newer or on same date (yyyy-MM-dd) | Account close date |
to | Filters invoices older date (yyyy-MM-dd) | Today |
cutomer_number | Filters invoices by customer number |
Entity: invoice
Create invoice
POST https://service.runmyaccounts.com/api/{version}/clients/{clientname}/invoices
Entity: invoice
Get invoice
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/invoices/{invoice_number}
Entity: invoice
PDF or HTML of invoice
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/invoices/{invoice_number}/pdf
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/invoices/{invoice_number}/html
Parameters/filters:
Parameter | Description | Default |
---|---|---|
formname | May specify a specific template name (ex. invoice, remittance_voucher, packing_list, pick_list) | |
language_code | Specific language code. Otherwise default template language will be used |
Payments on invoices
List of payments
Use the payment list endpoint the following way:
- Get all payments not processed since a given date.
- Process the payments within your software
- Mark the payments as processed.
Step 1: Get all payments not processed since a given date.
GET https://service.runmyaccounts.com/api/{version}/clients/{clientname}/invoices/payment_list?processed=yyyy-MM-ddTHH:mm
Entity: invoice payment
Step 2: Process the payments within your software
Your piece of cake
Step 3: Mark the payments as processed.
POST https://service.runmyaccounts.com/api/{version}/clients/{mandantenname}/invoices/set_as_processed
Content-Type: application/x-www-form-urlencoded
Parameter | Description | Default |
---|---|---|
id | Id of payment that should be marked as processed |
You can mark multiple payments by simply adding multiple id parameters.
Payments of invoice
GET https://service.runmyaccounts.com/api/{version}/clients/{clientname}/invoices/{invoice_number}/payments
Entity: invoice payment
Add payment to invoice
POST https://service.runmyaccounts.com/api/{version}/clients/{clientname}/invoices/{invoice_number}/payments
Entity: invoice payment
Chart of accounts
List charts
GET https://service.runmyaccounts.com/api/{version}/clients/{clientname}/charts
Entity: chart
Parameter | Description | Default |
---|---|---|
type | Filters the list charts by type. |
Vendors
List of vendors
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/vendors
Parameters/filters: none
Entity: vendor
Create or mute vendor
POST https://service.runmyaccounts.com/api/latest/clients/{clientname}/vendors
Parameters/filters: none
Entity: vendor
Vendor invoices
List of vendor invoices
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/payables
Parameters/filters: none
Entity: vendor invoice
Create vendor invoice
POST https://service.runmyaccounts.com/api/{version}/clients/{clientname}/payables
Entity: vendor invoice
Get vendor invoice
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/payables/{invoice_number}
Entity: vendor invoice
PDF of vendor invoice
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/payables/{invoice_number}/pdf
Payments on vendor invoices
List payments of vendor invoice
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/payables/{invoice_number}/payments
Entity: vendor invoice payment
Add payment to vendor invoice
POST https://service.runmyaccounts.com/api/latest/clients/{clientname}/payables/{invoice_number}/payments
Entity: vendor invoice payment
General ledger
Balance of chart
GET https://service.runmyaccounts.com/api/{version}/clients/{clientname}/gl/saldo
Parameters/filters:
Parameter | Description | Mandatory | Example |
---|---|---|---|
accno | Filter by account number. You can use character x as wildcard. Ex. 15xx filters all account from 1500 to 1599 | Yes | 15xx |
from | Include transaction from date (yyyy-MM-dd) | No | 2019-01-01 |
to | Include transaction until date (yyyy-MM-dd), default is today | No | 2019-05-31 |
department | Count only transaction of specified department | No | |
bookkeeping_main_curr | Default value is true. Show balances in book keepings main currency | No | |
exclude_yearend_bookings | Ignore offsets at yearend | No |
Warning: Chart of the balance sheet do not need a from date. Charts of the income statement need from and to parameter.
Examples:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<table>
<row>
<column>2010</column>
<column>Verbindlichkeiten für AHV</column>
<column>41557.6500</column>
</row>
<row>
<column>2011</column>
<column>Verbindlichkeiten für BVG</column>
<column>-12827.8500</column>
</row>
<row>
<column>2012</column>
<column>Verbindlichkeiten für UVG</column>
<column>7723.7000</column>
</row>
<row>
<column>2013</column>
<column>Verbindlichkeiten für KTG</column>
<column>4776.0000</column>
</row>
<row>
<column>2014</column>
<column>Verbindlichkeiten für Quellensteuer</column>
<column>2731.3000</column>
</row>
</table>
{
"row": [
{
"column": [
"2010",
"Verbindlichkeiten für AHV",
"41557.6500"
]
},
{
"column": [
"2011",
"Verbindlichkeiten für BVG",
"-12827.8500"
]
},
{
"column": [
"2012",
"Verbindlichkeiten für UVG",
"7723.7000"
]
},
{
"column": [
"2013",
"Verbindlichkeiten für KTG",
"4776.0000"
]
},
{
"column": [
"2014",
"Verbindlichkeiten für Quellensteuer",
"2731.3000"
]
}
]
}
Create general ledger booking
POST https://service.runmyaccounts.com/api/latest/clients/{clientname}/gl
Entity: general ledger batch
Transactions of chart
GET https://service.runmyaccounts.com/api/{version}/clients/{clientname}/charts/{account-number}/transactions
Parameters/filters:
Parameter | Description | Mandatory | Example |
---|---|---|---|
accno | Filter by account number. You can use character x as wildcard. Ex. 15xx filters all account from 1500 to 1599 | Yes | 15xx |
from_date | Include transaction from date (yyyy-MM-dd) | 2019-01-01 | |
to_date | Include transaction until date (yyyy-MM-dd), default is today | 2019-05-31 | |
include_openings | Include opening balances to list | true | |
include_closings | Include closing balances to list | true |
Examples:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<transactions number_of_transaction="5">
<transaction>
<id>10204</id>
<chart id="0" accno="1000" link="" allow_gl="false" is_active="true">
<taxes/>
</chart>
<transdate>2015-10-22T00:00:00+02:00</transdate>
<reference>R-001</reference>
<description></description>
<amount>-50.0</amount>
<module>ar</module>
<source></source>
<entry_id>102</entry_id>
<memo></memo>
<notes></notes>
<intnotes></intnotes>
<accno>1000</accno>
</transaction>
<transaction>
<id>10246</id>
<chart id="0" accno="1020" link="" allow_gl="false" is_active="true">
<taxes/>
</chart>
<transdate>2017-03-02T00:00:00+01:00</transdate>
<reference>A1.3</reference>
<description></description>
<amount>-106.92</amount>
<module>ar</module>
<source></source>
<entry_id>145</entry_id>
<memo></memo>
<notes></notes>
<intnotes></intnotes>
<accno>1020</accno>
</transaction>
<transaction>
<id>10247</id>
<chart id="0" accno="1021" link="" allow_gl="false" is_active="true">
<taxes/>
</chart>
<transdate>2017-03-03T00:00:00+01:00</transdate>
<reference>A1.4</reference>
<description></description>
<amount>-3.58</amount>
<module>ar</module>
<source></source>
<entry_id>159</entry_id>
<notes></notes>
<intnotes></intnotes>
<accno>1021</accno>
</transaction>
<transaction>
<id>10247</id>
<chart id="0" accno="1021" link="" allow_gl="false" is_active="true">
<taxes/>
</chart>
<transdate>2017-03-03T00:00:00+01:00</transdate>
<reference>A1.4</reference>
<description></description>
<amount>-50.0</amount>
<module>ar</module>
<source></source>
<entry_id>157</entry_id>
<memo></memo>
<notes></notes>
<intnotes></intnotes>
<accno>1021</accno>
</transaction>
<transaction>
<id>10249</id>
<chart id="0" accno="1020" link="" allow_gl="false" is_active="true">
<taxes/>
</chart>
<transdate>2017-10-07T00:00:00+02:00</transdate>
<reference>K-001</reference>
<description></description>
<amount>108.0</amount>
<module>ap</module>
<source></source>
<entry_id>167</entry_id>
<memo></memo>
<notes></notes>
<intnotes></intnotes>
<accno>1020</accno>
</transaction>
</transactions>
{
"@number_of_transaction": "5",
"transaction": [
{
"id": "10204",
"chart": {
"@id": "0",
"@accno": "1000",
"@link": "",
"@allow_gl": "false",
"@is_active": "true",
"taxes": null
},
"transdate": "2015-10-22T00:00:00+02:00",
"reference": "R-001",
"description": "",
"amount": "-50.0",
"module": "ar",
"source": "",
"entry_id": "102",
"memo": "",
"notes": "",
"intnotes": "",
"accno": "1000"
},
{
"id": "10246",
"chart": {
"@id": "0",
"@accno": "1020",
"@link": "",
"@allow_gl": "false",
"@is_active": "true",
"taxes": null
},
"transdate": "2017-03-02T00:00:00+01:00",
"reference": "A1.3",
"description": "",
"amount": "-106.92",
"module": "ar",
"source": "",
"entry_id": "145",
"memo": "",
"notes": "",
"intnotes": "",
"accno": "1020"
},
{
"id": "10247",
"chart": {
"@id": "0",
"@accno": "1021",
"@link": "",
"@allow_gl": "false",
"@is_active": "true",
"taxes": null
},
"transdate": "2017-03-03T00:00:00+01:00",
"reference": "A1.4",
"description": "",
"amount": "-3.58",
"module": "ar",
"source": "",
"entry_id": "159",
"notes": "",
"intnotes": "",
"accno": "1021"
},
{
"id": "10247",
"chart": {
"@id": "0",
"@accno": "1021",
"@link": "",
"@allow_gl": "false",
"@is_active": "true",
"taxes": null
},
"transdate": "2017-03-03T00:00:00+01:00",
"reference": "A1.4",
"description": "",
"amount": "-50.0",
"module": "ar",
"source": "",
"entry_id": "157",
"memo": "",
"notes": "",
"intnotes": "",
"accno": "1021"
},
{
"id": "10249",
"chart": {
"@id": "0",
"@accno": "1020",
"@link": "",
"@allow_gl": "false",
"@is_active": "true",
"taxes": null
},
"transdate": "2017-10-07T00:00:00+02:00",
"reference": "K-001",
"description": "",
"amount": "108.0",
"module": "ap",
"source": "",
"entry_id": "167",
"memo": "",
"notes": "",
"intnotes": "",
"accno": "1020"
}
]
}
Get yearend bookings
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/gl/yearend
Examples:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<yearends>
<yearend>
<transdate>2015-06-30T00:00:00+02:00</transdate>
<reference>JAB2014/2015</reference>
</yearend>
<yearend>
<transdate>2016-12-31T00:00:00+01:00</transdate>
<reference>JAB.2016</reference>
</yearend>
</yearends>
{
"yearend": [
{
"transdate": "2015-06-30T00:00:00+02:00",
"reference": "JAB2014/2015"
},
{
"transdate": "2016-12-31T00:00:00+01:00",
"reference": "JAB.2016"
}
]
}
Document processing
Upload document for processing
POST https://service.runmyaccounts.com/api/latest/clients/{clientname}/belege
Upload documents for processing. Accepted content types are PDF and images. Upload accepts mime multipart data (Content-Type: multipart/form-data). File content musst be in parameter Filedata. And optional additonal parameter comment can be used to add instructions for processing.
Example:
POST /api/latest/clients/apitest/belege?api_key=GEHEIM HTTP/1.1
Host: service.runmyaccounts.com
Connection: keep-alive
Content-Length: 27974
Cache-Control: max-age=0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.114 Safari/537.36
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryyik8WY7O6UcFUs4z
Accept-Encoding: gzip,deflate,sdch
Accept-Language: de-DE,de;q=0.8,en-US;q=0.6,en;q=0.4,fr;q=0.2,sv;q=0.2
------WebKitFormBoundaryyik8WY7O6UcFUs4z
Content-Disposition: form-data; name="comment"
Kontierung 4200
------WebKitFormBoundaryyik8WY7O6UcFUs4z
Content-Disposition: form-data; name="Filedata"; filename="test_dokument.pdf"
Content-Type: application/pdf
%PDF-1.4
...
%%EOF
------WebKitFormBoundaryAR3J3St4XvA6RGZa--
Response:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<beleg_upload>
<id>112305</id>
<comment></comment>
<checksum>4084618730</checksum>
<date_received>2014-06-18T08:06:52.810+02:00</date_received>
<file_name>1400851148_invoice_R100007.pdf</file_name>
</beleg_upload>
Cost and profit centers
List cost and profit centers
GET https://service.runmyaccounts.com/api/latest/clients/{clientname}/departments
Entity: department