Steel, Mark
-
Posts
479 -
Joined
-
Last visited
-
Days Won
35
Content Type
Profiles
Forums
Events
Articles
Downloads
Gallery
Posts posted by Steel, Mark
-
-
Hi @Arthur Liou,
403 relates to the auth level of the user. We'll need some further information to understand the issue. Can you DM me with the below please.
{ "access_token": "XfbYpJAxVeBE8jxkS1Ed90prGPrcPB8Iti8jQ2uEL2KeDnFRh3dViCy_gaMUTWOxeZtSWC1IKVx8E9p6FCRLwSz14oBwvnJs1RgImEcMr4-XwBUdSZJjbvItONEFJV-aKMv1A64r1osvs1KRVVx6twYzoP20oMP4MuRhW-_OjJcivv6jSLP1cIfnCmOzAbPDBjGl9ofardvnuwb_1lAFw", "expires_in": 300, "token_type": "bearer", "refresh_token": "eyJhbGciOiJSUzUxMiIsImtpZCI6IjRLR1RqZmN4TGpOWXdac1BiSjZkZ2Y1Zi1MdG9aSmp2cFR2c0hsUnFGX2s9In0.eyJqdGkiOiI1MTAzMzk0MS1mYzljLTQyZmItYjMzMy1kNzQ3YjkzM2ZkNWUiLCJpYXQiOjE3MDc3Mzc4MTMsImV4cCI6MTcxzKcPYbTNjQre5w", "refresh_token_expires_in": 2678400, "scope": "full_access", "requested_by_id": "2b486e58-632a-a6cd-6ea8-eb5183931ad3" }
We'll need:
- The requested_by_id returned on the access_token
- The business ID or the email address of the user
- The region the business is located in CA, IE, UK or US
ThanksMark
-
Hi @Railz Dev,
It is possible via a journal transaction using body params as per the example below.
{ "journal": { "date": "2024-04-15", "reference": "Multi Currency Transfer", "description": "Multi Currency Transfer", "total": "100", "journal_lines": [ { "ledger_account_id": "d47fbc695161427b9d579d92020c2d1b", "details": "Money In to Dollar Account", "debit": "100.0", "credit": "0.0", "journal_line_foreign_currency":{ "currency_debit":"121.46", "currency_credit":"0.00", "exchange_rate": "1.2145675946" } }, { "ledger_account_id": "ccd4db18df44421bbdc93e18ab1427b7", "details": "Money Out of Euro Account", "debit": "0.0", "credit": "100.0", "journal_line_foreign_currency":{ "currency_credit":"112.75", "currency_debit":"0.0", "exchange_rate": "1.127522832" } } ] } }
Thanks
Mark
-
Hi @Steve Lalanne,
Thank you for your post. You would need to use the CA_NO_TAX rate for the transaction to be valid. I've included an example body for you to try.
The tax_rates API returns the tax_rate_id for a given region if you need to understand what tax_rate_id is validhttps://api.accounting.sage.com/v3.1/tax_rates?address_region_id=US-KY
{ "sales_invoice": { "contact_id": "dfd5417ec8384cc89084eb6e9f2cf1f9", "date": "2024-04-15", "reference": "10748979", "tax_address_region_id":"CA-ON", "invoice_lines": [{ "description": "LAREDO, TX - LOUISVILLE, KY", "ledger_account_id": "b21edb9145aa11ee8d7712b53df3d14f", "unit_price": "390.00", "tax_amount": "0.00", "quantity": "1", "tax_rate_id": "CA_NO_TAX" }, { "description": "FSC - (Standard Rate)", "ledger_account_id": "b21edb9145aa11ee8d7712b53df3d14f", "unit_price": "5108.10", "tax_amount": "0.00", "quantity": "1", "tax_rate_id": "CA_NO_TAX" } ], "main_address":{ "address_line_1":"34 CANUCK DRIVE", "address_line_2":"", "City":"MISSISSAUGA", "postal_code":"L5T 1C1", "region":"ON", "country_group_id":"CA" }, "delivery_address":{ "address_line_1":"1 JONES LANE", "address_line_2":"", "City":"MILOUISVILLESSISSAUGA", "postal_code":"40243", "region":"KY", "country_group_id":"US" } }}
Thanks
Mark
-
Hi @Arthur Liou
Thank you for your post.
Trial accounts have all of the same scope as if you were paying a subscription and this is not the issue here.
If you can PM me with the email address of the user you are authenticating the API with or raise a support ticket with [email protected] and provide it there we'll be able to provide greater insight to the issue.Thanks
Mark -
Hi @John Charnley,
I've set you a PM to ask for some additional details to help us trace the error.
It may be that one or more of the SI's being returned has a large number of item lines that is causing the backend server to exceed the 28's the API gateway waits for the response.
What data do you actually require from the SI? It may be that you can specify the attributes you require rather than ask for all?
Thanks
Mark -
Hi Dimitris,A 504 is a standardised response for an http request that has timed out. For sage it means the backend hasn't been able to respond within 28 seconds with the API gateway."I use the client from 'Find' but get the 504 Gateway error" - What are you passing in the find please? You've included a screen shot of the Create Sales Invoice form which is using the Name. This needs to pass the contact id of the find result - https://developer.sage.com/accounting/zapier/search-options/.ThanksMark
-
Hi @Mahnoor Zia,
What problem are you referring to please?
The problem Craig experienced was due to the correct callback urls not being registered against his app. The solution was to add the correct callback in the app registry.
https://developer.sage.com/accounting/guides/authenticating/oauth-troubleshooting/Thanks
Mark
-
Hi @Rafał Pająk
Thank you for your post,
Are you able to provide an example import containing the transaction as it's not been possible to replicate the issue following the steps you outline with our own imported payment on account transaction.
ThanksMark
-
Hi @Railz Dev,
Thank you for your post.
Sage Business Cloud Accounting resolves all foreign currencies to the businesses base currency meaning you cannot transfer amounts between two bank accounts which use currency different to that of the business base currency.
You'd need to make two separate transfers, one from the first non base bank account to a bank account with the same base currency as the business and then a second from the base currency bank account to the other non base bank account with the relevant exchange rates.
Thanks
Mark -
The rules aren't documented per se as this is legislation and rules stipulated by HMRC. A lot the legislation came about during brexit and the subsequent EU VAT Reform.
We have articles and guides relating to those changes which introduce the tax_determinations API https://developer.sage.com/accounting/reference/taxes/#tag/Tax-Determinations. This has a number of query params that can be passed and will return the tax_rates which are valid based on the params passed.For example here we have a UK Vat registered business and an EU customer, we can pass the usage type which is sales, and the contact_id for example:
GET https://api.accounting.sage.com/v3.1/tax_determinations?usage=sales&contact_id=4dc963f0c3284f9cbdebd31b569597cd
This returns the below response of which there is only one tax_rate_id returned:
{ "$total": 1, "$page": 1, "$next": null, "$back": null, "$itemsPerPage": 20, "$items": [ { "id": "GB_ZERO", "displayed_as": "Zero Rated 0.00%", "$path": "/tax_rates/GB_ZERO" } ] }
https://developer.sage.com/accounting/guides/eu-vat-reform/
https://developer.sage.com/accounting/guides/brexit/
Thanks
Mark -
Thanks @raghu Chaudhary,
The error message is informing you of the issue. The tax_rate_id applicable for this item line is GB_ZERO. GB_EXEMPT is an invalid tax_rate_id for sales of goods to the EU for VAT registered businesses. - "must be 'Zero Rated' for Customers outside the EU.","$source":"line_items.tax_rate"}]
Thanks
Mark
-
Thanks @raghu Chaudhary,
Goods and services sold from a VAT registered UK business to the EU need to report the transactions via the EU Sales List Report.
https://www.gov.uk/guidance/vat-exports-dispatches-and-supplying-goods-abroad
Goods and services sold to the EU fall in to different classifications and potentially different VAT rates. When creating a sales_invoice for an EU customer each line item must be classified with either Goods or Services but you cannot have a mix of both. You would need to create separate sales_invoice's for this scenario.
The JSON body should resemble the below.{ "sales_invoice": { "contact_id": "4dc963f0c3284f9cbdebd31b569597cd", "date": "2024-04-04", "reference": "API EU Inv", "invoice_lines": [ { "description": "Goods item line", "ledger_account_id": "7a5ecfcf884911ed84fa0252b90cda0d", "unit_price": "100", "quantity": "2", "tax_rate_id": "GB_ZERO", "eu_goods_services_type_id":"GOODS" }, { "description": "Another goods item line", "ledger_account_id": "7a5ecfcf884911ed84fa0252b90cda0d", "unit_price": "10", "quantity": "50", "tax_rate_id": "GB_ZERO", "eu_goods_services_type_id":"GOODS" } ] } }
ThanksMark
-
Hi Raghu,
Thank you for your post.
There's a lot of validation involved with EU sales and many variables. If you can let me know the following I'll be able to help you further:- The country/location of the business(the province or state if US/CA)
- The taxation scheme of the business
- The customers location (presuming this is a sales_invoice)
- If the customer is registered for tax (business to business transaction)
- The type of items being sold(goods or services)
Thanks
Mark
-
Hi @Maximo Smith,
Since Zapier's recent UI change we've seen cases of attribute values being concatenated and causing 504's in the app.
If you contact myself through the developer services email address [email protected] I'll arrange a Teams call with yourself to look at this in more detail.
Thanks
Mark
-
Hi Carlos,
Thank you for your post.
Sage 300 isn't a product supported on the community at present. If you don't receive a response you can contact the Sage 300 Developer Support team at [email protected].Thanks
Mark
-
Hi Carlos,
Sage 300 isn't a supported product in the community at present. You can direct your queries to the Sage 300 Developer Support team at [email protected] for help with this issue.
Thanks
Mark
-
Hi Donna,
Sage 300 isn't a supported product in the community at present. You can direct your queries to the Sage 300 Developer Support team at [email protected] for help with this issue.
Thanks
Mark
-
Hi Caludio,
Thank you for your post.
Alternatively to requesting attributes=all you can use the ID of the data record to obtain the full response.
https://api.accounting.sage.com/3.1/ledger_accounts/e438573afaca11e7aa730a57719b2edbThanks
-
-
Thanks Andrew,
You'll need to pass Accept:application/json in the header also.
There's a useful POSTMAN env which has a small collection you can use as a starting point to build out the collection further.
- 1
-
Hi Shivam,
Thank you for your post.
The API gateway times out after 28 seconds of waiting for a response from the backend. If you're creating artefacts, Estimate's in this instance with a large number of line items it may be that at times the backend is unable to respond in 28 sec's. If the payload is all good the artefact will be created.
You'll need to think about implementing idempotency in your requests if large numbers of item lines is likely to be the norm. https://developer.sage.com/accounting/guides/concepts/idempotency/.I've also referenced the below threads in the developer community from people having similar issues when posting sales_invoices. -
Hi Andrew,
Thanks for your post.
What is the request you are making and what headers are you passing in the request?
Thanks
Mark
-
Hi Joe,
I'm not sure why you referenced https://capcutproapk.org/?The API reference for https://developer.sage.com/accounting/reference/products-services/#tag/Products/operation/postProducts provides the ability to expand the sales_prices array which references the product_sales_price_type_id as per the example json body above. It doesn't highlight it as a required field however so we do need to update that aspect of the swagger/open API spec.
https://developer.sage.com/accounting/reference/products-services/#tag/Product-Sales-Price-Types - Details how to obtain and create product_sales_prices.
ThanksMark
-
Hi Rishiom,
The fix has now been deployed and the problem client_id's are now working.
Thanks for your patience.
Mark
Bank transactions not importing into Sage Business Cloud
in Support
Posted
Hi @Nolubabalo Dube,
The developer community is not the best place for someone to answer your product question and is aimed at supporting 3rd party developers integrating with Sage products via Sage API's and SDK's.
If you reach out in https://communityhub.sage.com/gb/sage-business-cloud-accounting/ or contact customer support using one of the options listed at https://my.sage.co.uk/public/help.aspx#/contact?locale=uk&type=customer&product=sagebusinesscloudaccountingstart someone will be able to help you.
Kind regards
Mark Steel