Interface AccessibleEntitiesController
-
public interface AccessibleEntitiesControllerAnOAuthProviderthat wants to support accessible entities should provide an appropriate REST endpoint via a controller implementing this interface. SeeOAuthProvider.isAccessibleEntitiesSupported(),OAuthProvider.getAccessibleEntitiesEndpoint()- Since:
- 2024.03
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classAccessibleEntitiesController.EntityNamestatic classAccessibleEntitiesController.EntitySourcestatic interfaceAccessibleEntitiesController.SettingsProvider-specific settings DTO for UI purposes.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description AccessibleEntitiesController.EntityNamecreateEntityName(String value, AccessibleEntitiesController.EntitySource source)Invoke provider-specific logic to create a proper entity name out of a provided user value.AccessibleEntitiesController.SettingsgetSettings()Provide a settings DTO for UI purposes.org.springframework.http.ResponseEntity<List<String>>listAllowedEntities(String projectId, String connectionId)List all allowed entity names for the scope of a given OAuth connection.
-
-
-
Method Detail
-
getSettings
@GetMapping(value="/settings", produces="application/json") @NotNull AccessibleEntitiesController.Settings getSettings()Provide a settings DTO for UI purposes. Should be exposed underGET {baseUrl}/settings.- Returns:
- settings DTO
- Since:
- 2024.03
-
createEntityName
@GetMapping(value="/entityName", produces="application/json") @Nullable AccessibleEntitiesController.EntityName createEntityName(@RequestParam @NotNull String value, @RequestParam @NotNull AccessibleEntitiesController.EntitySource source)Invoke provider-specific logic to create a proper entity name out of a provided user value. The source parameter allows handling certain types of values differently. Should be exposed underGET {baseUrl}/entityName?value=- Parameters:
value- provided valuesource- source of the value- Returns:
- the created entity name, if applicable
- Since:
- 2024.03
-
listAllowedEntities
@GetMapping(value="/allowed", produces="application/json") @NotNull org.springframework.http.ResponseEntity<List<String>> listAllowedEntities(@NotNull @RequestParam String projectId, @NotNull @RequestParam String connectionId)List all allowed entity names for the scope of a given OAuth connection. Implementations should give backHTTP 501 Not Implementedif this operation is not supported. Implementations should give backHTTP 504 Gateway Timeoutif the listing can't be completed due to downstream timeouts. Should be exposed underGET {baseUrl}/allowed?projectId=pid&connectionId=cid- Parameters:
projectId- the external ID of the connection's projectconnectionId- the connection ID- Returns:
- an HTTP entity object encapsulating a list of allowed entity names
- Since:
- 2024.12
-
-