Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions .github/workflows/slack-cli-generate-docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Generate Slack CLI Docs

on:
workflow_dispatch:
Comment on lines +3 to +4
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👁️‍🗨️ thought: Adding on "version" tags might be interesting! Otherwise we will need to add this to our release runbooks.

📣 ramble: So open to saving this for follow ups of course.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗣️ note: Ugh that was more clear in mind... I meant to suggest "on new tagged releases the workflow should run" but I forget the syntax!


jobs:
update-docs:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔐 todo: This'll also need some set of permissions. Do let me know if I can help with this!

runs-on: ubuntu-latest

steps:

- name: Install Slack CLI
run: |
curl -fsSL https://downloads.slack-edge.com/slack-cli/install.sh | bash

- name: Generate a GitHub token
id: ghtoken
uses: actions/create-github-app-token@v2
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💔 todo: We should use pinned versions here though I don't think the healthscore has released such a check yet...

📫 note: I can soon add these versions if needed!

with:
app-id: ${{ secrets.GH_APP_ID }}
owner: slackapi
private-key: ${{ secrets.GH_APP_PRIVATE_KEY }}

- name: Checkout code
uses: actions/checkout@v4

- name: Generate docs
run: |
slack docgen docs/reference

- name: Create a pull request
uses: peter-evans/create-pull-request@v7
with:
token: ${{ steps.ghtoken.outputs.token }}
title: "Automated Slack CLI reference docs for release"
body: "Automatically updating Slack CLI docs following release"
author: "slackapi[bot] <186980925+slackapi[bot]@users.noreply.github.com>"
committer: "slackapi[bot] <186980925+slackapi[bot]@users.noreply.github.com>"
commit-message: "Update slack cli reference docs"
base: "main"
branch: "update-slack-cli-reference"
delete-branch: true
labels: docs
28 changes: 14 additions & 14 deletions docs/reference/commands/slack.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,17 @@

Slack command-line tool

## Synopsis
## Description

CLI to create, run, and deploy Slack apps

