CML
    Preparing search index...

    Function httpStatusToSvtaErrorCode

    • Embed an HTTP response status code into the SVTA Network error category, per the external code embedding rule of SVTA2070. HTTP 404 becomes 3404.

      Values outside the valid HTTP status range (integers 100-599) return the unknown network error code (3000) rather than throwing, so error reporting paths cannot fail.

      Parameters

      • status: number

        An HTTP response status code (100-599).

      Returns number

      The SVTA network error code embedding the status.

      const code = httpStatusToSvtaErrorCode(404)

      assert(code === 3404)