Discourse
Use openspective with the discourse-perspective-api plugin.
The discourse-perspective-api plugin has Google’s domain written into its code (GOOGLE_API_DOMAIN in lib/discourse_perspective.rb), and there’s no setting to change it.
Until the plugin accepts a configurable URL, install a fork with the constant changed:
- Fork the plugin.
- In
lib/discourse_perspective.rb, changeGOOGLE_API_DOMAINfromhttps://commentanalyzer.googleapis.comto your openspective URL. - In your Discourse
app.yml, install the plugin from your fork instead of the original, and rebuild. - In the plugin settings, set the API key to one of your
OPENSPECTIVE_API_KEYS, or any value if your server doesn’t require keys.
A change to make the URL a site setting is tracked in openspective’s issues. Once the plugin supports it, this page will switch to the setting.