latest api features#3
Conversation
Add new CLI commands for managing forms and retrieving statistics. Implement forms responses command to fetch and display form submission data with support for JSON and table output formats. Extend stats commands with segment and report statistics endpoints. Extract error handling logic into reusable function to reduce code duplication across command handlers.
feat: add forms responses and stats commands
Add Installation & Usage section with npx recommendation and rationale. Update subscriber search examples to require email or uuid parameter for clarity. Add pagination and search examples to tags, fields, and broadcasts commands. Include GitHub Actions example for CI/CD workflows. Add dashboard command reference with browser integration. Improve scripting examples with better comments and npx usage for CI environments.
Add dynamic status column to workflows table output. The status column now only displays when the API response includes status data in workflow attributes. This prevents showing empty columns for API versions that don't support workflow status.
docs: add installation guide and improve examples
…pdate) Resolves merge conflicts by taking the PR's more complete sequences implementation (create-email, update-email, --html-file support, validation) while preserving existing type exports for workflows, forms, and experimental. Updates tests to match new sequence ID validation and API POST body format. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add test suite for the skills command covering help output, listing available skills, and installing skills to AI agents. Tests verify both standard and JSON output modes, error handling for unknown agents and skills, agent detection, symlink creation to canonical skill copies, and force installation behavior. Also update .gitignore to exclude documentation build output directory.
Update @bentonow/bento-node-sdk dependency from pinned version1.0.5 to latest to ensure the package always uses the most recent stable release. This allows the project to benefit from bug fixes and new features without manual version updates.
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
test: add comprehensive skills command tests
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 477f2585fa
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| async getWorkflows(): Promise<Workflow[]> { | ||
| const sdk = await this.getClient(); | ||
| return this.handleApiCall(() => sdk.V1.Workflows.getWorkflows()); |
There was a problem hiding this comment.
Paginate workflows before claiming to list them all
getWorkflows() is wired straight to sdk.V1.Workflows.getWorkflows() with no page loop, but the Bento SDK docs describe page as the pagination mechanism for this endpoint. On accounts with more than one page of workflows, bento workflows list will silently omit every workflow after page 1 even though the CLI advertises "List all workflows", which can hide active automations from operators.
Useful? React with 👍 / 👎.
| async getSequences(): Promise<Sequence[] | null> { | ||
| const sdk = await this.getClient(); | ||
| return this.handleApiCall(() => sdk.V1.Sequences.getSequences()); |
There was a problem hiding this comment.
Paginate sequences before returning the full list
getSequences() has the same truncation problem: it forwards to sdk.V1.Sequences.getSequences() once and never requests later pages, while the SDK docs say callers must pass { page } to paginate large installs. Any Bento account with enough sequences to spill onto page 2 will get an incomplete bento sequences list, and users will be unable to discover later sequence IDs from the CLI.
Useful? React with 👍 / 👎.
| async geolocate(ip: string): Promise<unknown> { | ||
| const sdk = await this.getClient(); | ||
| return this.handleApiCall(() => sdk.V1.Experimental.geolocate({ ip })); |
There was a problem hiding this comment.
Call the SDK's actual geolocation helper
The Bento SDK documentation exposes the experimental IP lookup as Experimental.geoLocateIP(...), not Experimental.geolocate(...). Because this wrapper calls a method name that the shipped SDK does not provide, bento experimental geolocate <ip> will throw a ...geolocate is not a function error at runtime instead of reaching the API.
Useful? React with 👍 / 👎.
| async checkBlacklist(domain?: string, ip?: string): Promise<BlacklistResponse> { | ||
| const sdk = await this.getClient(); | ||
| const params = domain ? { domain } : { ip: ip! }; | ||
| return this.handleApiCall(() => sdk.V1.Experimental.checkBlacklist(params)); |
There was a problem hiding this comment.
Use the documented blacklist API name and payload
The SDK's experimental blacklist helper is documented as getBlacklistStatus({ domain | ipAddress }), but this wrapper invokes checkBlacklist(...) and sends { ip } for IP lookups. As written, bento experimental blacklist cannot succeed against the current SDK surface: domain checks call a missing method, and IP checks also use the wrong field name for the documented request shape.
Useful? React with 👍 / 👎.
| function getSkillsSourceDir(): string { | ||
| let dir = resolve(__dirname, ".."); |
There was a problem hiding this comment.
Resolve the skills directory without
__dirname in ESM
These commands ship through bin/bento as Node ESM (scripts/build.ts builds format: "esm"), and __dirname is not defined in that runtime. Once the package is built/published, any call into getSkillsSourceDir()—for example bento skills list or bento skills install—will fail immediately with ReferenceError: __dirname is not defined for Node users.
Useful? React with 👍 / 👎.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Paginate workflows and sequences (auto-page loop like broadcasts) - Fix geolocate to use SDK's geoLocateIP() method name - Fix blacklist to use SDK's getBlacklistStatus() with ipAddress param - Fix __dirname for ESM compatibility using import.meta.url Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
updates for the lastest api features and uses the skills install that includes a liquid skill and cli skill.