codeant-ai-for-open-source[bot] commented on PR #38078:
URL: https://github.com/apache/superset/pull/38078#issuecomment-3922963578

   ## **Sequence Diagram**
   
   Shows how the frontend collects masked_encrypted_extra secrets during import 
and sends them to the import API, and the alternate path where the API requests 
missing encrypted fields which the frontend then renders for the user to fill.
   
   ```mermaid
   sequenceDiagram
       participant User
       participant Frontend as "Import / Database Modal"
       participant Hook as "useImportResource"
       participant API as "Superset Import API"
   
       User->>Frontend: Select import bundle + enter encrypted_extra secrets
       Frontend->>Hook: onUpload/onDbImport(bundle, ..., encryptedExtraSecrets)
       Hook->>API: POST /api/v1/<resource>/import/ (formData includes 
encrypted_extra_secrets)
       alt API accepts secrets (success)
           API-->>Hook: 200 OK (import succeeded)
           Hook-->>Frontend: update state (clear needs), return success
           Frontend-->>User: show success (toast / close modal)
       else API needs encrypted fields (missing/secrets masked)
           API-->>Hook: 400 validation error (masked_encrypted_extra messages)
           Hook-->>Frontend: set encryptedExtraFieldsNeeded (file+paths+labels)
           Frontend-->>User: render encrypted extra input fields for those files
       end
   ```
   
   ---
   *Generated by [CodeAnt AI](https://codeant.ai)*
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to