api-explorationlisted
Install: claude install-skill fusebase-dev/fusebase-flow
# API Exploration with Temporary Tokens
When you're unsure about an API endpoint's behavior, response shape, or want to test a flow before committing to implementation — create a temporary token and run test calls directly.
## Workflow
### 1. Create a temporary token
```bash
fusebase token create --feature <featureId>
```
This outputs a short-lived token (15 min) to stdout. Capture it:
```bash
TOKEN=$(fusebase token create --feature <featureId>)
```
The `appId` comes from `fusebase.json` → `apps[].id`.
### 2. Write and run test code
Create a temporary script (e.g. `_test-api.ts`) to make the API calls you want to verify:
```typescript
const token = process.env.TOKEN || "<paste-token-here>";
const res = await fetch("https://api-endpoint/...", {
headers: { "x-app-feature-token": token },
});
console.log(res.status);
console.log(await res.json());
```
Run it:
```bash
TOKEN=$(fusebase token create --feature <featureId>) bun _test-api.ts
```
### 3. Inspect results and iterate
Read the output, adjust your calls, and re-run. Once you understand the API behavior, implement it properly in your app code.
### 4. Clean up
Delete the temporary test script when done — don't commit it.
## Example: Testing `@fusebase/dashboard-service-sdk`
Use this to verify SDK calls before wiring them into app UI code.
`_test-sdk.ts`:
```typescript
import {
createClient,
DatabasesApi,
CustomDashboardRowsApi,
} from "@fusebase/dashboard-service-sdk";
const token = process.env.T