Create API to query issues by project and `GroupHash.hash` value
Problem Statement
Enable querying issues by fingerprint.
We currently have a public API endpoint which returns a list of fingerprints for an issue id but we don't have any way of retrieving the inverse (issue id for a fingerprint).
Solution Brainstorm
Add a new (experimental, for now) API endpoint which returns issue details for a fingerprint (grouphash).
Product Area
Issues
Notes:
-
This will need to be a project endpoint, since hash values aren't unique across projects/orgs, but are unique within a project.
-
The initial usecase for this is to be able to copy issue data across regions (as an org is migrating to the EU datastore, for example). Because they live in separate databases, the old and new copies of a given issue won't necessarily have the same group id, but they will have the same hash. This endpoint is therefore a way to find the new group id. Given that:
- Since we'll need to do this for all of a project's issues, it'd be nice to be able to send a bunch of hash values at once and get back groups for all of them.
- We might consider whether we want to have a mode where all it returns is a dictionary of hash value to group id, rather than hash value to full group.
- Another option would be to just add the ability to pass a hash (or, better, a set of hashes) to the project-issues endpoint.
-
There are more places than you'd immediately think of where our endpoints are listed (and where any new endpoint would need to be added). See https://github.com/getsentry/sentry/pull/72552 for an example.