Skip to content

This pull request refactors the /prospects API endpoint to provide a more useful and production-ready response. Instead of returning static endpoint information, the endpoint now returns a paginated, filtered, and ordered list of prospects, prioritizing flagged entries and sorting alphabetically by first name.#54

Merged
goldlabelapps merged 1 commit intomasterfrom
staging
Apr 4, 2026

Conversation

@goldlabelapps
Copy link
Copy Markdown
Owner

Prospects endpoint improvements:

  • The /prospects GET endpoint now returns paginated, filtered, and ordered results from the prospects table, rather than a static list of endpoint URLs.
  • Results are ordered so that flagged prospects appear first (using flag DESC NULLS LAST), followed by alphabetical ordering by first_name.

Code cleanup:

  • Removed the old /prospects/read endpoint and its handler, consolidating functionality into the updated /prospects endpoint.

These changes make the API more useful for clients by allowing them to fetch actual prospect data with pagination and meaningful ordering.

@goldlabelapps goldlabelapps merged commit b89a450 into master Apr 4, 2026
2 checks passed
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