Skip to content

Commit

Permalink
Update / correct docs for the Connector plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
zackkatz committed Apr 30, 2024
1 parent 00e1058 commit 992759a
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 34 deletions.
45 changes: 13 additions & 32 deletions docs/Connector/hooks.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,55 +2,36 @@

## Filters {#filters}

### Modify default settings<br/>`trustedlogin/vendor/settings/default` {#modify-default-settingsbrtrustedloginvendorsettingsdefault}

```php
[
'account_id' => '',
'private_key' => '',
'api_key' => '',
'helpdesk' => [ 'helpscout' ],
'approved_roles' => [ 'administrator' ],
'debug_enabled' => 'on',
'enable_audit_log' => 'on',
]
```

### Modify menu location<br/>`trustedlogin/vendor/settings/menu-location` {#modify-menu-locationbrtrustedloginvendorsettingsmenu-location}

| Parameter | Type | Description | Default | Since |
| --- | --- | --- | --- | -- |
| `$location` | `string` | Where to place the TrustedLogin menu in the WordPress admin sidebar, either `main` or `submenu`. | `main` | `1.0.0` |

Filter:
Added to allow devs to move options item under 'Settings' menu item in wp-admin to keep things neat.

## Help Scout integration {#help-scout-integration}

### Modify returned licenses array<br/>`trustedlogin/vendor/customers/licenses` {#modify-returned-licenses-arraybrtrustedloginvendorcustomerslicenses}
### Modify returned licenses array<br/>`trustedlogin/connector/customers/licenses` {#modify-returned-licenses-arraybrtrustedloginvendorcustomerslicenses}

| Parameter | Type | Description | Default | Since |
| --- | --- | --- | --- | -- |
| `$licenses` | `\EDD_SL_License[]`,`false` | License keys associated with the passed emails. | `[]` | `1.0.0` |
| `$customer_emails` | `array` | Email addresses Help Scout associates with the customer. | `[]` | `1.0.0` |

return apply_filters( 'trustedlogin/vendor/customers/licenses', $licenses, $customer_emails );
### Widget template overrides {#widget-template-overrides}

### Help Scout widget template overrides {#help-scout-widget-template-overrides}
You can modify the template output implemented in the support desk (Help Scout or FreeScout) integrations using the following filters.

You can modify the template output implemented in the Help Scout integration using the following filters:
Replace the `(helpscout|freescout)` placeholder in the filter name with the support desk you are using (`helpscout` with `freescout`).

#### `trustedlogin/vendor/helpdesk/helpscout/template/wrapper` {#trustedloginvendorhelpdeskhelpscouttemplatewrapper}
#### `trustedlogin/connector/helpdesk/(helpscout|freescout)/template/wrapper` {#trustedloginvendorhelpdeskhelpscouttemplatewrapper}
HTML output of the wrapper HTML elements.

#### `trustedlogin/vendor/helpdesk/helpscout/template/item` {#trustedloginvendorhelpdeskhelpscouttemplateitem}
#### `trustedlogin/connector/helpdesk/(helpscout|freescout)/template/item` {#trustedloginvendorhelpdeskhelpscouttemplateitem}
HTML output of the individual items HTML elements.

#### `trustedlogin/vendor/helpdesk/helpscout/template/no-items` {#trustedloginvendorhelpdeskhelpscouttemplateno-items}
#### `trustedlogin/connector/helpdesk/(helpscout|freescout)/template/no-items` {#trustedloginvendorhelpdeskhelpscouttemplateno-items}
HTML output of the HTML elements when no items are found.

## Actions {#actions}

### `trustedlogin/vendor/add_hooks/after` {#trustedloginvendoradd_hooksafter}
### `trustedlogin_connector` {#trustedlogin_connector}

This action is triggered after the plugin is initialized.

### `trustedlogin_connector_settings_saved` {#trustedlogin_connector_settings_saved}

This action is triggered after the plugin adds menu items, initializes settings, and registers scripts and styles.
This action is triggered after the settings are saved or reset.
2 changes: 1 addition & 1 deletion docs/SaaS/server-setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ sidebar_position: 2

The TrustedLogin application is powered by Laravel and run on a Dockerized, high-availability, Kubernetes cluster.

The application handles account management, profiles, and billing. But most important, it receives and processes requests from the [Client SDK](/Client/intro) and [TrustedLogin Connector plugin](/Vendor/intro).
The application handles account management, profiles, and billing. But most important, it receives and processes requests from the [Client SDK](/Client/intro) and [TrustedLogin Connector plugin](/Connector/intro).

## What software powers TrustedLogin? {#what-software-powers-trustedlogin}

Expand Down
2 changes: 1 addition & 1 deletion docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Don't close the tab! We'll be coming back here to grab the Account ID, Public Ke

The TrustedLogin Connector plugin is a WordPress plugin that you host on your own site. The Connector plugin is what makes TrustedLogin so secure: secrets are encrypted and decrypted using keys that are generated by the Connector plugin.

1. [Download the Connector plugin](https://github.com/trustedlogin/trustedlogin-connector/releases/download/v1.0.0/trustedlogin-connector.zip)
1. [Download the Connector plugin](https://github.com/trustedlogin/trustedlogin-connector/releases/download/v1.1.0/trustedlogin-connector-1.1.zip)
2. Upload the plugin to your WordPress installation
3. Click the new "TrustedLogin" menu item in the sidebar menu
4. Configure the plugin using the Account ID, Public Key, and Private Key values from the Team page
Expand Down

0 comments on commit 992759a

Please sign in to comment.