Install any skill in seconds. Free to start, no credit card required.
Get Started Free →jeremylongshore/guidewire-sdk-patterns
Build a production-grade Guidewire Cloud API client that survives the request-side failures — 409 checksum conflicts on PATCH/PUT, 429 quota throttling, offsetToken pagination drift, retry-unsafe POSTs, and unstructured error responses.
Passed 23 of 24 test cases with the skill, and 13 of 24 without it.
and 10 more in the full report
10 fixed13 passed either way1 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 10 test cases the skill fixed. Same model, same prompt, with and without the skill.
If a POST request returns HTTP `400 Bad Request` with error type `invalid-attribute` from Guidewire Cloud API, where can details about the invalid field be found?
| Checked | Without skill | With skill |
|---|---|---|
| Inspects errors[].attributes for the failing field path. | Missed | Passed |
The instructions your model reads when the skill loads.
Build the Cloud API request layer that runs in production. This skill assumes the auth layer from guidewire-install-auth is in place — bearer tokens come from the cached token provider, not a static API_KEY. What this layer adds: safe mutations under optimistic locking, retry-aware writes, quota-friendly request pacing, complete pagination, and a typed error surface that business logic can pattern-match.
Five production failures this skill prevents:
checksum; the next concurrent edit causes both PATCHes to lose.429 happens at the same backoff, all clients hammer the endpoint together, the tenant rate quota stays pinned.pageSize=100 as "all results"; misses page 2 onward; reports inflated coverage to downstream.userMessage, errors[].type, and attributes structure the API actually returns.guidewire-install-auth — getToken() returning a cached, scope-validated bearer[TENANT].guidewire.net (PC/CC/BC base URLs in env)fetch, AbortController, and crypto.randomUUIDdata[], attributes, checksum, links) — see guidewire-install-auth/references/API_REFERENCE.mdImplement the patterns below as composable layers on top of fetch. Each pattern targets one of the five production failures listed in Overview; do not skip any layer in production code.
Every Cloud API resource carries a checksum. PATCH and PUT must echo the latest checksum in the request body, or the API returns 409 Conflict to protect concurrent writers. Wrap mutations in a fetch-then-mutate helper that does the round-trip automatically.
export async function patchResource<T>(path: string, mutate: (current: T) => Partial<T>): Promise<T> {
const token = await getToken();
const getRes = await fetch(`${BASE}${path}`, { headers: { Authorization: `Bearer ${token}` } });
if (!getRes.ok) throw await mapError(getRes, "GET", path);
const { data: current } = await getRes.json();
const patchRes = await fetch(`${BASE}${path}`, {
method: "PATCH",
headers: { Authorization: `Bearer ${token}`, "Content-Type": "application/json" },
body: JSON.stringify({
test cases passed, vs 13 / 24 without
More skills from the same source and nearby in the registry, with their headline benchmark lift.