Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
Mirrored from https://github.com/Camo67/composio.git
Synced Nov 21, 06:00 UTC
| 1 | ## How do I set up custom OAuth credentials for ServiceM8? |
| 2 | |
| 3 | Composio-managed OAuth works for ServiceM8 without any setup. Use your own ServiceM8 add-on when you want your app name on the consent screen and control over its permissions. You need a [ServiceM8 developer account](https://developer.servicem8.com/). |
| 4 | |
| 5 | ### Create the ServiceM8 add-on |
| 6 | |
| 7 | 1. Sign in to ServiceM8 and open **Developer** from the main menu. On **Store Items**, click **Add Item**. |
| 8 | |
| 9 |  |
| 10 | |
| 11 | 2. Enter a **Name** and **Description**. Keep **Category** set to **Add-on**, choose a price (Free works for a private integration), and click **Save**. ServiceM8 opens the add-on's settings. |
| 12 | |
| 13 |  |
| 14 | |
| 15 | 3. Scroll to **Addon OAuth Credentials** and copy the **App Id** and **App Secret**. These are the client ID and client secret in Composio. |
| 16 | |
| 17 |  |
| 18 | |
| 19 | 4. Under **Addon SDK**, set **Addon Type** to **External Integration**. |
| 20 | 5. Set **Addon Activation URL** to `https://backend.composio.dev/api/v1/auth-apps/add` and click **Save**. ServiceM8 checks the OAuth redirect host against this URL, so it must match the auth config's `oauth_redirect_uri` field. See ServiceM8's [authentication docs](https://developer.servicem8.com/docs/authentication). |
| 21 | |
| 22 |  |
| 23 | |
| 24 | ### Create the auth config in Composio |
| 25 | |
| 26 | 1. In the [Composio dashboard](https://dashboard.composio.dev/~/project/auth-configs?utm_source=docs&utm_medium=content&utm_campaign=toolkits-servicem8), go to **Auth Configs** → **Create** and select **ServiceM8**. |
| 27 | |
| 28 |  |
| 29 | |
| 30 |  |
| 31 | |
| 32 | 2. Choose **OAuth 2.0** and **Your Own Credentials**. Enter the App Id as the client ID and the App Secret as the client secret. Keep the default redirect URI. |
| 33 | |
| 34 |  |
| 35 | |
| 36 | 3. Under **Scopes**, choose the permissions your tools need, then click **Create Auth Config**. |
| 37 | |
| 38 |  |
| 39 | |
| 40 | 4. Click **Connect Account** and sign in to the ServiceM8 account you want to connect. A new draft add-on shows **This Addon isn't verified**; confirm it's your add-on and click **Proceed**. Check the app name and permissions, then click **Allow**. |
| 41 | |
| 42 |  |
| 43 | |
| 44 |  |
| 45 | |
| 46 | 5. Open the auth config's **Accounts** tab and confirm the account shows **Active**. The auth config's own **Enabled** label doesn't mean an account is connected. |
| 47 | |
| 48 |  |
| 49 | |
| 50 | See [custom auth configs](/docs/auth-configuration/custom-auth-configs) for the general flow. |
| 51 | |
| 52 | ### Scopes |
| 53 | |
| 54 | ServiceM8 permissions are per resource, such as `read_jobs`, `manage_jobs`, `read_customers`, `manage_customers`, `read_staff`, and `read_schedule`. The default auth config requests read and manage permissions across jobs, customers, staff, schedule, inventory, assets, and messaging. A read-only jobs integration needs only `read_jobs`. See ServiceM8's [scope descriptions](https://developer.servicem8.com/docs/authentication). |
| 55 | |
| 56 | The add-on can stay a draft. Publishing it to the ServiceM8 directory is a separate process, and submitting the add-on for review removes the unverified warning. |