API
Introduktion
Autentisering och auktorisering
Exempel på hämtning av åtkomsttoken
curl 'https://id.simutek.se/connect/token' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'client_id=your_client_id' \
--data-urlencode 'client_secret=your_client_secret' \
--data-urlencode 'grant_type=client_credentials'import requests
def fetch_access_token():
url = "https://id.simutek.se/connect/token"
headers = {
"Content-Type": "application/x-www-form-urlencoded"
}
data = {
"client_id": "YOUR_CLIENT_ID",
"client_secret": "YOUR_CLIENT_SECRET",
"grant_type": "client_credentials"
}
response = requests.post(url, headers=headers, data=data)
if response.status_code == 200:
access_token = response.json().get("access_token")
print(f"Access Token: {access_token}")
else:
print(f"Failed to fetch access token. Status Code: {response.status_code}")
print(response.text)
if __name__ == "__main__":
fetch_access_token()Headers
Dokumentation
Success. The customer was created.
No content
Bad request. The request is not well-formed or there is a validation error.
Not Found
Server error. An internal server error occured. Please try again later.
No content
The customer number.
Success. The company was found and returned.
Bad request. The request is not well-formed or there is a validation error.
Not found. The customer with provided customer number was not found.
Server error. An internal server error occured. Please try again later.
Optional filter by exact customer number.
Optional filter by name, matches anywhere in the name.
Optional filter by corporate identity number. Spaces and dashes are ignored when matching.
Page number, starting from 1. Default is 1.
1Page size, maximum 100. Default is 50.
50OK
Bad Request
Internal Server Error
The customer number in GKS of the buyer. A company with this customer number must exist in GKS.
K100421Optional name of the sales order that will be useful when searching for the order. Default: "Webshop order".
Obsolete. We do not see a business need to change the date of purchase. It should always be the same date as the order request is received.
An optional purchase order number from the buyer. In PlaceSimpleOrder API, "CustOrderNo".
Indicates whether the order is an export outside the seller's country.
Affects VAT calculation on the sales order.
When true, all orderline VatPercent must be 0.
Default: false. When null together with Simutek.GksPublic.ApplicationService.DTO.SalesOrder.IsExportWithinEu
and all orderline VatPercent, all three are fetched from the customer directory instead.
Indicates whether the order is an export to another country within the EU.
Affects VAT calculation on the sales order.
Requires Simutek.GksPublic.ApplicationService.DTO.SalesOrder.IsExport to be true when set to true.
Default: false. When null together with Simutek.GksPublic.ApplicationService.DTO.SalesOrder.IsExport
and all orderline VatPercent, all three are fetched from the customer directory instead.
The preferred language (ISO 639-1) of documents communicated with the buyer, i.e. order confirmation. Accepted values: sv, no, en
The currency of the amounts in this sales order. ISO 4217.
SEKA comment added by the customer during placement of the order. Commonly with instructions to the seller.
Success. The sales order was created.
Bad request. The request is not well-formed or there is a validation error.
Not found. The customer number was not found.
Server error. An internal server error occured. Please try again later.
Last updated