Return values for API version ALPHA

A word with a @-sign in front is a changing variable in the return values
Return values inside square brackets [ ] are arrays

All methods can fail with these errors:
  • “ERROR: VENDOR API KEY DISABLED” Software vendor has disabled the use of this vendor api key
  • “ERROR: USER HAS NO RIGHTS TO COMPANY” Current user has no rights to company with id given in ‘company_uuid’
  • “ERROR: USER BELONGS TO MULTIPLE COMPANIES, NO COMPANY ID GIVEN” No ‘company_uuid’ given
  • “ERROR: USER NOT FOUND” API key not found
  • “ERROR: COMPANY ACCOUNT IS LOCKED” Company’s account has been locked for some reason (e.g. too many disputes)
  • “ERROR: COMPANY HAS NOT COMPLETED FIRST TIME WIZARD” API won’t work until the user that registered for Maventa has completed the first time wizard
hello_world
  • “Hello world!”
country_list currency_list language_list relay_operator_list company_lookup
  • [CompanyLookupOut] An array of CompanyLookupOut which match the search string given
invoice_create
  • [[InvoiceStatus]] InvoiceStatus
  • The “status” of the InvoiceStatus object can be one of the following:
  • “ERROR: FILE @file NOT FOUND, INVOICE WAS NOT CREATED” An attachment was specified in the creation call but no file with that name was found
  • “ERROR: CUSTOMER COMPANY NOT FOUND WITH MAVENTA ID ’@maventaid’” Maventa ID given for customer but no such id exists
  • “ERROR: NO CUSTOMER INFORMATION FOUND” No customer information given (maventa_id or the whole CustomerParamsOut)
  • “ERROR: CUSTOMER COUNTRY CODE INVALID” Country code given in customer information is nit supported
  • “ERROR: COMPANY HAS NO POSTAL ADDRESS” Company has no postal address set
  • “ERROR: LANGUAGE @lang IS NOT VALID” Given language is not supported
  • “ERROR: DATE FORMAT INVALID FOR INVOICE DATE” Invalid date format
  • “ERROR: DATE FORMAT INVALID FOR DUE DATE” Invalid date format
  • “ERROR: DATE FORMAT INVALID FOR DELIVERY DATE” Invalid date format
  • “ERROR: NO ITEMS FOUND” No items in items array, invoice needs at least one item
  • “ERROR: AN ITEM IS NOT VALID” An item does not have all required values (subject, price, amount, tax, sum, sum_tax)
  • “ERROR: UNKNOWN ERROR” Something unexpected happened, please contact support with timestamp of request
  • “ERROR: COULD NOT CREATE INVOICE” Invoice saving failed for some reason, please contact support with timestamp of request
  • “OK: INVOICE CREATED” Everything went OK and invoice will be sent

Bravo specific:

  • “ERROR: COMPANY HAS NO POSTAL ADDRESS AND NO ADDRESS GIVEN” Company has no postal address set or given in request
  • “ERROR: INVALID FILE ATTACHMENT ATTACHMENT_TYPE” Currently allowed ATTACHMENT_TYPEs are: “ATTACHMENT”, “INVOICE_IMAGE”, “FINVOICE”, “TEAPPS”, “OIO”
  • “ERROR: FILENAME CONTAINS INVALID CHARACTERS” Only letters, numbers, underscore and dot are allowed in file names
  • “ERROR: INVALID FILETYPE ’@filename’ (allowed doc, xls, tif, jpg, gif, txt, xml, xsl, html, htm, pdf)” Allowed attachment types
  • “ERROR: ALL SEND ROUTES DISABLED” disabled_routes is 111 which leads to invoice not being sent at all
invoice_revoke
  • ERROR: INVOICE NOT FOUND OR NO RIGHTS Given invoice_id was not found or user has no rights to it
  • ERROR: COULD NOT CREATE CREDIT NOTE Something went wrong
  • ERROR: DELIVERY FAILED (NOT ENOUGH INFORMATION OF CUSTOMER) Invoice created but sending failed, no route found to customer
  • OK: INVOICE SENT Everything went OK and invoice revocation has been sent
invoice_list invoice_list_inbound invoice_show invoice_confirm
  • ERROR: INVOICE NOT FOUND OR NO RIGHTS Given invoice_id was not found or user has no rights to it
  • ERROR: COULD NOT MARK INVOICE AS PAID Could not save invoice for some reason
  • OK: INVOICE MARKED AS PAID Invoice successfully marked as paid
