Skip to content

Consolidate discover prompt library: live-verified corrections, trim to 7 prompts#4

Open
noneal220 wants to merge 3 commits into
IntuitDeveloper:mainfrom
noneal220:main
Open

Consolidate discover prompt library: live-verified corrections, trim to 7 prompts#4
noneal220 wants to merge 3 commits into
IntuitDeveloper:mainfrom
noneal220:main

Conversation

@noneal220

Copy link
Copy Markdown
Collaborator

Consolidates the discover prompt library with live-verified API corrections and trims it to a focused, internally consistent set of 7 prompts.

What's included

  • Live-verified corrections to every API-behavior claim, confirmed against the production QBO API:
    • project-budgets: budgetDetails updates MERGE by sequenceId (single-line delete via deleted: true); total is server-computed; state defaults to LOCKED (LOCKED→DRAFT forbidden); non-Basic cost-method prerequisite; 1 budget per project; no syncToken/clientMutationId; REST-vs-GraphQL host split; budgetDetailsPaginated uses the budgetDetailsInput wrapper.
    • project-change-orders: top-level LinkedTxn is authoritative and auto-propagates onto lines (only total absence errors); verified error codes; sparse delete response; correct entity doc link.
    • projects / custom-fields / dimensions: explicit REST + GraphQL host blocks; correct entity doc links; minorversion on the estimate read; IES accepted in the projects eligibility gate; custom-fields associations[].associatedEntity corrected to the verified /network/Contact + subAssociations shape.
    • oauth-setup: refresh-token rotation + invalid_grant guidance; x_refresh_token_hard_expires_in documented as header-gated (verified) — the incorrect x_refresh_token_lifetime_expires_in name is called out, not used.
  • Trimmed to 7 internally consistent prompts (removed batch, data-sync, multi-currency, payment-linking, reports along with their config keys, schema properties, menu entries, and README references).

Verification

  • prompt-config.json + schema validate; all 7 prompts regenerate with zero unresolved placeholders.
  • No secrets, tokens, or realm IDs anywhere in the tree or history.

