Config form

Config allows displaying a "one-time" form. All values from this form will be securely stored on the server and sent to the command any time it is run. Useful when a command requires some configuration (e.g. API key) before it can be run.

Simple Config formConfig form with error
Copy
Copied
{
  "config": {
    "form": {
      "fields": [
        {
          "type": "text",
          "id": "api-key",
          "label": "API Key",
          "placeholder": "GIPHY API key"
        }
      ]
    }
  }
}
Copy
Copied
{
  "config": {
    "form": {
      "error": "This API Key has expired",
      "fields": [
        {
          "type": "text",
          "id": "api-key",
          "label": "API Key",
          "placeholder": "GIPHY API key"
        }
      ]
    }
  }
}

Show the Config form conditionally

You will likely want to show the configuration form to the user conditionally, e.g. when the user hasn't entered the values yet or when the values are incorrect. See the Send Slack Message example to learn how to use the config form conditionally.