invoice_accept
  • ERROR: INVOICE NOT FOUND OR NO RIGHTS Given invoice_id was not found or user has no rights to it
  • ERROR: INVOICE STATE DOES NOT ALLOW ACCEPTANCE Invoice state is not “SENT” which is the only state from which invoice can be accepted
  • ERROR: COULD NOT ACCEPT INVOICE Could not save invoice for some reason
  • OK: INVOICE ACCEPTED Invoice accepted successfully
invoice_decline
  • ERROR: INVOICE NOT FOUND OR NO RIGHTS Given invoice_id was not found or user has no rights to it
  • ERROR: INVOICE STATE DOES NOT ALLOW ACCEPTANCE Invoice state is not “SENT” which is the only state from which invoice can be declined
  • ERROR: COULD NOT DECLINE INVOICE Could not save invoice for some reason
  • OK: INVOICE DECLINED Invoice declined successfully
invoice_dispute
  • ERROR: INVOICE NOT FOUND OR NO RIGHTS Given invoice_id was not found or user has no rights to it
  • ERROR: INVOICE STATE DOES NOT ALLOW ACCEPTANCE Invoice state is not “SENT” which is the only state from which invoice can be disputed
  • ERROR: COULD NOT DISPUTE INVOICE Could not save invoice for some reason
  • OK: INVOICE DISPUTED Invoice disputed successfully
user_create
  • OK: USER SAVED User created and activation email sent
  • ERROR: NO RIGHTS TO ADD USERS Only admin user can add new users
  • ERROR: @errormessage Error message with validation errors for the user
user_update
  • ERROR: USER NOT FOUND User with given user_id was not found
  • ERROR: NO RIGHTS TO USER Only the user in question or an admin can update user information
  • ERROR: USER COULD NOT BE SAVED User could not be saved for some reason
  • OK: USER SAVED User updated successfully
user_delete
  • ERROR: USER NOT FOUND User with given user_id was not found
  • ERROR: NO RIGHTS TO USER Only an admin can delete users
  • ERROR: CANNOT DELETE YOURSELF User cannot delete himself
  • ERROR: COULD NOT DELETE USER User could not be deleted for somea reason
  • OK: USER DELETED FROM COMPANY User deleted successfully
user_list user_show company_update
  • ERROR: COUNTRY CODE INVALID Given country code does not exist or is not supported
  • ERROR: @errormessage Validation errors
  • ERROR: NO RIGHTS TO CHANGE SETTINGS Only admin user can change settings
  • OK: COMPANY SAVED Company details updated successfully
company_list company_show company_settings_show company_settings_update
  • ERROR: NO RIGHTS TO CHANGE SETTINGS Only admin user can change settings
  • ERROR: COULD NOT SAVE SETTINGS Could not save settings for some reason
  • OK: SETTINGS SAVED Settings saved successfully
company_fee_list company_fee_show company_fee_create
  • ERROR: INVALID CURRENCY FOR COMPANY FEE Given currency not supported
  • ERROR: COMPANY ALREADY HAS FEE FOR CURRENCY @currency Company can only have one fee per currency
  • ERROR: @error Exception handling
  • OK: COMPANY FEE SAVED Company fee saved successfully
company_fee_update
  • ERROR: COMPANY FEE NOT FOUND OR NO RIGHTS CompanyFee with given id does not exist for current company
  • ERROR: INVALID CURRENCY FOR COMPANY FEE Given currency not supported
  • ERROR: COMPANY ALREADY HAS FEE FOR CURRENCY @currency Company can only have one fee per currency
  • ERROR: @error Exception handling
  • OK: COMPANY FEE SAVED Company fee saved successfully
company_fee_delete
  • ERROR: COMPANY FEE NOT FOUND OR NO RIGHTS CompanyFee with given id does not exist for current company
  • ERROR: COULD NOT DELETE COMPANY FEE Failed to delete company fee
  • OK: COMPANY FEE DELETED Company fee deleted successfully
bank_account_create
  • ERROR: @errormessage Error message with validation errors for the bank account
  • OK: ACCOUNT SAVED Account created successfully
bank_account_update
  • ERROR: ACCOUNT NOT FOUND OR NO RIGHTS BankAccount with given id does not exist for current company
  • ERROR: @errormessage Error message with validation errors for the bank account
  • OK: ACCOUNT SAVED Account updated successfully
