Script settings API
The script settings endpoints, each in TypeScript, Python, the CLI and curl.
Set up
Section titled “Set up”npm install @reminix/sdkexport REMINIX_API_KEY="<your API key>"pip install reminixexport REMINIX_API_KEY="<your API key>"npm install -g @reminix/clireminix loginexport REMINIX_API_KEY="<your API key>"To pass the key yourself, use createClient({ apiKey: key }) in TypeScript or Reminix(api_key=key) in Python.
Get the workspace’s script settings
Section titled “Get the workspace’s script settings”GET /v1/script-settings Try it in the API playground (opens in a new tab) Scope: scripts:read.
Returns how the workspace governs scripts, such as whether publishing needs a second person.
import { createClient } from "@reminix/sdk";
// Uses the REMINIX_API_KEY environment variable.const reminix = createClient();const scriptSetting = await reminix.scriptSettings.get();console.log(scriptSetting);from reminix import Reminix
# Uses the REMINIX_API_KEY environment variable.reminix = Reminix()script_setting = reminix.script_settings.get()print(script_setting)reminix script-settings getcurl -X GET "https://api.reminix.com/v1/script-settings" \ -H "Authorization: Bearer $REMINIX_API_KEY"Returns:
{ "publishNeedsSecondPerson": false}Change the workspace’s script settings
Section titled “Change the workspace’s script settings”PATCH /v1/script-settings Try it in the API playground (opens in a new tab) Scope: scripts:write.
Changes how the workspace governs scripts.
import { createClient } from "@reminix/sdk";
// Uses the REMINIX_API_KEY environment variable.const reminix = createClient();const scriptSetting = await reminix.scriptSettings.update({ publishNeedsSecondPerson: false,});console.log(scriptSetting);from reminix import Reminix
# Uses the REMINIX_API_KEY environment variable.reminix = Reminix()script_setting = reminix.script_settings.update(publish_needs_second_person=False)print(script_setting)reminix script-settings update --no-publish-needs-second-personcurl -X PATCH "https://api.reminix.com/v1/script-settings" \ -H "Authorization: Bearer $REMINIX_API_KEY" \ -H "Content-Type: application/json" \ -d '{"publishNeedsSecondPerson":false}'Returns:
{ "publishNeedsSecondPerson": false}| Field | Description |
|---|---|
publishNeedsSecondPerson | Whether publishing needs a second person. When it's on, each publish becomes a request. Another owner or admin, not the person who asked, approves it. |
More about this endpoint
Workspace owners and admins can change these settings, and so can a workspace API key. Turning on second-person publishing needs the Business plan.