/
Redaction API Flow

Redaction API Flow

 

image-20241230-202034.png
Coral

Coral Backend API sends an SQS request (coral_redaction_startprocess) to StartProcess Lambda

StartProcess Lambda will invoke the process Start Redaction in Integration API

Integration API will Log the request to CoralRedactionIntegrationLog (DynamoDB) and invokes the Redaction API (Confidact) PreSigned Request

Integration API sends the SQS request (coral_redaction_result) to datasync lambda

DataSync lambda invokes the Redaction API (Confidact) Presigned Download Request. If success, invokes SaveAutoRedaction in Coral backend API with redaction result.

Eventbridge – Runs every hour invoking ProcessPendingJobs in datasync lambda to process any pending jobs.

 

Two endpoints created to complete the Redaction Integration process Swagger UI

Step 1: Coral Redaction API - Receive Request Packet.

  • Log Status – Request Packet Received

  • Validate - token, request params.

    • Log Error : Request Packet Error

Step 2: Coral Redaction API - Get Upload URL - Confidact API

  • Call PreSigned Upload

    • Log Error: PreSigned Request Error

Step 3: Coral Redaction API - Download Image

  • Download Image from Coral S3 bucket.

    • Log Error: Download Error

Step 4: Coral Redaction API - Upload Image

  • Upload Image to Confidact S3 bucket using PreSigned URL.

    • Log Error: Upload Error

  • Log Status – Redaction Start

  • Add Delay and Trigger - Return Result

 

Step 5: Coral Redaction API - Get Download URL - Confidact API

  • Call PreSigned Download for the CorrelationID

    • Log Status – Redaction Status

      • Log Error: Status Error

    • Retry

      • Success

        • Log Status - Redaction Complete.

      • Failure (on last retry)

        • Log Status - Redaction Pending.

Step 6: Coral Redaction API - Download Result File

  • Download the result file from Confidact S3 bucket using PreSigned URL.

  • Log Error: Download Result Error

Step 7: Coral Redaction API - Send Result File - Coral Backend API.

  • Send Result packet. (ImageID, JSON)

  • Check the audit table - CoralRedactionIntegrationLog for Pending Status EventType.Status - RedactionStatusPending

  • Get the CorralationId and invoke Integration API to Download result.

  • Update the status on the Audit table with response - Complete/Error.

  • Invoke Backend API SaveAutoRedaction with response.

 

Related content