Get started by reading the docs: [https://docs.slack.dev/tools/slack-cli](https://docs.slack.dev/tools/slack-cli/)
Get started by reading the docs: [https://docs.slack.dev/tools/slack-cli](https://docs.slack.dev/tools/slack-cli)

```
slack <command> <subcommand> [flags]
```

## Examples

```
$ slack login # Log in to your Slack account
$ slack create # Create a new Slack app
$ slack init # Initialize an existing Slack app
$ slack run # Start a local development server
$ slack deploy # Deploy to the Slack Platform
```

## Options
## Flags

```
-a, --app string use a specific app ID or environment
Expand All @@ -37,7 +27,17 @@ $ slack deploy # Deploy to the Slack Platform
-v, --verbose print debug logging and additional info
```

## SEE ALSO
## Examples

```
$ slack login # Log in to your Slack account
$ slack create # Create a new Slack app
$ slack init # Initialize an existing Slack app
$ slack run # Start a local development server
$ slack deploy # Deploy to the Slack Platform
```

## See also

* [slack activity](slack_activity) - Display the app activity logs from the Slack Platform
* [slack app](slack_app) - Install, uninstall, and list teams with the app installed
Expand Down
22 changes: 11 additions & 11 deletions docs/reference/commands/slack_activity.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,15 @@

Display the app activity logs from the Slack Platform

## Synopsis
## Description

Display the app activity logs from the Slack Platform

```
slack activity [flags]
```

## Examples

```
$ slack platform activity # Display app activity logs for an app
$ slack platform activity -t # Continuously poll for new activity logs
```

## Options
## Flags

```
--component string component type to filter
Expand All @@ -40,7 +33,7 @@ $ slack platform activity -t # Continuously poll for new activity logs
--trace-id string trace id to filter
```

## Options inherited from parent commands
## Global flags

```
-a, --app string use a specific app ID or environment
Expand All @@ -54,7 +47,14 @@ $ slack platform activity -t # Continuously poll for new activity logs
-v, --verbose print debug logging and additional info
```

## SEE ALSO
## Examples

```
$ slack platform activity # Display app activity logs for an app
$ slack platform activity -t # Continuously poll for new activity logs
```

## See also

* [slack](slack) - Slack command-line tool

30 changes: 15 additions & 15 deletions docs/reference/commands/slack_app.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,21 @@

Install, uninstall, and list teams with the app installed

## Synopsis
## Description

Install, uninstall, and list teams with the app installed

```
slack app [flags]
```

## Examples

```
$ slack app install # Install a production app to a team
$ slack app link # Link an existing app to the project
$ slack app list # List all teams with the app installed
$ slack app settings # Open app settings in a web browser
$ slack app uninstall # Uninstall an app from a team
$ slack app delete # Delete an app and app info from a team
```

## Options
## Flags

```
-h, --help help for app
```

## Options inherited from parent commands
## Global flags

```
-a, --app string use a specific app ID or environment
Expand All @@ -41,7 +30,18 @@ $ slack app delete # Delete an app and app info from a team
-v, --verbose print debug logging and additional info
```

## SEE ALSO
## Examples

```
$ slack app install # Install a production app to a team
$ slack app link # Link an existing app to the project
$ slack app list # List all teams with the app installed
$ slack app settings # Open app settings in a web browser
$ slack app uninstall # Uninstall an app from a team
$ slack app delete # Delete an app and app info from a team
```

## See also

* [slack](slack) - Slack command-line tool
* [slack app delete](slack_app_delete) - Delete the app
Expand Down
28 changes: 14 additions & 14 deletions docs/reference/commands/slack_app_delete.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,21 @@

Delete the app

## Synopsis
## Description

Uninstall the app from the team and permanently delete the app and all of its data

```
slack app delete [flags]
```

## Examples

```
# Delete an app and app info from a team
$ slack app delete

# Delete a specific app from a team
$ slack app delete --team T0123456 --app local
```

## Options
## Flags

```
-h, --help help for delete
```

## Options inherited from parent commands
## Global flags

```
-a, --app string use a specific app ID or environment
Expand All @@ -40,7 +30,17 @@ $ slack app delete --team T0123456 --app local
-v, --verbose print debug logging and additional info
```

## SEE ALSO
## Examples

```
# Delete an app and app info from a team
$ slack app delete

# Delete a specific app from a team
$ slack app delete --team T0123456 --app local
```

## See also

* [slack app](slack_app) - Install, uninstall, and list teams with the app installed

31 changes: 18 additions & 13 deletions docs/reference/commands/slack_app_install.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,24 @@

Install the app to a team

## Synopsis
## Description

Install the app to a team

```
slack app install [flags]
```

## Examples

```
$ slack app install # Install a production app to a team

# Install a production app to a specific team
$ slack app install --team T0123456
```

## Options
## Flags

```
-E, --environment string environment of app (local, deployed)
-h, --help help for install
--org-workspace-grant string grant access to a specific org workspace ID
(or 'all' for all workspaces in the org)
```

## Options inherited from parent commands
## Global flags

```
-a, --app string use a specific app ID or environment
Expand All @@ -41,7 +33,20 @@ $ slack app install --team T0123456
-v, --verbose print debug logging and additional info
```

## SEE ALSO
## Examples

```
# Install a production app to a team
$ slack app install

# Install a production app to a specific team
$ slack app install --team T0123456 --environment deployed

# Install a local dev app to a specific team
$ slack app install --team T0123456 --environment local
```

## See also

* [slack app](slack_app) - Install, uninstall, and list teams with the app installed

28 changes: 14 additions & 14 deletions docs/reference/commands/slack_app_link.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Add an existing app to the project

## Synopsis
## Description

Saves an existing app to a project to be available to other commands.

Expand All @@ -19,24 +19,14 @@ Only one app can exist for each combination of Team ID and environment.
slack app link [flags]
```

## Examples

```
# Add an existing app to a project
$ slack app link

# Add a specific app without using prompts
$ slack app link --team T0123456789 --app A0123456789 --environment deployed
```

## Options
## Flags

```
-E, --environment string environment to save existing app (local, deployed)
-h, --help help for link
```

## Options inherited from parent commands
## Global flags

```
-a, --app string use a specific app ID or environment
Expand All @@ -50,7 +40,17 @@ $ slack app link --team T0123456789 --app A0123456789 --environment deployed
-v, --verbose print debug logging and additional info
```

## SEE ALSO
## Examples

```
# Add an existing app to a project
$ slack app link

# Add a specific app without using prompts
$ slack app link --team T0123456789 --app A0123456789 --environment deployed
```

## See also

* [slack app](slack_app) - Install, uninstall, and list teams with the app installed

Loading
Loading