bank_account_delete
  • ERROR: ACCOUNT NOT FOUND OR NO RIGHTS BankAccount with given id does not exist for current company
  • ERROR: COULD NOT DELETE ACCOUNT Could not delete account
  • OK: ACCOUNT DELETED Account deleted successfully
bank_account_list bank_account_show postal_address_create
  • ERROR: COUNTRY CODE INVALID Given country code does not exist or is not supported
  • ERROR: COMPANY ALREADY HAS ADDRESS INFORMATION FOR @country / @lang Company can only have one postal address for each country and language pair
  • ERROR: @errormessage Error message with validation errors for the postal address
  • OK: POSTAL ADDRESS SAVED Postal address created successfully
postal_address_update
  • ERROR: POSTAL ADDRESS NOT FOUND OR NO RIGHTS Given postal_address_id not found for current company
  • ERROR: COUNTRY CODE INVALID Given country code does not exist or is not supported
  • ERROR: COMPANY ALREADY HAS ADDRESS INFORMATION FOR @country / @lang Company can only have one postal address for each country and language pair
  • ERROR: @errormessage Error message with validation errors for the postal address
  • OK: POSTAL ADDRESS SAVED Postal address updated successfully
postal_address_delete
  • ERROR: POSTAL ADDRESS NOT FOUND OR NO RIGHTS Given postal_address_id not found for current company
  • ERROR: COULD NOT DELETE POSTAL ADDRESS Postal address could not be deleted
  • OK: POSTAL ADDRESS DELETED Postal address deleted successfully
postal_address_list postal_address_show get_pdf
  • ERROR: INVOICE NOT FOUND Invoice not found for given invoice_id
  • ERROR: USER NOT FOUND FOR API KEY User not found for given API key
  • ERROR: COULD NOT CREATE PDF PDF creation failed for some reason
  • ERROR: USER HAS NO RIGHTS TO INVOICE Invoice does not belong to current company
  • SOAP Attachment If all goes well, return value is a SOAP Attachment with the name “invoice.pdf”
get_partner_transactions
  • ERROR: USER NOT FOUND FOR API KEY User not found for given API key
  • ERROR: VENDOR API KEY NOT FOUND @vendor_api_key Given vendor API key was not found
  • ERROR: USER HAS NO RIGHTS TO VENDOR API KEY Vendor API key does not belong to user’s company
  • SOAP Attachment If all goes well, return value is a SOAP Attachment with the name
get_files
  • ERROR: INVOICE NOT FOUND Invoice not found for given invoice_id
  • ERROR: USER NOT FOUND FOR API KEY User not found for given API key
  • ERROR: COULD NOT CREATE FILES Could not create files for some reason
  • ERROR: USER HAS NO RIGHTS TO INVOICE Invoice does not belong to current company
  • SOAP Attachment If all goes well, return value is a SOAP Attachment with the name “@invoice_nr.zip”
put_xml
  • ERROR: USER NOT FOUND FOR API KEY User not found for given API key
  • ERROR: COMPANY NOT FOUND OR NO RIGHTS User does not belong to given company_uuid
  • ERROR: NO VALID XML INVOICE FOUND File is not a valid XML invoice or is not supported
  • ERROR: FILENAME IS NOT AN XML Filename must be .xml
  • OK: INVOICE CREATED SUCCESSFULLY OK, an invoice created from the XML sent
put_zip
  • ERROR: USER NOT FOUND FOR API KEY User not found for given API key
  • ERROR: COMPANY NOT FOUND OR NO RIGHTS User does not belong to given company_uuid
  • ERROR: INVALID ZIP FILE Could not open the zip file
  • ERROR: NO VALID XML INVOICE FOUND No valid XML invoice found in zip
  • ERROR: FILE IS NOT A ZIP Filename must be .zip
  • ERROR: @error Exception handling
  • OK: INVOICE CREATED OK, at least one invoice was created
put_attachment
  • ERROR: USER NOT FOUND FOR API KEY User not found for given API key
  • ERROR: COMPANY NOT FOUND OR NO RIGHTS User does not belong to given company_uuid
  • ERROR: INVALID FILETYPE ’@filetype’ (allowed doc, xls, tif, jpg, gif, txt, xml, xsl, html, htm, pdf) Invalid filetype for attachment
  • ERROR: @error Exception handling
  • OK: FILE ’@filename’ RECEIVED File saved to company’s incoming files and can be added to an invoice

Also available in: HTML TXT