noneal220 and others added 3 commits July 21, 2026 13:22
…ication workflow, trim to 7 prompts (IntuitDeveloper#2)

* Add custom-fields prompt category

Brings the QBO Custom Fields prompt (GraphQL discovery + REST V3 write/read)
into the library. Includes:

- Core prompt template + README (workflow: 5 tasks, GraphQL definitions ->
  REST V3 transactions, with empirically-verified gotchas like silent drops,
  legacyIDV2 vs id distinction, production-only GraphQL)
- Per-language SDK notes for Java, .NET, Python, Node, PHP, Ruby covering
  how each SDK handles the enhancedAllCustomFields include parameter
- Postman collections: main CRUD flow + 2 diagnostic collections
  (id-format-test, salesreceipt-subassociation-test) for verifying API
  behavior empirically
- Test checklist and methodology docs (test/runs/ excluded as internal QA)

Note: requires accompanying config/schema/merge-prompt.js updates that
will follow in subsequent commits to wire this prompt into the menu.

* Add sales-tax prompt category (template, README, postman, SDK notes)

* Add project-budgets prompt category (template, README, postman)

* Add project-change-orders prompt category (template, README)

* Add prompt-config-existing.json for integrating into existing codebases

* Restructure instructions.md into markdown tables and code fences

Replaces the legacy plaintext lists with markdown tables for
type_of_transaction values and language_framework / typing_system
combinations, and wraps the transaction_creation_instructions examples
in fenced JSON blocks. Same data, cleaner format.

* Wire new prompt categories + fix REST V3 sandbox host in prompt-config.json

Adds 33 new keys for the four new prompt categories (custom-fields,
sales-tax, project-budgets, project-change-orders) covering GraphQL
queries/mutations, REST V3 endpoints, sample-app links, scopes, and
example variables payloads.

Also fixes three existing values:
- rest_baseurl_sandbox: was qb-sandbox.api.intuit.com (the GraphQL host),
  now sandbox-quickbooks.api.intuit.com (the correct REST V3 host).
- get_transaction_endpoint: now includes ?minorversion=75.
- rest_v3_api_documentation: now uses {{type_of_transaction}} so the
  link points at the right entity page per prompt.

* Add schema entries for new prompt categories (selective merge)

Adds 32 new property definitions for the four new prompt categories
(project-budgets, project-change-orders, custom-fields, sales-tax) and
adds custom_field_transaction_creation_instructions to the required
array. Preserves the 5 upstream-only properties (estimate endpoints,
rest_baseurl_*, minorversion).

* Expand merge-prompt.js menu from 2 to 6 prompt categories

Adds menu options 3-6 for the four new prompt categories (custom-fields,
sales-tax, project-budgets, project-change-orders). Keeps all upstream
infrastructure unchanged: CLI --config flag, schema validation,
multi-pass placeholder merge, and unresolved/runtime placeholder
classification.

* Update discover/README.md for 6-prompt menu and new categories

Documents the new 6-option menu (adding custom-fields, sales-tax,
project-budgets, project-change-orders alongside dimensions and project-
estimates), updates the project structure tree to include the new
prompt folders, and refreshes the workflow diagrams and choice table.
Preserves the MIT license footer.

* Regenerate all 6 prompts after config/menu changes

Re-runs merge-prompt.js for all 6 menu options:
- dimensions and projects: pick up the upgraded rest_v3_api_documentation
  (now uses {{type_of_transaction}}) and get_transaction_endpoint (now
  includes ?minorversion=75) from the config update.
- custom-fields, sales-tax, project-budgets, project-change-orders: new
  generated artifacts for the four new prompt categories.

Smoke test: all 6 choices generate without unresolved placeholders; only
expected runtime placeholders remain (companyid, TransactionId, sdk_notes,
entity-specific IDs).

* testing

* testing

* Added Reports prompt

* Still testing

* testing reports

* adding prompts and live testing

* adding more promtps

* Fix --language flag to inject SDK notes and keep prompt consistent (IntuitDeveloper#1)

Adds --language <lang> to merge-prompt.js: injects a per-prompt sdk-notes/<lang>.md into {{sdk_notes}} and overrides language_framework/typing_system so the whole prompt stays consistent. Falls back to config language_framework when the flag is absent; warns (no leak/crash) when notes are missing.

Co-authored-by: dvaishnavi <vaishnavi_davuluri@intuit.com>

* Port live-verified project-budgets corrections onto current mainline

Reconcile the mainline project-budgets prompt (richer structure: inline
mutation skeletons, Non-Goals, Step A/B discovery) with the live-verified
facts from production testing, replacing the incorrect ones:

- Removed syncToken everywhere (does not exist on BusinessPlanning_Budget;
  selecting/sending it fails GRAPHQL_VALIDATION_FAILED) and clientMutationId
  from the create/update/delete selections.
- Replaced the wrong 'full-replace / no sparse updates' model with the
  verified MERGE-by-sequenceId behavior; single-line delete via deleted:true.
- total is server-computed (input ignored), not a 'sanity-check'.
- sequenceId is server-assigned; reuse the server value on update/delete.
- state defaults to LOCKED; LOCKED->DRAFT forbidden (PNB-INPUT-85).
- Added Check 4 (non-Basic cost method, PNB-INPUT-87), the 1:1 rule
  (PNB-INPUT-72), hard-delete (PNB-INPUT-024), the REST-vs-GraphQL host
  split for the pre-flight, and the budgeting-service error-code reference.
- Fixed the config update example (no syncToken, demonstrates edit +
  deleted:true) and removed syncToken from the paginated query.

Regenerated the ready-prompt; config validates.

* Add verify-discover-prompts workflow and Claude-local gitignore rules

Bring the read-only multi-agent verification workflow (fan-out one verifier
per prompt package, adversarial refute per finding, synthesize) onto the
current mainline, plus gitignore rules that ignore personal/local Claude
files while keeping .claude/workflows/ tracked as a team-shared tool.

* Reconcile discover prompts: port live-verified corrections + fix defects

Apply this session's live-verified corrections onto the current mainline
prompts, and fix defects surfaced by the verify-discover-prompts workflow:

project-change-orders (template + README):
- LinkedTxn required at top level (authoritative; auto-propagates onto lines
  that omit it); only total absence fails (error 2020). Removed the wrong
  'omitting on any line degrades to a standalone estimate' claim.
- Silent normalization of differing per-line TxnIds to the top-level value.
- Verified error codes 2020 / 5010; sparse delete response shape.
- Fixed malformed delete URL (?minorversion=75?operation -> &operation).
- Doc link now points at the changeorder entity, not salesreceipt (new
  changeorder_rest_v3_api_documentation config key).

projects (template):
- Added REST + GraphQL host block (using the real rest_baseurl_* keys).
- Estimate doc link now points at the estimate entity, not salesreceipt
  (new estimate_rest_v3_api_documentation key).
- get_estimate_transaction_endpoint now carries minorversion=75 so the
  Task 3 read returns ProjectRef.

custom-fields (template + README):
- Added a host block distinguishing the production-only GraphQL definitions
  API from the QBO_ENV-honoring REST V3 value calls.
- Create example sub-association SALE_INVOICE -> SALE (matches salesreceipt
  target). Corrected the README's subType-filter claim to match the shipped
  active-only query + client-side filtering.

dimensions (template):
- Added the REST base host for the Task 2 REST V3 transaction call.

project-budgets (README):
- Removed syncToken / full-array / sparse-update guidance; documented the
  merge-by-sequenceId + deleted:true model, server-computed total, and the
  budgeting-service error codes. Fixed the generated-prompts output path.

Regenerated all affected ready-prompts; config validates.

* Fix remaining consistency defects from verification workflow

- project-change-orders: added the REST + GraphQL host block (was the one
  package still missing it); softened the two 'LinkedTxn on every line'
  imperatives to 'recommended', matching the verified Constraints/Guardrails.
- prompt-config.schema.json: corrected the update-payload description (no
  syncToken; MERGE by sequenceId) to match the config/template/generated.
- custom-fields README: aligned the filter description with the shipped
  query (active-only + client-side narrowing); flagged server-side subType
  as unused/unverified rather than 'correct'.
- Fixed the generated-sample-prompts -> generated-prompts output path across
  discover READMEs.

Regenerated project-change-orders; config and schema validate.

Known open item: the custom-fields associatedEntity string values
(/network/Contact + /work/Project in the template vs /Customer + /Vendor in
the README) conflict and are flagged needs_live_test — left unresolved
pending a live Custom Fields API check rather than guessing.

* Fix custom-fields README associatedEntity values (live-verified)

Resolved the template-vs-README conflict flagged needs_live_test by
querying appFoundationsCustomFieldDefinitions live against production.

Verified: the parent associations[].associatedEntity is path-style
(/transactions/Transaction, /network/Contact, /work/Project) with the
specific type in subAssociations[].associatedEntity as an UPPER_SNAKE code
(CUSTOMER, SALE_INVOICE, etc.). The template was already correct; the
README's table wrongly listed /Customer, /Vendor and per-type transaction
paths as parent values. Corrected the README to match.

Also confirmed the subType filter is accepted but does not match by entity
name (subType:"invoice" returned 0 edges for a SALE_INVOICE-associated
definition), so client-side filtering remains the correct approach.

* Fold oauth-setup refresh-token refinements into consolidated branch

Port the four refinements from feat/oauth-refresh-tokens onto this branch's
oauth-setup prompt so it matches the current library:
- refresh_token value rotates ~every 24h; refresh one request at a time
- invalid_grant causes expanded for both code exchange (redirect_uri with no
  query params, single-use code, correct key set, exchange once) and refresh
  (expired/revoked/stale/raced token)

The core facts (token/revoke/auth endpoints, x_refresh_token_hard_expires_in
behind the x-include-refresh-token-hard-expires-in header, the wrong-name
trap) were already correct. Regenerated the ready-prompt; generates clean
with no unresolved placeholders.

* Remove batch, data-sync, multi-currency, payment-linking, reports prompts

Complete the removal of the five deprecated prompt packages so the discover
library is internally consistent:
- Deleted the 5 templates and their generated outputs; removed the now-empty
  folders.
- Removed their 18 config keys and 18 schema properties (none were required
  or referenced by any surviving template).
- Trimmed the merge-prompt.js menu from 12 to 7 entries and renumbered
  OAuth 2.0 setup to option 7.
- Updated discover/README.md (catalog table, folder tree, generated-files
  list) to drop the removed packages.

Verified: config and schema validate; all 7 remaining prompts regenerate
with zero unresolved placeholders; no dangling references remain.

* Fix projects IES eligibility gate and budget pagination query shape

Two defects surfaced by the verification workflow on the post-merge branch:

- projects Task 1 Check 1 admitted only "QuickBooks Online Advanced" while
  the scope line and the failure message both name IES as eligible, so a
  genuine IES company would fail the pre-flight. Widened the gate to "...
  or indicates Intuit Enterprise Suite", matching the sibling
  project-budgets / project-change-orders templates.

- project_budget_details_paginated_query used direct first/after/sortBy
  args, but the verified working shape (live test 2026-07-20, tid
  1-6a5e096b-...; introspected BusinessPlanning_FetchBudgetDetailsInput) and
  the package Postman collection both use the budgetDetailsPaginated(
  budgetDetailsInput: BusinessPlanning_FetchBudgetDetailsInput) wrapper.
  Corrected the config query to the wrapper shape.

Regenerated projects and project-budgets; all 7 prompts regenerate with
zero unresolved placeholders.

---------

Co-authored-by: dvaishnavi <vaishnavi_davuluri@intuit.com>
Untrack the .claude/ directory (verification workflow + README) so the
public-facing repo ships only the prompt library itself, not local Claude
Code tooling. Broadened the gitignore to ignore all of .claude/. The
workflow remains available locally (and in git history) for maintainers;
it is simply not distributed with the public repo.

No secrets were involved — .claude/ contained only the workflow script and
its README (a full git-history scan confirmed no credentials were ever
committed to this repo).
…workflows

Remove .claude/ from the public repo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant