Probe every access review connector on status check
Bad API keys and expired OAuth tokens showed Connected because probes ran only for OAuth2 and many providers had no ProbeURL. Add a registry ProbeConnection dispatcher with static, dynamic, and custom probes so all 41 providers are checked on demand. Signed-off-by: Bryan Frimin <bryan@probo.com>
This commit is contained in:
@@ -24,15 +24,12 @@ import (
|
||||
)
|
||||
|
||||
func mondayRegistration() *Registration {
|
||||
// Monday.com's primary API is GraphQL POST, and the auth subdomain
|
||||
// does not expose a Bearer-protected GET userinfo endpoint, so
|
||||
// ProbeURL is empty. The probe handler skips empty entries; an
|
||||
// invalid token surfaces at the next /v2 query.
|
||||
return &Registration{
|
||||
Provider: coredata.ConnectorProviderMonday,
|
||||
DisplayName: "Monday.com",
|
||||
AuthURL: "https://auth.monday.com/oauth2/authorize",
|
||||
TokenURL: "https://auth.monday.com/oauth2/token",
|
||||
Probe: probeMonday,
|
||||
OAuth2Scopes: []string{"users:read", "account:read"},
|
||||
NewDriver: func(_ context.Context, c *http.Client, _ *coredata.Connector, _ *log.Logger) (drivers.Driver, error) {
|
||||
return drivers.NewMondayDriver(c), nil
|
||||
|
||||
Reference in New Issue
Block a user