Clover uses OAuth 2.0 to create a secure connection between your Web apps and Clover merchant information.
For your Android app, you can simply generate an API token and query web services using Clover Android SDK.
The Clover OAuth 2.0 framework requires you to retrieve an API token before you can query merchant information, such as inventory, orders, and payments.
Clover’s implementation of OAuth 2.0 consists of the following parts:
Client ID (App ID)
The Client ID or App ID uniquely identifies an app on Clover App Market.
Client Secret (App Secret)
The Client Secret or App Secret is a secret key that is assigned to your app by Clover.
Merchant ID (MID)
The merchant ID uniquely identifies Clover merchants (including test merchants) on the Clover platform. MIDs are 13 characters in length. On the Merchant Dashboard, you can find the MID for your test merchant in the browser window URL.
When a merchant has signed in to Clover with their merchant account, you receive an authorization code. With this code, you can request for an API token.
With the API token, your app can make REST API calls and access merchant data.
You can view the App ID and App Secret on the App Settings page.
To generate a test API token for your web app in the sandbox environment:
- On the sandbox Developer Dashboard, select a test merchant from the header menu.
- On the Merchant Dashboard that appears, click Setup > API Tokens.
- Enter a name to uniquely identify your API token and then select Generate Token. Your generated test API token is available in the table below.
- Set your app permissions based on the type of test merchant information you want to query and manage. Note that each permission maps to a Clover REST API endpoint.
- Select Save. You can create as many test API tokens as required.
With your test API token, you can make a REST API call and access Clover merchant data.
Tokens generated with the Setup app should only be used when testing the API in sandbox. Using these merchant tokens in production is forbidden.
Updated 7 days ago