Skip to content

Commit 5f8a21b

Browse files
committed
Add activate grid skill
1 parent a8729a8 commit 5f8a21b

2 files changed

Lines changed: 46 additions & 1 deletion

File tree

.claude/skills/grid-api/SKILL.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,25 @@ For detailed information, read these reference files in the `references/` direct
6060
cd cli && npm install && npm run build && cd ..
6161
```
6262

63+
### Automatic Setup (Check First)
64+
65+
Before prompting for credentials, check if a setup script exists in the workspace:
66+
- `./setup-grid-credentials`
67+
- `./setup-grid-credentials.sh`
68+
- `./scripts/setup-grid-credentials`
69+
70+
If found, source the script to set environment variables:
71+
```bash
72+
source ./setup-grid-credentials
73+
```
74+
75+
Then verify the credentials work:
76+
```bash
77+
node cli/dist/index.js config get
78+
```
79+
80+
If the setup script exists and credentials work, skip the manual setup steps below.
81+
6382
### Quick Setup (Recommended)
6483

6584
Run the interactive configuration command:
@@ -77,7 +96,7 @@ This will:
7796
You can also configure via environment variables:
7897
- `GRID_API_TOKEN_ID` - API token ID
7998
- `GRID_API_CLIENT_SECRET` - API client secret
80-
- `GRID_BASE_URL` - Base URL (defaults to `https://api.lightspark.com/grid/2025-10-13`)
99+
- `GRID_BASE_URL` - Optional override (defaults to `https://api.lightspark.com/grid/2025-10-13`)
81100

82101
### Non-Interactive Setup
83102

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -924,6 +924,32 @@ export GRID_API_TOKEN_ID="your-token-id"
924924
export GRID_API_CLIENT_SECRET="your-client-secret"
925925
```
926926

927+
### Automated Credential Setup
928+
929+
For convenience, you can create a `setup-grid-credentials` script in the repository root to automatically configure credentials. This script will be detected and run when activating the Grid skill.
930+
931+
Create a file named `setup-grid-credentials` (or `setup-grid-credentials.sh`):
932+
933+
```bash
934+
#!/bin/bash
935+
export GRID_API_TOKEN_ID="your-token-id"
936+
export GRID_API_CLIENT_SECRET="your-client-secret"
937+
# Optional: override the base URL (defaults to https://api.lightspark.com/grid/2025-10-13)
938+
# export GRID_BASE_URL="https://api.lightspark.com/grid/2025-10-13"
939+
```
940+
941+
Make it executable:
942+
943+
```bash
944+
chmod +x setup-grid-credentials
945+
```
946+
947+
Add the script to `.gitignore` to avoid committing credentials:
948+
949+
```bash
950+
echo "setup-grid-credentials*" >> .gitignore
951+
```
952+
927953
## Support
928954

929955
For any questions or issues, please contact Grid support at <support@lightspark.com>.

0 commit comments

Comments
 (0)