Skip to content

Conversation

@pedrooot
Copy link
Member

@pedrooot pedrooot commented Jan 15, 2026

Description

Track whether a provider account still exists, for ephemeral accounts that may be deleted.

  • Add available boolean field to Provider (root level, default True)
  • Read-only for users (not editable via PATCH), filterable via ?filter[available]=true|false
  • Custom ProviderNotAvailableError exception with check_available() model method
  • Unavailable providers return HTTP 400 on:
    • Connection checks (POST /providers/{id}/connection)
    • Scan creation (POST /scans)
    • Schedule creation (POST /schedules/daily)
  • Defense in depth: connection tasks and scans also skip internally if available=False
Screenshot 2026-01-19 at 11 56 29 Screenshot 2026-01-19 at 11 56 36

Steps to review

Please add a detailed description of how to review this PR.

Checklist

Community Checklist
  • This feature/issue is listed in here or roadmap.prowler.com
  • Is it assigned to me, if not, request it via the issue/feature in here or Prowler Community Slack

SDK/CLI

  • Are there new checks included in this PR? Yes / No
    • If so, do we need to update permissions for the provider? Please review this carefully.

UI

  • All issue/task requirements work as expected on the UI
  • Screenshots/Video of the functionality flow (if applicable) - Mobile (X < 640px)
  • Screenshots/Video of the functionality flow (if applicable) - Table (640px > X < 1024px)
  • Screenshots/Video of the functionality flow (if applicable) - Desktop (X > 1024px)
  • Ensure new entries are added to CHANGELOG.md, if applicable.

API

  • All issue/task requirements work as expected on the API
  • Endpoint response output (if applicable)
  • EXPLAIN ANALYZE output for new/modified queries or indexes (if applicable)
  • Performance test results (if applicable)
  • Any other relevant evidence of the implementation (if applicable)
  • Verify if API specs need to be regenerated.
  • Check if version updates are required (e.g., specs, Poetry, etc.).
  • Ensure new entries are added to CHANGELOG.md, if applicable.

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@pedrooot pedrooot requested a review from a team as a code owner January 15, 2026 16:48
@github-actions github-actions bot added component/api review-django-migrations This PR contains changes in Django migrations labels Jan 15, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Jan 15, 2026

Conflict Markers Resolved

All conflict markers have been successfully resolved in this pull request.

@github-actions
Copy link
Contributor

github-actions bot commented Jan 15, 2026

✅ All necessary CHANGELOG.md files have been updated.

@jfagoagas
Copy link
Member

I'm not sure about the naming and the location of this new field. Even though we need the provider status I'm a little bit confused. If we want to be able to enable/disable we can create a new enabled field. On the contrary since this is being created looking for a future Organizations integration maybe another table can solve it where we can store the status between the account and their parent organization.

Is this a replacement of connection.connected? If so we can mark the field as deprecated.

Thoughts? @Alan-TheGentleman @alejandrobailo @AdriiiPRodri @josemazo @vicferpoy

@pedrooot pedrooot changed the title feat(api): add provider status feat(api): add provider available Jan 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component/api review-django-migrations This PR contains changes in Django migrations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants