Skip to content

Conversation

@lkacenja
Copy link
Collaborator

@lkacenja lkacenja commented Jan 7, 2026

Our Open API Spec can be transformed into Zod clients. Currently there is no easy way to use those clients. We have also been working on creating state-specific Open API overlays that add configuration to the base API spec. We should apply the state overlays and make the Zod clients available as a package.

This PR adds a packaging workflow to create precompiled Zod clients that may be imported into projects via NPM.

type: string

push:
tags:
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can build packages automatically by tagging a commit with a version or state-version. In the latter case the version will only be applied to the specific state. We can also manually trigger a packaging via the UI.

@@ -0,0 +1,264 @@
/**
* Search Query Helpers for Safety Net API Clients
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I returned this utility because I thought it would be handy. It is now included in the packages.

@lkacenja lkacenja self-assigned this Jan 8, 2026
@lkacenja lkacenja marked this pull request as draft January 8, 2026 15:05
@lkacenja
Copy link
Collaborator Author

lkacenja commented Jan 8, 2026

This should wait until #5 is merged. There is a problem with the application overlay being applied that I'd like to fix. It will be easier to address after the application is not a moving target.

@lkacenja lkacenja marked this pull request as ready for review January 12, 2026 22:25
@lkacenja lkacenja requested a review from mryhmln January 12, 2026 22:25
console.log(`\n Processing ${domain}...`);

// Bundle spec (dereference $refs)
await exec('npx', [
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the purpose of this call?

@lkacenja lkacenja requested a review from mryhmln January 15, 2026 16:33
@lkacenja lkacenja merged commit a212137 into main Jan 15, 2026
@mrlubos
Copy link

mrlubos commented Jan 15, 2026

Hey @lkacenja @mryhmln, big fan of @codeforamerica! In one of your negatives, "Separate type and Zod files vs. combined", I'm wondering if something like this would help you? If the concern is around the amount of files, you can collapse them into a single file if you wish. Let me know if I'm misunderstanding that bullet point.

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.

4 participants