jianyuan / terraform-provider-sentry

Terraform provider for Sentry
https://registry.terraform.io/providers/jianyuan/sentry/latest
MIT License
330 stars 131 forks source link

List of Acceptable Project Platform Values #404

Closed wnoonan closed 6 months ago

wnoonan commented 8 months ago

Hello,

I am unable to determine the values that I can use for platform when creating a sentry project. I wanted to point out this function in the provider code:

https://github.com/jianyuan/terraform-provider-sentry/blob/f15b70efee40fb2e37b9ac3524fee46f5ca532fb/sentry/resource_sentry_project.go#L376

Their api documentation doesn't demonstrate or have a defined list of acceptable values here.

https://docs.sentry.io/api/projects/update-a-project/

Just an example but I have an application that is go net/http which looks like this in sentry: Screenshot 2024-03-15 at 2 44 05 PM

This is what it looks like when it comes back from the api: Screenshot 2024-03-15 at 2 44 36 PM

but the code indicated above tries to locate it like this: https://docs.sentry.io/_platforms/go/http.json -- which gives us a 404 not found.

Are you aware of a listing of all of these json documents in a single location to start loading all of my projects into terraform with this provider so i can accurately reference the platform?

Thanks!

aurasphere commented 7 months ago

I had the same problem and I found a list here: https://github.com/getsentry/sentry/blob/master/static/app/data/platformCategories.tsx

wnoonan commented 7 months ago

I had the same problem and I found a list here: https://github.com/getsentry/sentry/blob/master/static/app/data/platformCategories.tsx

many of these won't work due to how this works:

terraform-provider-sentry/sentry/resource_sentry_project.go

The list i'm referring to is the list of valid json files that this validation checks against.