Create a partner-hosted app
A Zettle partner-hosted app is hosted by the integrator building the app. Authorisation is done using the authorisation code grant method.
This method provides the client app with access to a merchant’s data without giving away any credentials. The merchant authorises the client app, which presents proof of authorisation to the server. A temporary authorisation code is generated from the authorisation server using API credentials. These include a client secret and client ID. The temporary code is then exchanged for an access token by the authorisation server.
With authorisation code grant, client app usage tracking is available by default.
To use the authorisation code grant method, you need to create an app with API credentials from the Developer Portal. See the following how to do this.
Note: To build an app that will be hosted by individual merchants, see create a self-hosted app.
Prerequisites
- An account for the Developer Portal. If you don't have this, sign up for a developer account.
Get API credentials for a new app
Follow these steps to get API credentials for the app.
Log in to the Developer Portal.
On your Dashboard, click Create a new app.
On the Create a new app page, click Public API credentials to open the form for app information.
Fill in the form.
Click Get credentials to create the API credentials.
Download the API credentials and save them somewhere safe.
Tip: If you lose the client secret, you can request a new one.
Request a new client secret for an existing app
See the following how to get a new client secret for an existing app. The client ID of an app doesn't change.
Log in to the Developer Portal.
On your Dashboard, select the app for which you need a new client secret. The current client secret is hidden.
On the app page, click Request new client secret to deactivate the current secret and generate a new one. The new client secret will be shown.
Download your API credentials and save them somewhere safe.