# Scan Lifespan and Events

#### Scan Lifespan and Events <a href="#scan-lifespan-and-events" id="scan-lifespan-and-events"></a>

1. **Scan Initiation Acknowledgment:**
   * Type: `private_project_scan_acknowledge`
   * Sample:

     ```
     {
       "type": "private_project_scan_acknowledge",
       "payload": {
         "scan_id": "",
         "message": "",
         "project_name": "testsol1",
         "project_url": "https://github.com/mano-credshields/testsol1",
         "project_id": null
       },
       "event_timestamp": "2024-02-13 13:30:45.750213"
     }
     ```
2. **Account Credits Update:**
   * Type: `account_credits_update`
   * Sample:

     ```
     {
       "type": "account_credits_update",
       "payload": {
         "updated_credits": 78
       },
       "event_timestamp": "2024-02-13 13:30:46.114996"
     }
     ```
3. **Scan Status Events:**
   * Types: `scan_initiate`, `scan_status`
   * Sample:

     ```
     {
       "type": "scan_initiate",
       "payload": {
         "scan_details": { ... }
       },
       "event_timestamp": "2024-02-13 13:30:46.238227"
     }
     ```
4. **Post Scan Completion Details:**
   * Type: `scan_status` with `scan_status` as `scan_done`
   * Sample:

     ```
     {
       "type": "scan_status",
       "payload": {
         "scan_id": "3c360eb6e7d70c5c",
         "scan_status": "scan_done",
         "project_id": "851506d2648ff2a405b8de364f00ca82",
         "scan_details": {
           "link": "https://credshields-prod.s3.amazonaws.com/private_scan_details/b3249e92472d1352.json?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=...&X-Amz-Date=...&X-Amz-Expires=...&X-Amz-SignedHeaders=...&X-Amz-Signature=..."
         }
       },
       "event_timestamp": "2024-02-13 13:30:56.323289"
     }
     ```
