Walkthrough

For these APIs the OAuth Password Grant Type is used.

To use this, you need the following: client-id, client-secret, username and passord. You get the client credentials when you register/order your app, and the username and password can be created by an API administrator in Min Bedrift.

Authentication

A minimal curl-example to authenticate with the api is given below (replace the client-id, client-secret, username and password with your own):

If you were successful using the correct credentials, running this example will return a valid access-token that you can use to make calls against the APIs you have access to.

For a more in-depth explanation of the authorization and authentication flow, consult the OAuth documentation

Examples

To get all incidents try the following curl:

A full example in Java can be found in our GitHub Repo

API-reference

When the access token is obtained the app can access the available endpoints for this specific API.

API references

Information about accounts

This API will allow the application to fetch information about a company's accounts. Access is limited to the system user used. The raw swagger doc for the API product can be found here

Please use only version 2 of corporate-accounts, corporate-mobile-subscriptions and corporate-agreements since version 1 of these APIs is deprecated.

Information about agreements

This API will allow the application to fetch information about a company's agreements (for example Mobilt Bedriftsnett) and agreed product offers. Access is limited to the system user used. You will find the swagger doc here.

Please use only version 2 of corporate-accounts, corporate-mobile-subscriptions and corporate-agreements since version 1 of these APIs is deprecated.